class AvatarValidator extends AbstractValidator

Traits

Properties

static string $CORE_VALIDATION_CACHE_KEY from AbstractValidator
protected array $configuration from AbstractValidator
protected array $rules from AbstractValidator
protected Factory $validator from AbstractValidator
protected TranslatorInterface $translator from AbstractValidator
protected Validator $laravelValidator
protected ImageManager $imageManager

Methods

string|null
getClassExtensionId()

No description

addConfiguration($callable)

No description

__construct(Factory $validator, TranslatorInterface $translator, ImageManager $imageManager)

No description

assertValid(array $attributes)

Throw an exception if a model is not valid.

array
getRules()

No description

array
getMessages()

No description

array
getAttributeNames()

No description

Validator
makeValidator(array $attributes)

Make a new validator instance for this model.

assertFileRequired(UploadedFileInterface $file)

No description

assertFileMimes(UploadedFileInterface $file)

No description

assertFileSize(UploadedFileInterface $file)

No description

raise($error, array $parameters = [], $rule = null)

No description

getMaxSize()

No description

getAllowedTypes()

No description

Details

protected string|null getClassExtensionId()

Return Value

string|null

addConfiguration($callable)

Parameters

$callable

__construct(Factory $validator, TranslatorInterface $translator, ImageManager $imageManager)

Parameters

Factory $validator
TranslatorInterface $translator
ImageManager $imageManager

assertValid(array $attributes)

Throw an exception if a model is not valid.

Parameters

array $attributes

protected array getRules()

Return Value

array

protected array getMessages()

Return Value

array

protected array getAttributeNames()

Return Value

array

protected Validator makeValidator(array $attributes)

Make a new validator instance for this model.

Parameters

array $attributes

Return Value

Validator

protected assertFileRequired(UploadedFileInterface $file)

Parameters

UploadedFileInterface $file

protected assertFileMimes(UploadedFileInterface $file)

Parameters

UploadedFileInterface $file

protected assertFileSize(UploadedFileInterface $file)

Parameters

UploadedFileInterface $file

protected raise($error, array $parameters = [], $rule = null)

Parameters

$error
array $parameters
$rule

protected getMaxSize()

protected getAllowedTypes()