<?php #CodeGenerator V4 Δ e1813461fa704ca3ece955bb5b0fe8cd Δ DYNAMICALLY GENERATED FILE - Do not modify this line! Remove it completely to protect the file from changes.
/**
 * JSON:API Request Class
 *
 * @version     1.0.$Revision:$
 * @version     SVN: $Id:$
 * @version     STUB: 1.0.0
 * @generated   2026-03-23 15:02:27
 * @package     bplan-base/globals
 * @subpackage  Requests
 * @author      Emilio Cannarozzo <emilio.cannarozzo@bplan-solutions.de>
 * @author      Wassilios Meletiadis <wassilios.meletiadis@bplan-solutions.de>
 * @copyright   Copyright (C) 2025, 2026 bplan-solutions GmbH & Co. KG <https://www.bplan-solutions.de/>
 * /Δ\
 */

namespace BplanBase\Globals\JsonApi\Data\EntityTypes;


use LaravelJsonApi\Laravel\Http\Requests\ResourceRequest;
use LaravelJsonApi\Validation\Rule as JsonApiRule;


/**
 * JSON:API Request Class
 *
 * @version     1.0.0 / 2026-03-23
 * @author      Emilio Cannarozzo <emilio.cannarozzo@bplan-solutions.de>
 * @author      Wassilios Meletiadis <wassilios.meletiadis@bplan-solutions.de>
 */
class EntityTypeRequest extends ResourceRequest
{


/* +++ TRAITS +++ +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */


/* +++ CLASS CONSTANTS +++ ++++++++++++++++++++++++++++++++++++++++++++++++++ */


/* +++ OBJECT MEMBERS +++ +++++++++++++++++++++++++++++++++++++++++++++++++++ */


/* +++ CLASS MEMBERS +++ ++++++++++++++++++++++++++++++++++++++++++++++++++++ */


/* +++ OBJECT METHODS +++ +++++++++++++++++++++++++++++++++++++++++++++++++++ */


    /**
     * Get the validation rules for the resource.
     *
     * @return      array
     *
     * @version     1.0.0 / 2026-03-23
     * @author      Emilio Cannarozzo <emilio.cannarozzo@bplan-solutions.de>
     * @author      Wassilios Meletiadis <wassilios.meletiadis@bplan-solutions.de>
     */
    public function rules(): array
    {
        return [
            'abstract'           => JsonApiRule::boolean(),
            'active'             => JsonApiRule::boolean(),
            'creatable'          => JsonApiRule::boolean(),
            'deleteMode'         => ['sometimes', 'required', 'string'],
            'editType'           => ['sometimes', 'required', 'string', 'max:3'],
            'editable'           => JsonApiRule::boolean(),
            'historize'          => JsonApiRule::boolean(),
            'htmlMask'           => ['nullable', 'string', 'max:500'],
            'identifier'         => ['required', 'string', 'max:65'],
            'internal'           => JsonApiRule::boolean(),
            'journalize'         => JsonApiRule::boolean(),
            'labels'             => [],
            'mainType'           => ['required', 'string', 'max:32'],
            'private'            => JsonApiRule::boolean(),
            'requireRelease'     => JsonApiRule::boolean(),
            'resourceName'       => ['required', 'string', 'max:50'],
            'subType'            => ['nullable', 'string', 'max:32'],
            'textMask'           => ['nullable', 'string', 'max:255'],
            'uuid'               => ['required'],
            'visible'            => JsonApiRule::boolean(),

            'master-entity-type' => JsonApiRule::toOne(),
            'model'              => JsonApiRule::toOne(),
            'module'             => JsonApiRule::toOne(),
            'source-entity-type' => JsonApiRule::toOne(),

        ];
    } // rules()


/* +++ CLASS METHODS +++ ++++++++++++++++++++++++++++++++++++++++++++++++++++ */


} // class EntityTypeRequest extends ResourceRequest {}
