Class RegexStringParser

Description

RegexStringParser is an abstract class that implements a common canHandle() method for decendents as well as defines a 'getRegex()' class method which must be set by decendent classes.

Located in /harmoni/core/Primitives/Chronology/StringParser/RegexStringParser.class.php (line 33)

SObject
   |
   --StringParser
      |
      --RegexStringParser
Direct descendents
Class Description
ANSI58216StringParser This StringParser parses durations formatted as per ANSI 5.8.2.16: [-]D:HH:MM:SS[.S]
DateAndTimeStringParser DateAndTimeStringParser breaks up strings into a date component and a time component and attempts to match each individually.
ISO8601StringParser This StringParser can handle ISO 8601 dates. http://www.cl.cam.ac.uk/~mgk25/iso-time.html Examples:
  • 1982-04-05T15:25:21+5:00
ISO8601TimeStringParser This StringParser can handle ISO 8601 dates. http://www.cl.cam.ac.uk/~mgk25/iso-time.html
TimeStringParser This StringParser can handle Times (12-hour or 24-hour) in the form:
  • <hour>:<minute>:<second> <am/pm>
<minute>, <second> or <am/pm> may be omitted. e.g. 1:59:30 pm; 8AM; 15:30
TwoDigitYearStringParser This class implements a method for converting from a two-digit year, such as '82' to the four-digit '1982' equivalent. Due to the lack of information contained in a two-digit year, the only valid years are 1970-2069.
Method Summary
boolean canHandle ()
string getRegex ()
Variables
Methods
canHandle (line 48)

Answer True if this parser can handle the format of the string passed.

  • since: 5/24/05
  • access: public
boolean canHandle ()

Redefinition of:
StringParser::canHandle()
Answer True if this parser can handle the format of the string passed.
getRegex (line 59)

Return the regular expression used by this parser

  • since: 5/24/05
  • access: protected
string getRegex ()

Redefined in descendants as:

Inherited Methods

Inherited From StringParser

StringParser::StringParser()
StringParser::canHandle()
StringParser::day()
StringParser::getParserFor()
StringParser::hour()
StringParser::minute()
StringParser::month()
StringParser::offsetHour()
StringParser::offsetMinute()
StringParser::offsetSecond()
StringParser::parse()
StringParser::second()
StringParser::setDay()
StringParser::setHour()
StringParser::setMinute()
StringParser::setMonth()
StringParser::setOffsetHour()
StringParser::setOffsetMinute()
StringParser::setOffsetSecond()
StringParser::setSecond()
StringParser::setYear()
StringParser::year()

Inherited From SObject

SObject::asA()
SObject::asString()
SObject::copy()
SObject::copySameFrom()
SObject::copyTwoLevel()
SObject::deepCopy()
SObject::isEqual()
SObject::isEqualTo()
SObject::isNotEqualTo()
SObject::isNotReferenceTo()
SObject::isReferenceTo()
SObject::newFrom()
SObject::postCopy()
SObject::printableString()
SObject::shallowCopy()
SObject::_deepCopyArray()

Documentation generated on Wed, 19 Sep 2007 10:25:54 -0400 by phpDocumentor 1.3.0RC3