generated from KOLANICH/python_project_boilerplate.py
A parser for metakit4 definition string
|
KOLANICH
48c06065bc
Some checks reported warnings
CI / build (push) Has been cancelled
|
||
|---|---|---|
| .github | Initial commit | |
| pyMetakitDefinitionString | Initial commit | |
| .editorconfig | Initial commit | |
| .gitignore | Initial commit | |
| Code_Of_Conduct.md | Initial commit | |
| MANIFEST.in | Initial commit | |
| parserBundle | Initial commit | |
| pyproject.toml | Initial commit | |
| ReadMe.md | Initial commit | |
| UNLICENSE | Initial commit | |
pyMetakitDefinitionString Unlicensed work
(削除) wheel (GHA via
nightly.link) (削除ここまで)(削除) GitHub Actions (削除ここまで)
Libraries.io Status
Code style: antiflash
Parses metakit definition string.
Usage
import pyMetakitDefinitionString
d = pyMetakitDefinitionString.parse("people[first:S,last:S,shoesize:I],text[line:S]")
print(d)
[
view<name='people', bodyF=[scalar<name='first', typeF='S'>, scalar<name='last', typeF='S'>, scalar<name='shoesize', typeF='I'>]>,
view<name='text', bodyF=[scalar<name='line', typeF='S'>]>
]
Interpretation of typeF is up to you since adding a enum will not spare you from having a look-up table. See the docs.
Requirements
- UniGrammarRuntime
- Any of the backends for which parsers have been generated.
parsimoniousis recommended, as it was benchmarked as the fastest one.