orionis 0.418.0__py3-none-any.whl → 0.420.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.
Files changed (136) hide show
  1. orionis/metadata/framework.py +1 -1
  2. {orionis-0.418.0.dist-info → orionis-0.420.0.dist-info}/METADATA +1 -1
  3. {orionis-0.418.0.dist-info → orionis-0.420.0.dist-info}/RECORD +58 -133
  4. {orionis-0.418.0.dist-info → orionis-0.420.0.dist-info}/top_level.txt +0 -1
  5. tests/foundation/config/app/test_foundation_config_app.py +262 -0
  6. {foundation → tests/foundation}/config/cache/test_foundation_config_cache_file.py +8 -8
  7. {foundation → tests/foundation}/config/cache/test_foundation_config_cache_stores.py +11 -3
  8. {foundation → tests/foundation}/config/database/test_foundation_config_database_pgsql.py +5 -5
  9. {foundation → tests/foundation}/config/queue/test_foundation_config_queue.py +0 -20
  10. {foundation → tests/foundation}/config/queue/test_foundation_config_queue_brokers.py +0 -13
  11. tests/foundation/config/root/test_foundation_config_root_paths.py +116 -0
  12. tests/foundation/config/startup/test_foundation_config_startup.py +199 -0
  13. foundation/config/app/test_foundation_config_app.py +0 -150
  14. foundation/config/root/test_foundation_config_root_paths.py +0 -201
  15. foundation/config/startup/test_foundation_config_startup.py +0 -205
  16. foundation/exceptions/__init__.py +0 -0
  17. foundation/exceptions/test_foundation_config_exceptions.py +0 -117
  18. orionis/_contracts/__init__.py +0 -0
  19. orionis/_contracts/application.py +0 -41
  20. orionis/_contracts/config/__init__.py +0 -0
  21. orionis/_contracts/config/config.py +0 -27
  22. orionis/_contracts/console/__init__.py +0 -0
  23. orionis/_contracts/console/base/__init__.py +0 -0
  24. orionis/_contracts/console/base/command.py +0 -437
  25. orionis/_contracts/console/command_filter.py +0 -32
  26. orionis/_contracts/console/kernel.py +0 -32
  27. orionis/_contracts/console/output/__init__.py +0 -0
  28. orionis/_contracts/console/output/console.py +0 -421
  29. orionis/_contracts/console/output/executor.py +0 -51
  30. orionis/_contracts/console/parser.py +0 -75
  31. orionis/_contracts/console/task_manager.py +0 -37
  32. orionis/_contracts/facades/__init__.py +0 -0
  33. orionis/_contracts/facades/commands/__init__.py +0 -0
  34. orionis/_contracts/facades/commands/commands_facade.py +0 -40
  35. orionis/_contracts/facades/commands/scheduler_facade.py +0 -28
  36. orionis/_contracts/facades/config/__init__.py +0 -0
  37. orionis/_contracts/facades/config/config_facade.py +0 -37
  38. orionis/_contracts/facades/environment/__init__.py +0 -0
  39. orionis/_contracts/facades/environment/environment_facade.py +0 -74
  40. orionis/_contracts/facades/facade.py +0 -38
  41. orionis/_contracts/facades/files/__init__.py +0 -0
  42. orionis/_contracts/facades/files/path_facade.py +0 -148
  43. orionis/_contracts/facades/log/__init__.py +0 -0
  44. orionis/_contracts/facades/log/log_facade.py +0 -83
  45. orionis/_contracts/facades/tests/__init__.py +0 -0
  46. orionis/_contracts/facades/tests/tests_facade.py +0 -30
  47. orionis/_contracts/foundation/__init__.py +0 -0
  48. orionis/_contracts/foundation/bootstraper.py +0 -41
  49. orionis/_contracts/foundation/config/__init__.py +0 -0
  50. orionis/_contracts/foundation/config/config_bootstrapper.py +0 -140
  51. orionis/_contracts/foundation/console/__init__.py +0 -0
  52. orionis/_contracts/foundation/console/command_bootstrapper.py +0 -81
  53. orionis/_contracts/foundation/environment/__init__.py +0 -0
  54. orionis/_contracts/foundation/environment/environment_bootstrapper.py +0 -33
  55. orionis/_contracts/foundation/providers/__init__.py +0 -0
  56. orionis/_contracts/foundation/providers/service_providers_bootstrapper.py +0 -47
  57. orionis/_contracts/providers/__init__.py +0 -0
  58. orionis/_contracts/providers/service_provider.py +0 -14
  59. orionis/_contracts/services/__init__.py +0 -0
  60. orionis/_contracts/services/commands/__init__.py +0 -0
  61. orionis/_contracts/services/commands/reactor_commands_service.py +0 -23
  62. orionis/_contracts/services/commands/schedule_service.py +0 -317
  63. orionis/_contracts/services/config/__init__.py +0 -0
  64. orionis/_contracts/services/config/config_service.py +0 -37
  65. orionis/_contracts/services/environment/__init__.py +0 -0
  66. orionis/_contracts/services/environment/environment_service.py +0 -74
  67. orionis/_contracts/services/files/__init__.py +0 -0
  68. orionis/_contracts/services/files/path_resolver_service.py +0 -29
  69. orionis/_contracts/services/log/__init__.py +0 -0
  70. orionis/_contracts/services/log/log_service.py +0 -89
  71. orionis/_contracts/support/exception_parse.py +0 -26
  72. orionis/_contracts/support/reflection.py +0 -352
  73. orionis/_foundation/__init__.py +0 -0
  74. orionis/_foundation/console/__init__.py +0 -0
  75. orionis/_foundation/console/command_bootstrapper.py +0 -175
  76. orionis/_foundation/environment/__init__.py +0 -0
  77. orionis/_foundation/environment/environment_bootstrapper.py +0 -76
  78. orionis/_foundation/exceptions/__init__.py +0 -0
  79. orionis/_foundation/exceptions/exception_bootstrapper.py +0 -54
  80. orionis/_foundation/exceptions/exception_providers.py +0 -54
  81. orionis/_foundation/foundation/config/__init__.py +0 -0
  82. orionis/_foundation/foundation/config/config_bootstrapper.py +0 -209
  83. orionis/_foundation/providers/__init__.py +0 -0
  84. orionis/_foundation/providers/service_providers_bootstrapper.py +0 -107
  85. orionis/_services/__init__.py +0 -0
  86. orionis/_services/commands/__init__.py +0 -0
  87. orionis/_services/commands/reactor_commands_service.py +0 -148
  88. orionis/_services/commands/scheduler_service.py +0 -611
  89. orionis/_services/config/__init__.py +0 -0
  90. orionis/_services/config/config_service.py +0 -72
  91. {orionis-0.418.0.dist-info → orionis-0.420.0.dist-info}/WHEEL +0 -0
  92. {orionis-0.418.0.dist-info → orionis-0.420.0.dist-info}/licenses/LICENCE +0 -0
  93. {orionis-0.418.0.dist-info → orionis-0.420.0.dist-info}/zip-safe +0 -0
  94. {foundation → tests/foundation}/__init__.py +0 -0
  95. {foundation → tests/foundation}/config/__init__.py +0 -0
  96. {foundation → tests/foundation}/config/app/__init__.py +0 -0
  97. {foundation → tests/foundation}/config/auth/__init__.py +0 -0
  98. {foundation → tests/foundation}/config/auth/test_foundation_config_auth.py +0 -0
  99. {foundation → tests/foundation}/config/cache/__init__.py +0 -0
  100. {foundation → tests/foundation}/config/cache/test_foundation_config_cache.py +0 -0
  101. {foundation → tests/foundation}/config/cors/__init__.py +0 -0
  102. {foundation → tests/foundation}/config/cors/test_foundation_config_cors.py +0 -0
  103. {foundation → tests/foundation}/config/database/__init__.py +0 -0
  104. {foundation → tests/foundation}/config/database/test_foundation_config_database.py +0 -0
  105. {foundation → tests/foundation}/config/database/test_foundation_config_database_connections.py +0 -0
  106. {foundation → tests/foundation}/config/database/test_foundation_config_database_mysql.py +0 -0
  107. {foundation → tests/foundation}/config/database/test_foundation_config_database_oracle.py +0 -0
  108. {foundation → tests/foundation}/config/database/test_foundation_config_database_sqlite.py +0 -0
  109. {foundation → tests/foundation}/config/filesystems/__init__.py +0 -0
  110. {foundation → tests/foundation}/config/filesystems/test_foundation_config_filesystems.py +0 -0
  111. {foundation → tests/foundation}/config/filesystems/test_foundation_config_filesystems_aws.py +0 -0
  112. {foundation → tests/foundation}/config/filesystems/test_foundation_config_filesystems_disks.py +0 -0
  113. {foundation → tests/foundation}/config/filesystems/test_foundation_config_filesystems_local.py +0 -0
  114. {foundation → tests/foundation}/config/filesystems/test_foundation_config_filesystems_public.py +0 -0
  115. {foundation → tests/foundation}/config/logging/__init__.py +0 -0
  116. {foundation → tests/foundation}/config/logging/test_foundation_config_logging.py +0 -0
  117. {foundation → tests/foundation}/config/logging/test_foundation_config_logging_channels.py +0 -0
  118. {foundation → tests/foundation}/config/logging/test_foundation_config_logging_chunked.py +0 -0
  119. {foundation → tests/foundation}/config/logging/test_foundation_config_logging_daily.py +0 -0
  120. {foundation → tests/foundation}/config/logging/test_foundation_config_logging_hourly.py +0 -0
  121. {foundation → tests/foundation}/config/logging/test_foundation_config_logging_monthly.py +0 -0
  122. {foundation → tests/foundation}/config/logging/test_foundation_config_logging_stack.py +0 -0
  123. {foundation → tests/foundation}/config/logging/test_foundation_config_logging_weekly.py +0 -0
  124. {foundation → tests/foundation}/config/mail/__init__.py +0 -0
  125. {foundation → tests/foundation}/config/mail/test_foundation_config_mail.py +0 -0
  126. {foundation → tests/foundation}/config/mail/test_foundation_config_mail_file.py +0 -0
  127. {foundation → tests/foundation}/config/mail/test_foundation_config_mail_mailers.py +0 -0
  128. {foundation → tests/foundation}/config/mail/test_foundation_config_mail_smtp.py +0 -0
  129. {foundation → tests/foundation}/config/queue/__init__.py +0 -0
  130. {foundation → tests/foundation}/config/queue/test_foundation_config_queue_database.py +0 -0
  131. {foundation → tests/foundation}/config/root/__init__.py +0 -0
  132. {foundation → tests/foundation}/config/session/__init__.py +0 -0
  133. {foundation → tests/foundation}/config/session/test_foundation_config_session.py +0 -0
  134. {foundation → tests/foundation}/config/startup/__init__.py +0 -0
  135. {foundation → tests/foundation}/config/testing/__init__.py +0 -0
  136. {foundation → tests/foundation}/config/testing/test_foundation_config_testing.py +0 -0
@@ -1,421 +0,0 @@
1
- from abc import ABC, abstractmethod
2
-
3
- class IConsole(ABC):
4
-
5
- @abstractmethod
6
- def success(message: str, timestamp: bool = True):
7
- """
8
- Prints a success message with a green background.
9
-
10
- Parameters
11
- ----------
12
- message : str, optional
13
- The success message to print.
14
- timestamp : bool, optional
15
- Whether to include a timestamp (default is True).
16
- """
17
- pass
18
-
19
- @abstractmethod
20
- def textSuccess(message: str):
21
- """
22
- Prints a success message in green.
23
-
24
- Parameters
25
- ----------
26
- message : str
27
- The success message to print.
28
- """
29
- pass
30
-
31
- @abstractmethod
32
- def textSuccessBold(message: str):
33
- """
34
- Prints a bold success message in green.
35
-
36
- Parameters
37
- ----------
38
- message : str
39
- The success message to print.
40
- """
41
- pass
42
-
43
- @abstractmethod
44
- def info(message: str, timestamp: bool = True):
45
- """
46
- Prints an informational message with a blue background.
47
-
48
- Parameters
49
- ----------
50
- message : str
51
- The informational message to print.
52
- timestamp : bool, optional
53
- Whether to include a timestamp (default is True).
54
- """
55
- pass
56
-
57
- @abstractmethod
58
- def textInfo(message: str):
59
- """
60
- Prints an informational message in blue.
61
-
62
- Parameters
63
- ----------
64
- message : str
65
- The informational message to print.
66
- """
67
- pass
68
-
69
- @abstractmethod
70
- def textInfoBold(message: str):
71
- """
72
- Prints a bold informational message in blue.
73
-
74
- Parameters
75
- ----------
76
- message : str
77
- The informational message to print.
78
- """
79
- pass
80
-
81
- @abstractmethod
82
- def warning(message: str, timestamp: bool = True):
83
- """
84
- Prints a warning message with a yellow background.
85
-
86
- Parameters
87
- ----------
88
- message : str
89
- The warning message to print.
90
- timestamp : bool, optional
91
- Whether to include a timestamp (default is True).
92
- """
93
- pass
94
-
95
- @abstractmethod
96
- def textWarning(message: str):
97
- """
98
- Prints a warning message in yellow.
99
-
100
- Parameters
101
- ----------
102
- message : str
103
- The warning message to print.
104
- """
105
- pass
106
-
107
- @abstractmethod
108
- def textWarningBold(message: str):
109
- """
110
- Prints a bold warning message in yellow.
111
-
112
- Parameters
113
- ----------
114
- message : str
115
- The warning message to print.
116
- """
117
- pass
118
-
119
- @abstractmethod
120
- def fail(message: str, timestamp: bool = True):
121
- """
122
- Prints a failure message with a red background.
123
-
124
- Parameters
125
- ----------
126
- message : str
127
- The failure message to print.
128
- timestamp : bool, optional
129
- Whether to include a timestamp (default is True).
130
- """
131
- pass
132
-
133
- @abstractmethod
134
- def error(message: str, timestamp: bool = True):
135
- """
136
- Prints an error message with a red background.
137
-
138
- Parameters
139
- ----------
140
- message : str
141
- The error message to print.
142
- timestamp : bool, optional
143
- Whether to include a timestamp (default is True).
144
- """
145
- pass
146
-
147
- @abstractmethod
148
- def textError(message: str):
149
- """
150
- Prints an error message in red.
151
-
152
- Parameters
153
- ----------
154
- message : str
155
- The error message to print.
156
- """
157
- pass
158
-
159
- @abstractmethod
160
- def textErrorBold(message: str):
161
- """
162
- Prints a bold error message in red.
163
-
164
- Parameters
165
- ----------
166
- message : str
167
- The error message to print.
168
- """
169
- pass
170
-
171
- @abstractmethod
172
- def textMuted(message: str):
173
- """
174
- Prints a muted (gray) message.
175
-
176
- Parameters
177
- ----------
178
- message : str
179
- The message to print.
180
- """
181
- pass
182
-
183
- @abstractmethod
184
- def textMutedBold(message: str):
185
- """
186
- Prints a bold muted (gray) message.
187
-
188
- Parameters
189
- ----------
190
- message : str
191
- The message to print.
192
- """
193
- pass
194
-
195
- @abstractmethod
196
- def textUnderline(message: str):
197
- """
198
- Prints an underlined message.
199
-
200
- Parameters
201
- ----------
202
- message : str, optional
203
- The message to print.
204
- """
205
- pass
206
-
207
- @abstractmethod
208
- def clear():
209
- """
210
- Clears the console screen.
211
- """
212
- pass
213
-
214
- @abstractmethod
215
- def clearLine():
216
- """
217
- Clears the current line in the console.
218
- """
219
- pass
220
-
221
- @abstractmethod
222
- def line():
223
- """
224
- Prints a horizontal line in the console.
225
- """
226
- pass
227
-
228
- @abstractmethod
229
- def newLine(count: int = 1):
230
- """
231
- Prints multiple new lines.
232
-
233
- Parameters
234
- ----------
235
- count : int, optional
236
- The number of new lines to print (default is 1).
237
-
238
- Raises
239
- ------
240
- ValueError
241
- If count is less than or equal to 0.
242
- """
243
- pass
244
-
245
- @abstractmethod
246
- def write(message: str):
247
- """
248
- Prints a message without moving to the next line.
249
-
250
- Parameters
251
- ----------
252
- message : str
253
- The message to print.
254
- """
255
- pass
256
-
257
- @abstractmethod
258
- def writeLine(message: str):
259
- """
260
- Prints a message and moves to the next line.
261
-
262
- Parameters
263
- ----------
264
- message : str, optional
265
- The message to print.
266
- """
267
- pass
268
-
269
- @abstractmethod
270
- def ask(question: str) -> str:
271
- """
272
- Prompts the user for input with a message and returns the user's response.
273
-
274
- Parameters
275
- ----------
276
- question : str
277
- The question to ask the user.
278
-
279
- Returns
280
- -------
281
- str
282
- The user's input, as a string.
283
- """
284
- pass
285
-
286
- @abstractmethod
287
- def confirm(question: str, default: bool = False) -> bool:
288
- """
289
- Asks a confirmation question and returns True or False based on the user's response.
290
-
291
- Parameters
292
- ----------
293
- question : str
294
- The confirmation question to ask.
295
- default : bool, optional
296
- The default response if the user presses Enter without typing a response.
297
- Default is False, which corresponds to a 'No' response.
298
-
299
- Returns
300
- -------
301
- bool
302
- The user's response, which will be True if 'Y' is entered,
303
- or False if 'N' is entered or the default is used.
304
- """
305
- pass
306
-
307
- @abstractmethod
308
- def secret(question: str) -> str:
309
- """
310
- Prompts the user for hidden input, typically used for password input.
311
-
312
- Parameters
313
- ----------
314
- question : str
315
- The prompt to ask the user.
316
-
317
- Returns
318
- -------
319
- str
320
- The user's hidden input, returned as a string.
321
- """
322
- pass
323
-
324
- @abstractmethod
325
- def table(headers: list, rows: list):
326
- """
327
- Prints a table in the console with the given headers and rows, with bold headers.
328
-
329
- Parameters
330
- ----------
331
- headers : list of str
332
- The column headers for the table.
333
- rows : list of list of str
334
- The rows of the table, where each row is a list of strings representing the columns.
335
-
336
- Raises
337
- ------
338
- ValueError
339
- If headers or rows are empty.
340
-
341
- Notes
342
- -----
343
- The table adjusts column widths dynamically, includes bold headers, and uses box-drawing characters for formatting.
344
- """
345
- pass
346
-
347
- @abstractmethod
348
- def anticipate(question: str, options: list, default=None):
349
- """
350
- Provides autocomplete suggestions based on user input.
351
-
352
- Parameters
353
- ----------
354
- question : str
355
- The prompt for the user.
356
- options : list of str
357
- The list of possible options for autocomplete.
358
- default : str, optional
359
- The default value if no matching option is found. Defaults to None.
360
-
361
- Returns
362
- -------
363
- str
364
- The chosen option or the default value.
365
-
366
- Notes
367
- -----
368
- This method allows the user to input a string, and then attempts to provide
369
- an autocomplete suggestion by matching the beginning of the input with the
370
- available options. If no match is found, the method returns the default value
371
- or the user input if no default is provided.
372
- """
373
- pass
374
-
375
- @abstractmethod
376
- def choice(question: str, choices: list, default_index: int = 0) -> str:
377
- """
378
- Allows the user to select an option from a list.
379
-
380
- Parameters
381
- ----------
382
- question : str
383
- The prompt for the user.
384
- choices : list of str
385
- The list of available choices.
386
- default_index : int, optional
387
- The index of the default choice (zero-based). Defaults to 0.
388
-
389
- Returns
390
- -------
391
- str
392
- The selected choice.
393
-
394
- Raises
395
- ------
396
- ValueError
397
- If `default_index` is out of the range of choices.
398
-
399
- Notes
400
- -----
401
- The user is presented with a numbered list of choices and prompted to select
402
- one by entering the corresponding number. If an invalid input is provided,
403
- the user will be repeatedly prompted until a valid choice is made.
404
- """
405
- pass
406
-
407
- @abstractmethod
408
- def exception(e) -> None:
409
- """
410
- Prints an exception message with detailed information.
411
-
412
- Parameters
413
- ----------
414
- exception : Exception
415
- The exception to print.
416
-
417
- Notes
418
- -----
419
- This method prints the exception type, message, and a detailed stack trace.
420
- """
421
- pass
@@ -1,51 +0,0 @@
1
- from abc import ABC, abstractmethod
2
-
3
- class IExecutor(ABC):
4
- """
5
- Interface for execution state logging.
6
-
7
- This interface defines methods for logging different execution states:
8
- "RUNNING", "DONE", and "FAIL".
9
- """
10
-
11
- @abstractmethod
12
- def running(program: str, time: str = ''):
13
- """
14
- Logs the execution of a program in a "RUNNING" state.
15
-
16
- Parameters
17
- ----------
18
- program : str
19
- The name of the program being executed.
20
- time : str, optional
21
- The time duration of execution, default is an empty string.
22
- """
23
- pass
24
-
25
- @abstractmethod
26
- def done(program: str, time: str = ''):
27
- """
28
- Logs the execution of a program in a "DONE" state.
29
-
30
- Parameters
31
- ----------
32
- program : str
33
- The name of the program being executed.
34
- time : str, optional
35
- The time duration of execution, default is an empty string.
36
- """
37
- pass
38
-
39
- @abstractmethod
40
- def fail(program: str, time: str = ''):
41
- """
42
- Logs the execution of a program in a "FAIL" state.
43
-
44
- Parameters
45
- ----------
46
- program : str
47
- The name of the program being executed.
48
- time : str, optional
49
- The time duration of execution, default is an empty string.
50
- """
51
- pass
@@ -1,75 +0,0 @@
1
- from abc import ABC, abstractmethod
2
- from typing import List, Tuple, Dict, Any
3
- import argparse
4
-
5
- class IParser(ABC):
6
- """
7
- Interface for a command-line argument parser.
8
-
9
- Defines the necessary methods for a command-line parser, ensuring
10
- consistency across implementations.
11
- """
12
-
13
- @abstractmethod
14
- def __init__(self, vars: Dict[str, Any], args: Tuple[Any, ...], kwargs: Dict[str, Any]):
15
- """
16
- Initializes the parser.
17
-
18
- Parameters
19
- ----------
20
- vars : dict
21
- A dictionary containing additional variables.
22
- args : tuple
23
- A tuple containing command-line arguments.
24
- kwargs : dict
25
- A dictionary containing keyword arguments.
26
- """
27
- pass
28
-
29
- @abstractmethod
30
- def setArguments(self, arguments: List[Tuple[str, Dict[str, Any]]]) -> None:
31
- """
32
- Registers command-line arguments dynamically.
33
-
34
- Parameters
35
- ----------
36
- arguments : list of tuple
37
- A list of tuples where each tuple contains:
38
- - str: The argument name (e.g., '--value')
39
- - dict: A dictionary of options (e.g., {'type': int, 'required': True})
40
-
41
- Raises
42
- ------
43
- ValueError
44
- If an argument is already registered.
45
- """
46
- pass
47
-
48
- @abstractmethod
49
- def recognize(self) -> None:
50
- """
51
- Processes and formats command-line arguments before parsing.
52
-
53
- Raises
54
- ------
55
- ValueError
56
- If an argument does not follow the correct format.
57
- """
58
- pass
59
-
60
- @abstractmethod
61
- def get(self) -> argparse.Namespace:
62
- """
63
- Parses the collected command-line arguments.
64
-
65
- Returns
66
- -------
67
- argparse.Namespace
68
- The parsed arguments as an object where each argument is an attribute.
69
-
70
- Raises
71
- ------
72
- ValueError
73
- If required arguments are missing or an error occurs during parsing.
74
- """
75
- pass
@@ -1,37 +0,0 @@
1
- from abc import ABC, abstractmethod
2
- from orionis._facades.commands.scheduler_facade import Schedule
3
-
4
- class ITaskManager(ABC):
5
- """
6
- Abstract base class that defines the interface for managing tasks.
7
-
8
- This class provides an abstract method `schedule` that must be implemented by any
9
- subclass to define how tasks are scheduled.
10
-
11
- Methods
12
- -------
13
- schedule(schedule: Schedule) -> None
14
- Schedules a task based on the provided `Schedule` instance.
15
- """
16
-
17
- @abstractmethod
18
- def schedule(self, schedule: Schedule) -> None:
19
- """
20
- Schedules a task based on the given `Schedule` instance.
21
-
22
- This method is abstract and must be implemented by a subclass to define
23
- the specific scheduling logic.
24
-
25
- Parameters
26
- ----------
27
- schedule : Schedule
28
- An instance of the `Schedule` class, which contains the details of
29
- when and how the task should be executed.
30
-
31
- Returns
32
- -------
33
- None
34
- This method does not return anything, but it is expected to schedule
35
- the task as defined by the `schedule` object.
36
- """
37
- pass
File without changes
File without changes
@@ -1,40 +0,0 @@
1
- from abc import ABC, abstractmethod
2
- from typing import Any
3
-
4
- class ICommand(ABC):
5
- """
6
- Interface for defining a CLI command.
7
- Command class for managing and executing registered CLI commands.
8
-
9
- This class provides a static method to invoke commands registered in the
10
- `CacheCommands` singleton, passing the required signature and any additional
11
- parameters.
12
-
13
- Methods
14
- -------
15
- call(signature: str, vars: dict[str, Any] = {}, *args: Any, **kwargs: Any) -> Any
16
- Executes the specified command with the provided arguments.
17
- """
18
-
19
- @abstractmethod
20
- def call(signature: str, vars: dict[str, Any] = {}, *args: Any, **kwargs: Any) -> Any:
21
- """
22
- Calls a registered command using the `CLIRunner`.
23
-
24
- Parameters
25
- ----------
26
- signature : str
27
- The command signature (name) to execute.
28
- vars : dict[str, Any], optional
29
- A dictionary containing named arguments for the command (default is `{}`).
30
- *args : Any
31
- Additional positional arguments.
32
- **kwargs : Any
33
- Additional keyword arguments.
34
-
35
- Returns
36
- -------
37
- Any
38
- The output of the executed command.
39
- """
40
- pass
@@ -1,28 +0,0 @@
1
- from abc import ABC, abstractmethod
2
- from typing import Any
3
- from orionis._services.commands.scheduler_service import ScheduleService
4
-
5
- class ISchedule(ABC):
6
-
7
- @abstractmethod
8
- def command(signature: str, vars: dict[str, Any] = {}, *args: Any, **kwargs: Any) -> 'ScheduleService':
9
- """
10
- Defines a Orionis command to be executed.
11
-
12
- Parameters
13
- ----------
14
- signature : str
15
- The signature of the command to execute.
16
- vars : dict, optional
17
- A dictionary of variables to pass to the command, by default an empty dictionary.
18
- *args : Any
19
- Additional positional arguments to pass to the command.
20
- **kwargs : Any
21
- Additional keyword arguments to pass to the command.
22
-
23
- Returns
24
- -------
25
- Schedule
26
- Returns the Schedule instance itself, allowing method chaining.
27
- """
28
- pass
File without changes
@@ -1,37 +0,0 @@
1
- from abc import ABC, abstractmethod
2
- from typing import Any, Optional
3
-
4
- class IConfig(ABC):
5
-
6
- @abstractmethod
7
- def set(key: str, value: Any) -> None:
8
- """
9
- Dynamically sets a configuration value using dot notation.
10
-
11
- Parameters
12
- ----------
13
- key : str
14
- The configuration key (e.g., 'app.debug').
15
- value : Any
16
- The value to set.
17
- """
18
- pass
19
-
20
- @abstractmethod
21
- def get(key: str, default: Optional[Any] = None) -> Any:
22
- """
23
- Retrieves a configuration value using dot notation.
24
-
25
- Parameters
26
- ----------
27
- key : str
28
- The configuration key (e.g., 'app.debug').
29
- default : Optional[Any]
30
- The default value to return if the key is not found.
31
-
32
- Returns
33
- -------
34
- Any
35
- The configuration value or the default value if the key is not found.
36
- """
37
- pass
File without changes