An (extremly) simple Meta-Language, this is the parser!
Project description
E-Z Meta-Language / Python Parser
What Is E-Z MetaLanguage/Parser?
E-Z Meta-Language is an extremely simple(or "e-z"), xml-flavored, data storage + aquisition method, revolving around this parser, written in Python.
At this point, general usage is simply variable storage.
Basic usage:
Example .ezml file(test.ezml):
<ezml>
<meta>
Author: Example Author
Info: Class Schedule
Date: January 17th, 2020
</meta>
<var title>Campus #1 Weekly Schedule Example</title>
<var monday>No School</monday>
<var tuesday>
class 1: history
class 2: science
</tuesday>
<var wednesday>Not On Campus</wednesday>
<var thursday>
class 1: history
class 2: science
</thursday>
<var friday>
class 1: history
class 2: ap-history
class 3: science
</friday>
</ezml>
Parsing Example (From File) :
from ezml import *
ezml = EZML(utils.dump_file('test.ezml'))
print(ezml.meta)
print(ezml.var['title'])
print(ezml.var['monday'])
print(f"Tuesdays Schedule:\n {ezml.var['tuesday']}")
Parsing Example (From String):
from ezml import EZML
ezml = EZML("<ezml><meta>Title: Hello World!</meta><var title>Foo<title><var bar>Hello World!</bar></ezml>")
print(ezml.meta)
print(ezml.var['title'])
print(ezml.var['bar'])
Getting Current Version:
from ezml import utils
print(utils.version)
Thanks for using E-Z MetaLanguage!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ezml-1.1.2.tar.gz
(3.1 kB
view details)
Built Distribution
ezml-1.1.2-py3-none-any.whl
(4.0 kB
view details)
File details
Details for the file ezml-1.1.2.tar.gz
.
File metadata
- Download URL: ezml-1.1.2.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/45.0.0 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | eebadb108fced57587d6daed2f65ed5b05e070d781a2f05ae0e7036ac7e7b90f |
|
MD5 | 1e51c3febfc2ebe1b97dc920d41e907b |
|
BLAKE2b-256 | 11e894bd34855d761455b8f41d645be92e0aa167bf02a5142dc1658e6223f3f0 |
File details
Details for the file ezml-1.1.2-py3-none-any.whl
.
File metadata
- Download URL: ezml-1.1.2-py3-none-any.whl
- Upload date:
- Size: 4.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/45.0.0 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bb217d324635fcd7d21993dfb590e0acc6aaa46f9ce65aa74e8a8dd07c7b27d7 |
|
MD5 | bbf90cb8534570143f7c6a50ee2b178c |
|
BLAKE2b-256 | f6dbf7118e39349a88466a2e91419419a7a232ffd5633482fa6ffdd3659873ac |