OXIESEC PANEL
- Current Dir:
/
/
opt
/
gsutil
/
third_party
/
pyparsing
/
examples
Server IP: 2a02:4780:11:1594:0:ef5:22d7:a
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
12/11/2024 09:39:44 AM
rwxr-xr-x
📄
0README.html
10.75 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
AcManForm.dfm
38.22 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
LAparser.py
20.62 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
Setup.ini
1.41 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
SimpleCalc.py
3.58 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
SingleForm.dfm
42.7 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
TAP.py
7.42 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
__init__.py
0 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
adventureEngine.py
21.59 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
antlr_grammar.py
10.88 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
antlr_grammar_tests.py
2.89 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
apicheck.py
2.2 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
bf.py
4.15 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
bigquery_view_parser.py
62.51 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
booleansearchparser.py
15.26 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
btpyparse.py
4.16 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
builtin_parse_action_demo.py
817 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
cLibHeader.py
853 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
chemical_formulas.py
3.17 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
commasep.py
707 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
configParse.py
2 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
cpp_enum_parser.py
1.35 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
cuneiform_python.py
2.57 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
datetime_parse_actions.py
1.9 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
decaf_parser.py
6.87 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
delta_time.py
21.49 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
dfmparse.py
7.05 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
dhcpd_leases_parser.py
2.98 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
dictExample.py
1.73 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
dictExample2.py
2.1 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
directx_x_file_parser.py
5.54 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
ebnf.py
4.15 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
ebnftest.py
2.35 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
email_address_parser.py
1.18 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
eval_arith.py
6.15 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
excel_expr.py
2.2 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
fourFn.py
10.27 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
gen_ctypes.py
5.28 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
getNTPserversNew.py
1.11 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
greeting.py
518 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
greetingInGreek.py
425 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
greetingInKorean.py
495 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
groupUsingListAllMatches.py
509 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
hola_mundo.py
2.02 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
html_stripper.py
1.68 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
html_table_parser.py
2.16 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
httpServerLogParser.py
3.48 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
idlParse.py
7.53 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
include_preprocessor.py
2.63 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
indentedGrammarExample.py
1022 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
indented_block_example.py
712 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
inv_regex.py
8.08 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
javascript_grammar.g
18.1 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
jsonParser.py
4.7 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
left_recursion.py
1.41 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
lineno_example.py
1.49 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
listAllMatches.py
1.57 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
lua_parser.py
7.96 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
lucene_grammar.py
8.46 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
macro_expander.py
1.77 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
make_diagram.py
1.62 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
matchPreviousDemo.py
586 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
mongodb_query_expression.py
8.46 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
mozilla.ics
752 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
mozillaCalendarParser.py
2.71 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
nested.py
579 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
nested_markup.py
1.85 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
number_words.py
3.77 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
numerics.py
1.34 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
oc.py
4.34 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
one_to_ninety_nine.py
1.88 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
parseTabularData.py
1.68 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
parse_python_value.py
2.5 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
parse_results_sum_example.py
853 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
partial_gene_match.py
2.33 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
pgn.py
3.34 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
position.py
2.17 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
protobuf_parser.py
3.89 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
pythonGrammarParser.py
8.08 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
railroad_diagram_demo.py
1.55 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
range_check.py
2.84 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
readJson.py
120.73 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
removeLineBreaks.py
1.8 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
roman_numerals.py
3.57 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
rosettacode.py
7.43 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
scanExamples.py
2.36 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
searchParserAppDemo.py
962 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
searchparser.py
10.4 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
select_parser.py
8.32 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
sexpParser.py
5.23 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
shapes.py
1.69 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
simpleArith.py
2.42 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
simpleBool.py
3.19 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
simpleSQL.py
3.16 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
simpleWiki.py
1.08 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
snmp_api.h
28.69 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
sql2dot.py
3.07 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
stackish.py
2.71 KB
08/25/2024 02:43:42 PM
rw-r--r--
📁
statemachine
-
08/25/2024 02:43:42 PM
rwxr-xr-x
📄
tag_emitter.py
1.17 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
tag_metadata.py
805 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
test_bibparse.py
8.72 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
unicode_denormalizer.py
5.02 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
urlExtractor.py
1.03 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
urlExtractorNew.py
2.4 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
verilog_parse.py
31.15 KB
08/25/2024 02:43:42 PM
rw-r--r--
📄
withAttribute.py
912 bytes
08/25/2024 02:43:42 PM
rw-r--r--
📄
wordsToNum.py
2.92 KB
08/25/2024 02:43:42 PM
rw-r--r--
Editing: 0README.html
Close
<HTML> <title>pyparsing Examples</title> <body> <h1>pyparsing Examples</h1> <p> This directory contains a number of Python scripts that can get you started in learning to use pyparsing. <h2>LICENSE</h2> <b><i> The files and source code in this examples directory are covered under the same LICENSE as the core pyparsing package. You will find this license in the LICENSE file of the pyparsing package. </i></b> <ul> <li><a href="greeting.py">greeting.py</a><br> Parse "Hello, World!". </li> <p> <li><a href="greetingInKorean.py">greetingInKorean.py</a> <i>~ submission by June Kim</i><br> Unicode example to parse "Hello, World!" in Korean. </li> <p> <li><a href="greetingInGreek.py">greetingInGreek.py</a> <i>~ submission by ???</i><br> Unicode example to parse "Hello, World!" in Greek. </li> <p> <li><a href="hola_mundo.py">hola_mundo.py</a> <i>~ submission by Marco Alfonso</i><br> "Hello, World!" example translated to Spanish, from Marco Alfonso's blog. </li> <p> <li><a href="chemical_formulas.py">chemical_formulas.py</a><br> Simple example to demonstrate the use of ParseResults returned from parseString(). Parses a chemical formula (such as "H2O" or "C6H5OH"), and walks the returned list of tokens to calculate the molecular weight. </li> <p> <li><a href="wordsToNum.py">wordsToNum.py</a><br> A sample program that reads a number in words (such as "fifteen hundred and sixty four"), and returns the actual number (1564). Also demonstrates some processing of ParseExceptions, including marking where the parse failure was found. </li> <p> <li><a href="mongodb_query_expression.py">mongodb_query_expression.py</a><br> A useful utility to convert infix query expressions into the nested dicts required by the MongoDB pymongo library's `find()` command. </li> <p> <li><a href="delta_time.py">delta_time.py</a><br> A utility to parse colloquial time expressions such as "2pm next Tuesday" and convert them into Python datetime instances. </li> <p> <li><a href="pythonGrammarparser.py">pythonGrammarparser.py</a> <i>~ suggested by JH Stovall</i><br> A sample program that parses the EBNF used in the Python source code to define the Python grammar. From this parser, one can generate Python grammar documentation tools, such as railroad track diagrams. Also demonstrates use of Dict class. </li> <p> <li><a href="commasep.py">commasep.py</a><br> Demonstration of the use of the commaSeparatedList helper. Shows examples of proper handling of commas within quotes, trimming of whitespace around delimited entries, and handling of consecutive commas (null arguments). Includes comparison with simple string.split(','). </li> <p> <li><a href="dictExample.py">dictExample.py</a><br> A demonstration of using the Dict class, to parse a table of ASCII tabulated data. </li> <p> <li><a href="dictExample2.py">dictExample2.py</a> <i>~ submission by Mike Kelly</i><br> An extended version of dictExample.py, in which Mike Kelly also parses the column headers, and generates a transposed version of the original table! </li> <p> <li><a href="scanExamples.py">scanExamples.py</a><br> Some examples of using scanString and transformString, as alternative parsing methods to parseString, to do macro substitution, and selection and/or removal of matching strings within a source file. </li> <p> <li><a href="urlExtractorNew.py">urlExtractorNew.py</a><br> A sample program showing sample definitions and applications of HTML tag expressions created using makeHTMLTags helper function. Very useful for scraping data from HTML pages. </li> <p> <li><a href="fourFn.py">fourFn.py</a><br> A simple algebraic expression parser, that performs +,-,*,/, and ^ arithmetic operations. (With suggestions and bug-fixes graciously offered by Andrea Griffini.) </li> <p> <li><a href="SimpleCalc.py">SimpleCalc.py</a> <i>~ submission by Steven Siew</i><br> An interactive version of fourFn.py, with support for variables. </li> <p> <li><a href="LAParser.py">LAParser.py</a> <i>~ submission by Mike Ellis</i><br> An interactive Linear Algebra Parser, an extension of SimpleCalc.py. Supports linear algebra (LA) notation for vectors, matrices, and scalars, including matrix operations such as inversion and determinants. Converts LA expressions to C code - uses a separate C library for runtime evaluation of results. </li> <p> <li><a href="configParse.py">configParse.py</a><br> A simple alternative to Python's ConfigParse module, demonstrating the use of the Dict class to return nested dictionary access to configuration values. </li> <p> <li><a href="getNTPserversNew.py">getNTPserversNew.py</a><br> Yet another scanString example, to read/extract the list of NTP servers from NIST's web site. Uses the new makeHTMLTags() method. </li> <p> <li><a href="httpServerLogParser.py">httpServerLogParser.py</a><br> Parser for Apache server log files. </li> <p> <li><a href="idlParse.py">idlParse.py</a><br> Parser for CORBA IDL files. </li> <p> <li><a href="mozillaCalendarParser.py">mozillaCalendarParser.py</a> <i>~ submission by Petri Savolainen</i><br> Parser for Mozilla calendar (*.ics) files. </li> <p> <li><a href="pgn.py">pgn.py</a> <i>~ submission by Alberto Santini</i><br> Parser for PGN (Portable Game Notation) files, the standard form for documenting the moves in chess games. </li> <p> <li><a href="simpleSQL.py">simpleSQL.py</a><br> A simple parser that will extract table and column names from SQL SELECT statements.. </li> <p> <li><a href="dfmparse.py">dfmparse.py</a> <i>~ submission by Dan Griffith</i><br> Parser for Delphi forms. </li> <p> <li><a href="ebnf.py">ebnf.py / ebnftest.py</a> <i>~ submission by Seo Sanghyeon</i><br> An EBNF-compiler that reads EBNF and generates a pyparsing grammar! Including a test that compiles... EBNF itself! </li> <p> <li><a href="searchparser.py">searchparser.py</a> <i>~ submission by Steven Mooij and Rudolph Froger</i><br> An expression parser that parses search strings, with special keyword and expression operations using (), not, and, or, and quoted strings. </li> <p> <li><a href="roman_numerals.py">romanNumerals.py</a><br> A Roman numeral generator and parser example, showing the power of parse actions to compile Roman numerals into their integer values. </li> <p> <li><a href="removeLineBreaks.py">removeLineBreaks.py</a><br> A string transformer that converts text files with hard line-breaks into one with line breaks only between paragraphs. Useful when converting downloads from <a href="https://www.gutenberg.org/">Project Gutenberg</a> to import to word processing apps that can reformat paragraphs once hard line-breaks are removed, or for loading into your Palm Pilot for portable perusal. <p> See <a href="Successful Methods of Public Speaking.txt">Successful Methods of Public Speaking.txt</a> and <a href="Successful Methods of Public Speaking(2).txt">Successful Methods of Public Speaking(2).txt</a> for a sample before and after (text file courtesy of Project Gutenberg). </li> <p> <li><a href="listAllMatches.py">listAllMatches.py</a><br> An example program showing the utility of the listAllMatches option when specifying results naming. </li> <p> <li><a href="linenoExample.py">linenoExample.py</a><br> An example program showing how to use the string location to extract line and column numbers, or the source line of text. </li> <p> <li><a href="parseListString.py">parseListString.py</a><br> An example program showing a progression of steps, how to parse a string representation of a Python list back into a true list. </li> <p> <li><a href="parsePythonValue.py">parsePythonValue.py</a><br> An extension of parseListString.py to parse tuples and dicts, including nested values, returning a Python value of the original type. </li> <p> <li><a href="indentedGrammarExample.py">indentedGrammarExample.py</a><br> An example program showing how to parse a grammar using indentation for grouping, such as is done in Python. </li> <p> <li><a href="simpleArith.py">simpleArith.py</a><br> An example program showing how to use the new operatorPrecedence helper method to define a 6-function (+, -, *, /, ^, and !) arithmetic expression parser, with unary plus and minus signs. </li> <p> <li><a href="simpleBool.py">simpleBool.py</a><br> An example program showing how to use the new operatorPrecedence helper method to define a boolean expression parser, with parse actions associated with each operator to "compile" the expression into a data structure that will evaluate the expression's boolean value. </li> <p> <li><a href="simpleWiki.py">simpleWiki.py</a><br> An example program showing how to use transformString to implement a simple Wiki markup parser. </li> <p> <li><a href="sql2dot.py">sql2dot.py</a><i>~ submission by EnErGy [CSDX]</i><br> A nice graphing program that generates schema diagrams from SQL table definition statements. </li> <p> <li><a href="htmlStripper.py">htmlStripper.py</a><br> An example implementation of a common application, removing HTML markup tags from an HTML page, leaving just the text content. </li> <p> <li><a href="macroExpansion.py">macroExpansion.py</a><br> An example implementation of a simple preprocessor, that will read embedded macro definitions and replace macro references with the defined substitution string. </li> <p> <li><a href="sexpParser.py">sexpParser.py</a><br> A parser that uses a recursive grammar to parse S-expressions. </li> <p> <li><a href="nested.py">nested.py</a><br> An example using nestedExpr, a helper method to simplify definitions of expressions of nested lists. </li> <p> <li><a href="withAttribute.py">withAttribute.py</a><br> An example using withAttribute, a helper method to define parse actions to validate matched HTML tags using additional attributes. Especially helpful for matching common tags such as <DIV> and <TD>. </li> <p> <li><a href="stackish.py">stackish.py</a><br> A parser for the data representation format, Stackish. </li> <p> <li><a href="builtin_parse_action_demo.py">builtin_parse_action_demo.py</a><br> Demonstration of using builtins (min, max, sum, len, etc.) as parse actions. </li> <p> <li><a href="antlr_grammar.py">antlr_grammar.py</a><i>~ submission by Luca DellOlio</i><br> Pyparsing example parsing ANTLR .a files and generating a working pyparsing parser. </li> <p> <li><a href="shapes.py">shapes.py</a><br> Parse actions example simple shape definition syntax, and returning the matched tokens as domain objects instead of just strings. </li> <p> <li><a href="datetimeParseActions.py">datetimeParseActions.py</a><br> Parse actions example showing a parse action returning a datetime object instead of string tokens, and doing validation of the tokens, raising a ParseException if the given YYYY/MM/DD string does not represent a valid date. </li> <p> <li><a href="position.py">position.py</a><br> Demonstration of a couple of different ways to capture the location a particular expression was found within the overall input string. </li> <p> </ul> </body></html>