Documentation

PersonExtension extends Extension

An extension is the only way to add new functionality to Faker.

Tags
experimental

This interface is experimental and does not fall under our BC promise

Table of Contents

GENDER_FEMALE  = 'female'
GENDER_MALE  = 'male'
firstName()  : string
firstNameFemale()  : string
firstNameMale()  : string
lastName()  : string
name()  : string
title()  : string
titleFemale()  : string
titleMale()  : string

Constants

Methods

firstName()

public firstName([string|null $gender = null ]) : string
Parameters
$gender : string|null = null

'male', 'female' or null for any

Tags
example

'John'

Return values
string

firstNameFemale()

public firstNameFemale() : string
Return values
string

firstNameMale()

public firstNameMale() : string
Return values
string

lastName()

public lastName() : string
Tags
example

'Doe'

Return values
string

name()

public name([string|null $gender = null ]) : string
Parameters
$gender : string|null = null

'male', 'female' or null for any

Tags
example

'John Doe'

Return values
string

title()

public title([string|null $gender = null ]) : string
Parameters
$gender : string|null = null

'male', 'female' or null for any

Tags
example

'Mrs.'

Return values
string

titleFemale()

public titleFemale() : string
Tags
example

'Mrs.'

Return values
string

titleMale()

public titleMale() : string
Tags
example

'Mr.'

Return values
string

Search results