Ptondereau\PackMe\Package::getAuthor PHP Méthode

getAuthor() public méthode

public getAuthor ( ) : string
Résultat string
    public function getAuthor()
    {
        return $this->author;
    }

Usage Example

 /**
  * Make a verification.
  *
  * @param Package $package
  *
  * @throws ValidatorException
  *
  * @return mixed|void
  */
 public function verify(Package $package)
 {
     if (null === $package->getAuthor() || empty($package->getAuthor())) {
         throw new ValidatorException('Author is not defined!');
     }
 }