class Illuminate / Validation / Rules / Dimensions
You are viewing an older version of the documentation. For the latest, please visit master documentation.

Dimensions

Uses

Properties

protected

$constraints array

The constraints for the dimensions rule.

Default: []

Methods

public

__construct ( array $constraints ) : void

Create a new dimensions rule instance.

Parameters

  • $constraints array
public

width ( $value ) : $this

Set the "width" constraint.

Parameters

  • $value int
public

height ( $value ) : $this

Set the "height" constraint.

Parameters

  • $value int
public

minWidth ( $value ) : $this

Set the "min width" constraint.

Parameters

  • $value int
public

minHeight ( $value ) : $this

Set the "min height" constraint.

Parameters

  • $value int
public

maxWidth ( $value ) : $this

Set the "max width" constraint.

Parameters

  • $value int
public

maxHeight ( $value ) : $this

Set the "max height" constraint.

Parameters

  • $value int
public

ratio ( $value ) : $this

Set the "ratio" constraint.

Parameters

  • $value float
public

__toString ( ) : string

Convert the rule to a validation string.