-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
hxlm (#11): started HMeta class, hxlm.core.model.meta
- Loading branch information
Showing
6 changed files
with
86 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
"""hxlm is (TODO: document) | ||
""" | ||
|
||
__version__="0.7.1" | ||
__version__="0.7.2" | ||
|
||
import hxlm.core.constant | ||
import hxlm.core.exception | ||
import hxlm.core.base | ||
import hxlm.core.model | ||
|
||
# Users need to explicitly call this | ||
import hxlm.core.compliance |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
"""TODO: document me | ||
""" | ||
from hxlm.core.model.base import * | ||
from hxlm.core.model.meta import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
"""hxlm.core.model.meta contans HMeta | ||
Copyleft 🄯 2021, Emerson Rocha (Etica.AI) <[email protected]> | ||
License: Public Domain / BSD Zero Clause License | ||
SPDX-License-Identifier: Unlicense OR 0BSD | ||
""" | ||
|
||
|
||
class HMeta: | ||
"""HMeta is the main entry point to glue collections of HConteiner and etc | ||
In practice, is mostly used to, with help with external utils, abstract | ||
hmeta.yml from disk | ||
""" | ||
|
||
def __init__(self, schemas_raw=None): | ||
self.kind: str = 'HMeta' | ||
self._schemas_raw = schemas_raw | ||
|
||
def export_schemas(self): | ||
return self._schemas_raw | ||
|
||
def load_schemas(self, schemas_raw): | ||
"""load_schemas load object and convert to HMeta | ||
How the object is saved on disk (or received from external sources) | ||
is out of scope of this class. | ||
Args: | ||
schemas (Object): Load generic object to HMeta | ||
""" | ||
self._schemas_raw = schemas_raw | ||
# print(schemas) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters