mirror of
https://github.com/fzaninotto/Faker.git
synced 2025-03-20 07:19:50 +01:00
restored Company.php deleted by mistake
This commit is contained in:
parent
ba5ed0d689
commit
d0de1b6825
30
src/Faker/Provider/Company.php
Normal file
30
src/Faker/Provider/Company.php
Normal file
@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
namespace Faker\Provider;
|
||||
|
||||
class Company extends \Faker\Provider\Base
|
||||
{
|
||||
protected static $formats = array(
|
||||
'{{lastName}} {{companySuffix}}',
|
||||
);
|
||||
|
||||
protected static $companySuffix = array('Ltd');
|
||||
|
||||
/**
|
||||
* @example 'Acme Ltd'
|
||||
*/
|
||||
public function company()
|
||||
{
|
||||
$format = static::randomElement(static::$formats);
|
||||
|
||||
return $this->generator->parse($format);
|
||||
}
|
||||
|
||||
/**
|
||||
* @example 'Ltd'
|
||||
*/
|
||||
public static function companySuffix()
|
||||
{
|
||||
return static::randomElement(static::$companySuffix);
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user