PHP Class libphonenumber\Matcher

Note that this is NOT the same as google's java PhoneNumberMatcher class. This class is a minimal port of java's built-in matcher class, whereas PhoneNumberMatcher is designed to recognize phone numbers embedded in any text.
Afficher le fichier Open project: giggsey/libphonenumber-for-php Class Usage Examples

Protected Properties

Свойство Type Description
$groups array
$pattern string
$subject string

Méthodes publiques

Méthode Description
__construct ( string $pattern, string $subject )
end ( integer | null $group = null ) : integer
find ( ) : boolean
group ( integer $group = null ) : string
groupCount ( ) : integer
lookingAt ( ) : boolean
matches ( ) : boolean
replaceAll ( string $replacement ) : string
replaceFirst ( string $replacement ) : string
reset ( string $input = "" ) : Matcher
start ( $group = null )

Méthodes protégées

Méthode Description
doMatch ( $type = 'find' )

Method Details

__construct() public méthode

public __construct ( string $pattern, string $subject )
$pattern string
$subject string

doMatch() protected méthode

protected doMatch ( $type = 'find' )

end() public méthode

public end ( integer | null $group = null ) : integer
$group integer | null
Résultat integer

find() public méthode

public find ( ) : boolean
Résultat boolean

group() public méthode

public group ( integer $group = null ) : string
$group integer
Résultat string

groupCount() public méthode

public groupCount ( ) : integer
Résultat integer

lookingAt() public méthode

public lookingAt ( ) : boolean
Résultat boolean

matches() public méthode

public matches ( ) : boolean
Résultat boolean

replaceAll() public méthode

public replaceAll ( string $replacement ) : string
$replacement string
Résultat string

replaceFirst() public méthode

public replaceFirst ( string $replacement ) : string
$replacement string
Résultat string

reset() public méthode

public reset ( string $input = "" ) : Matcher
$input string
Résultat Matcher

start() public méthode

public start ( $group = null )

Property Details

$groups protected_oe property

protected array $groups
Résultat array

$pattern protected_oe property

protected string $pattern
Résultat string

$subject protected_oe property

protected string $subject
Résultat string