pobs.parser
Class PSet

java.lang.Object
  extended bypobs.PParser
      extended bypobs.parser.PSet
All Implemented Interfaces:
PObject
Direct Known Subclasses:
PRange

public class PSet
extends PParser

Matches if the next character on the input matches any of a specified characters. Uses case sensitivity directive. BNF: parser := 'a' | 'b' | .. (where any number of characters may be specified)

Author:
Martijn W. van der Lee

Constructor Summary
PSet(java.lang.String set)
          Sole constructor.
 
Method Summary
 PMatch parse(PScanner input, long begin, PContext context)
           
 
Methods inherited from class pobs.PParser
addControl, getErrorInfo, process, setErrorInfo, setMatchAction, setMismatchAction
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PSet

public PSet(java.lang.String set)
Sole constructor.

Parameters:
set - a string containing the set of characters.
Method Detail

parse

public PMatch parse(PScanner input,
                    long begin,
                    PContext context)
Parameters:
input - Input to be parsed.
begin - Index of first character of input to be parsed.
context - Parsing context.
Returns:
Parsing result.