Caplin Trader 4.0.3

Interface: module:br/presenter/parser/Parser

module:br/presenter/parser/Parser

Summary

Parses a value according to some attributes.

Methods

isSingleUseParser()

Allows parsers that should only run a single time, and that should not repeatedly re-parse their own output.

This method is optional. Parsers that don't implement it are not considered to be single-use parsers by default.

parse(sValue, mAttributes)

Parses a value and either returns the parsed value upon success, otherwise returns null.
Parameters:
Name Type Description
sValue String the unparsed value. May be null.
mAttributes Object the attributes appropriate to the Parser implementation.
Implementations:
Returns:
the parsed value, or null if the value was not recognised.