PHP Class JMOlivas\Phpqa\Input\FilesOption

Afficher le fichier Open project: jmolivas/phpqa Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( array $files )
isAbsent ( ) : boolean Returns true if this option is not provided
isEmpty ( ) : boolean Returns true if this option is provided but has no values
normalize ( ) : array Normalize the provided values as an array

Method Details

__construct() public méthode

public __construct ( array $files )
$files array

isAbsent() public méthode

Returns true if this option is not provided
public isAbsent ( ) : boolean
Résultat boolean

isEmpty() public méthode

Returns true if this option is provided but has no values
public isEmpty ( ) : boolean
Résultat boolean

normalize() public méthode

- If it's either empty or absent, it returns an empty array - If it's a single value separated by commas, it converts it to array - Otherwise returns the value as is.
public normalize ( ) : array
Résultat array