orionis 0.11.0__py3-none-any.whl → 0.12.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
orionis/framework.py CHANGED
@@ -5,7 +5,7 @@
5
5
  NAME = "orionis"
6
6
 
7
7
  # Current version of the framework
8
- VERSION = "0.11.0"
8
+ VERSION = "0.12.0"
9
9
 
10
10
  # Full name of the author or maintainer of the project
11
11
  AUTHOR = "Raul Mauricio Uñate Castro"
@@ -0,0 +1,29 @@
1
+ class DotDict(dict):
2
+
3
+ """
4
+ A dictionary subclass that allows access to dictionary values using dot notation, with handling for missing keys.
5
+ This class extends the built-in `dict` class to provide attribute-style access to dictionary keys. If a key is not found,
6
+ it returns `None` instead of raising a `KeyError`. Additionally, nested dictionaries are automatically converted to `DotDict`
7
+ instances.
8
+ Methods
9
+ -------
10
+ __getattr__(item)
11
+ Retrieves the value associated with the given key using dot notation. If the key does not exist, returns `None`.
12
+ If the value is a dictionary, it is converted to a `DotDict` instance.
13
+ """
14
+
15
+ def __getattr__(self, item):
16
+ """
17
+ Retrieves the value associated with the given key using dot notation. If the key does not exist, returns `None`.
18
+ If the value is a dictionary, it is converted to a `DotDict` instance.
19
+ """
20
+
21
+ # Retrieve the value associated with the key
22
+ value = self.get(item, None)
23
+
24
+ # If the value is a dictionary, convert it to a DotDict instance
25
+ if isinstance(value, dict):
26
+ return DotDict(value)
27
+
28
+ # Otherwise, return the value
29
+ return value
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: orionis
3
- Version: 0.11.0
3
+ Version: 0.12.0
4
4
  Summary: Orionis Framework – Elegant, Fast, and Powerful.
5
5
  Home-page: https://github.com/orionis-framework/framework
6
6
  Author: Raul Mauricio Uñate Castro
@@ -1,6 +1,6 @@
1
1
  orionis/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  orionis/cli_manager.py,sha256=9wNVJxB0HyqUbNesUvkwlsqTyUbZwK6R46iVLE5WVBQ,1715
3
- orionis/framework.py,sha256=AMBen4p24cxXgu6cbkcdFlTvXrH2xvCTHlnNJ_Ox2y8,1386
3
+ orionis/framework.py,sha256=0PfcpqxgaqMKGcrPylxJ2h-F7e-qedPqVODIJ9voYYw,1386
4
4
  orionis/luminate/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
5
  orionis/luminate/app.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
6
  orionis/luminate/bootstrap/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -130,15 +130,16 @@ orionis/luminate/test/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3h
130
130
  orionis/luminate/test/exception.py,sha256=VJaZ7VMZfdKW1ov_GwKp2HAz_NYobujJxDt5RaPHuVQ,1395
131
131
  orionis/luminate/test/unit_test.py,sha256=3zemWa150SfxcXhs1n1TjYvbfLgwqJjhwFPnUlLLtgg,3738
132
132
  orionis/luminate/tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
133
+ orionis/luminate/tools/dot_dict.py,sha256=FVHfBuAGTTVMjNG01Fix645fRNKKUMmNx61pYkxPL5c,1253
133
134
  orionis/luminate/tools/reflection.py,sha256=3G4nZIE73LDtGJLlq9U_P9O2FnTi5-wr9s00CVAmjFw,11959
134
135
  orionis/luminate/tools/std.py,sha256=wquV7xgT1tvSRpbrq5h_GQwCof9cXjen-vuWPubAKbs,1398
135
136
  tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
136
137
  tests/tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
137
138
  tests/tools/class_example.py,sha256=dIPD997Y15n6WmKhWoOFSwEldRm9MdOHTZZ49eF1p3c,1056
138
139
  tests/tools/test_reflection.py,sha256=dNN5p_xAosyEf0ddAElmmmTfhcTtBd4zBNl7qzgnsc0,5242
139
- orionis-0.11.0.dist-info/LICENCE,sha256=-_4cF2EBKuYVS_SQpy1uapq0oJPUU1vl_RUWSy2jJTo,1111
140
- orionis-0.11.0.dist-info/METADATA,sha256=YpHiqFF7lhdDFFFQVhht8GxBDIR6UnHg6NCCrzZemTQ,2978
141
- orionis-0.11.0.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
142
- orionis-0.11.0.dist-info/entry_points.txt,sha256=eef1_CVewfokKjrGBynXa06KabSJYo7LlDKKIKvs1cM,53
143
- orionis-0.11.0.dist-info/top_level.txt,sha256=2bdoHgyGZhOtLAXS6Om8OCTmL24dUMC_L1quMe_ETbk,14
144
- orionis-0.11.0.dist-info/RECORD,,
140
+ orionis-0.12.0.dist-info/LICENCE,sha256=-_4cF2EBKuYVS_SQpy1uapq0oJPUU1vl_RUWSy2jJTo,1111
141
+ orionis-0.12.0.dist-info/METADATA,sha256=kw9wVVT8350_39BpeHBTzoOWtlvUEzeDwVtfdkKPFLA,2978
142
+ orionis-0.12.0.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
143
+ orionis-0.12.0.dist-info/entry_points.txt,sha256=eef1_CVewfokKjrGBynXa06KabSJYo7LlDKKIKvs1cM,53
144
+ orionis-0.12.0.dist-info/top_level.txt,sha256=2bdoHgyGZhOtLAXS6Om8OCTmL24dUMC_L1quMe_ETbk,14
145
+ orionis-0.12.0.dist-info/RECORD,,