Home | Trees | Indices | Help |
|
---|
|
Code to support PQL syntax (as found in various DAL protocols).
PQL range-list syntax is
valSep ::= "," rangeSep ::= "/" qualSep ::= ";" step ::= somethingMagicallyDefined range ::= [literal] rangeSep literal | literal rangeSep steppedRange ::= range [rangeSep step] qualification ::= qualSep somethingMagicallyDefined listItem ::= steppedRange | literal rangeList ::= listItem {valSep listItem} [qualification]
This defines a regular language, and we're going to slaughter it using REs and ad hoccing.
Since the actually allowed grammar depends on the type of the parameter (e.g., steps make no sense for strings, and have a special grammar for dates), parsing is done by the specific PQLPar types (fromLiteral). See the PQLPar docstring for further info.
Classes | |
PQLRange a representation of a PQL range. |
|
PQLNoRange a stand-in for PQLRange when no ranges are to be supported |
|
PQLPar a representation for PQL expressions. |
|
PQLIntPar a PQL parameter containing an integer. |
|
PQLDatePar a PQL parameter containing a date. |
|
PQLPositionPar a PQL position parameter, as for SSA. |
|
PQLFloatPar a PQL float parameter. |
|
PQLCaselessPar a PQL string parameter that's compared with case folding. |
|
PQLShellPatternPar a PQL shell pattern parameter. |
|
PQLNocaseShellPatternPar a shell-pattern matching parameter, ignoring case. |
|
PQLStringPar a PQL normal string parameter. |
|
PQLTextParIR a PQL string parameter matching "google-like", "Information Retrieval". |
|
ToPQLTypeConverter |
Functions | |||
|
|||
|
|||
|
Variables | |
QUALIFIER_RE = re.compile(r'
|
|
LIST_RE = re.compile(r'
|
|
RANGE_RE = re.compile(r'
|
|
__package__ =
|
Function Details |
returns a POSIX RE for a POSIX shell pattern. >>> getREForShPat(r"ZU?\*[!A-Z]*") 'ZU.\\*[^A\\-Z].*' >>> getREForShPat("no[*") 'no\\[.*' |
returns inputKey changed to generate SQL for PQL-like expressions. This is used for buildFrom on CondDescs and renderers having parameterStyle pql. |
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Thu May 2 07:29:09 2019 | http://epydoc.sourceforge.net |