<?php

namespace App\Classes\Modules\Documents\Standards\Validators;

use App\Classes\General\Abstracts\AbstractValidation;
use App\Classes\Modules\Documents\DataTransferObjects\DocumentObject;

class DocumentValidation extends AbstractValidation
{
    /**
     * @param DocumentObject $object
     * @return array
     */
    protected function data($object): array 
    {
        return [
            'document_type' => $object->getDocumentType(),
            'reference' => $object->getReference(),
            'status' => $object->getStatus(),
        ];
    }

    /**
     * @return array
     */
    protected function rules(): array 
    {
        return [
            'document_type' => 'required',
            'reference' => 'required',
            'status' => 'required'
        ];
    }

    /**
     * @return array
     */
    protected function messages(): array 
    {
        return [];
    }
}