PHP 클래스 Horde_Date_Parser_Locale_Pt, horde

상속: extends Horde_Date_Parser_Locale_Base
파일 보기 프로젝트 열기: horde/horde

공개 프로퍼티들

프로퍼티 타입 설명
$args
$definitions
$now

공개 메소드들

메소드 설명
__construct ( $args )
handle_od_rmn ( $tokens, $options )
handle_rdn ( $tokens, $options )
handle_sd_rmn ( $tokens, $options ) JPC
initDefinitions ( )
normalize_special_characters ( $str ) Replaces special characters with non-special equivalents.
numericizeOrdinals ( $text ) Convert ordinal words to numeric ordinals (third => 3rd)
parse ( $text, $specifiedOptions = [] ) Parses a string containing a natural language date or time. If the parser can find a date or time, either a Horde_Date or Horde_Date_Span will be returned (depending on the value of :return). If no date or time can be found, +nil+ will be returned.
preNormalize ( $text ) Clean up the specified input text by stripping unwanted characters, converting idioms to their canonical form, converting number words to numbers (three => 3), and converting ordinal words to numeric ordinals (third => 3rd)

메소드 상세

__construct() 공개 메소드

public __construct ( $args )

handle_od_rmn() 공개 메소드

public handle_od_rmn ( $tokens, $options )

handle_rdn() 공개 메소드

public handle_rdn ( $tokens, $options )

handle_sd_rmn() 공개 메소드

JPC
public handle_sd_rmn ( $tokens, $options )

initDefinitions() 공개 메소드

public initDefinitions ( )

normalize_special_characters() 공개 메소드

Source: http://pt2.php.net/manual/en/function.chr.php#93291

numericizeOrdinals() 공개 메소드

Convert ordinal words to numeric ordinals (third => 3rd)
public numericizeOrdinals ( $text )

parse() 공개 메소드

Options are: [:context] :past or :future (defaults to :future) If your string represents a birthday, you can set :context to :past and if an ambiguous string is given, it will assume it is in the past. Specify :future or omit to set a future context. [:now] Time (defaults to time()) By setting :now to a Horde_Date, all computations will be based off of that time instead of time(). [:return] 'result', 'span', or 'date' (defaults to 'date') By default, the parser will guess a single point in time for the given date or time. If you'd rather have the entire time span returned, set :return to 'span' and a Horde_Date_Span will be returned. If you want the entire result, including tokens (for retrieving the text that was or was not tagged, for example), set :return to 'result' and you will get a result object. [:ambiguousTimeRange] Integer or :none (defaults to 6 (6am-6pm)) If an Integer is given, ambiguous times (like 5:00) will be assumed to be within the range of that time in the AM to that time in the PM. For example, if you set it to 7, then the parser will look for the time between 7am and 7pm. In the case of 5:00, it would assume that means 5:00pm. If :none is given, no assumption will be made, and the first matching instance of that time will be used.
public parse ( $text, $specifiedOptions = [] )

preNormalize() 공개 메소드

Clean up the specified input text by stripping unwanted characters, converting idioms to their canonical form, converting number words to numbers (three => 3), and converting ordinal words to numeric ordinals (third => 3rd)
public preNormalize ( $text )

프로퍼티 상세

$args 공개적으로 프로퍼티

public $args

$definitions 공개적으로 프로퍼티

public $definitions

$now 공개적으로 프로퍼티

public $now