orionis 0.613.0__py3-none-any.whl → 0.615.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/container/providers/service_provider.py +31 -9
- orionis/foundation/application.py +100 -61
- orionis/foundation/exceptions/application.py +51 -4
- orionis/foundation/providers/catch_provider.py +11 -32
- orionis/foundation/providers/cli_request_provider.py +13 -28
- orionis/foundation/providers/console_provider.py +14 -48
- orionis/foundation/providers/directory_provider.py +13 -39
- orionis/foundation/providers/dumper_provider.py +13 -63
- orionis/foundation/providers/executor_provider.py +13 -62
- orionis/foundation/providers/inspirational_provider.py +12 -65
- orionis/foundation/providers/logger_provider.py +15 -58
- orionis/foundation/providers/performance_counter_provider.py +13 -39
- orionis/foundation/providers/progress_bar_provider.py +11 -66
- orionis/foundation/providers/reactor_provider.py +14 -65
- orionis/foundation/providers/scheduler_provider.py +13 -35
- orionis/foundation/providers/testing_provider.py +9 -55
- orionis/foundation/providers/workers_provider.py +17 -76
- orionis/metadata/framework.py +1 -1
- orionis/support/facades/application.py +8 -10
- orionis/support/facades/console.py +8 -9
- orionis/support/facades/directory.py +9 -8
- orionis/support/facades/dumper.py +7 -8
- orionis/support/facades/executor.py +10 -11
- orionis/support/facades/inspire.py +9 -10
- orionis/support/facades/logger.py +10 -10
- orionis/support/facades/performance_counter.py +9 -8
- orionis/support/facades/progress_bar.py +10 -8
- orionis/support/facades/reactor.py +9 -9
- orionis/support/facades/testing.py +8 -9
- orionis/support/facades/workers.py +8 -8
- {orionis-0.613.0.dist-info → orionis-0.615.0.dist-info}/METADATA +1 -1
- {orionis-0.613.0.dist-info → orionis-0.615.0.dist-info}/RECORD +35 -36
- orionis/foundation/contracts/config.py +0 -31
- {orionis-0.613.0.dist-info → orionis-0.615.0.dist-info}/WHEEL +0 -0
- {orionis-0.613.0.dist-info → orionis-0.615.0.dist-info}/licenses/LICENCE +0 -0
- {orionis-0.613.0.dist-info → orionis-0.615.0.dist-info}/top_level.txt +0 -0
|
@@ -3,49 +3,27 @@ from orionis.console.tasks.schedule import Schedule
|
|
|
3
3
|
from orionis.container.providers.service_provider import ServiceProvider
|
|
4
4
|
|
|
5
5
|
class ScheduleProvider(ServiceProvider):
|
|
6
|
-
"""
|
|
7
|
-
Service provider responsible for registering and bootstrapping the application's scheduling system.
|
|
8
|
-
|
|
9
|
-
The ScheduleProvider binds the ISchedule interface to the Scheduler implementation as a singleton
|
|
10
|
-
within the application's service container. It also provides an alias for convenient access.
|
|
11
|
-
Override the `boot` method to configure and register scheduled tasks or jobs required by the application.
|
|
12
|
-
|
|
13
|
-
Methods
|
|
14
|
-
-------
|
|
15
|
-
register() :
|
|
16
|
-
Registers the Scheduler as a singleton service and binds it to the ISchedule interface.
|
|
17
|
-
boot() :
|
|
18
|
-
Initializes and configures scheduled tasks; intended to be overridden for custom jobs.
|
|
19
|
-
"""
|
|
20
6
|
|
|
21
7
|
def register(self) -> None:
|
|
22
8
|
"""
|
|
23
|
-
|
|
9
|
+
Registers the Scheduler as a singleton service in the application container.
|
|
24
10
|
|
|
25
|
-
This method binds the ISchedule interface to the
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
convenient access
|
|
11
|
+
This method binds the `ISchedule` interface to the `Schedule` implementation,
|
|
12
|
+
ensuring that a single instance of the scheduler is used throughout the application's
|
|
13
|
+
lifecycle. Additionally, it provides an alias
|
|
14
|
+
("x-orionis.console.contracts.schedule.ISchedule") for convenient access to the
|
|
15
|
+
scheduler service.
|
|
29
16
|
|
|
30
|
-
|
|
31
|
-
|
|
17
|
+
Parameters
|
|
18
|
+
----------
|
|
32
19
|
None
|
|
33
|
-
This method does not return any value.
|
|
34
|
-
"""
|
|
35
|
-
# Bind Scheduler as a singleton to the ISchedule interface with an alias
|
|
36
|
-
self.app.singleton(ISchedule, Schedule, alias=f"x-{ISchedule.__module__}.{ISchedule.__name__}")
|
|
37
|
-
|
|
38
|
-
def boot(self) -> None:
|
|
39
|
-
"""
|
|
40
|
-
Initialize and configure any scheduled tasks or jobs required by the application.
|
|
41
|
-
|
|
42
|
-
This method is called automatically during the application's bootstrapping process.
|
|
43
|
-
Override this method to register custom scheduled tasks.
|
|
44
20
|
|
|
45
21
|
Returns
|
|
46
22
|
-------
|
|
47
23
|
None
|
|
48
|
-
This method does not return any value.
|
|
24
|
+
This method does not return any value. It performs the registration as a side effect.
|
|
49
25
|
"""
|
|
50
|
-
|
|
51
|
-
|
|
26
|
+
|
|
27
|
+
# Bind the Schedule implementation as a singleton to the ISchedule interface
|
|
28
|
+
# and provide an alias for easier access within the application container.
|
|
29
|
+
self.app.singleton(ISchedule, Schedule, alias="x-orionis.console.contracts.schedule.ISchedule")
|
|
@@ -3,52 +3,21 @@ from orionis.test.contracts.unit_test import IUnitTest
|
|
|
3
3
|
from orionis.test.core.unit_test import UnitTest
|
|
4
4
|
|
|
5
5
|
class TestingProvider(ServiceProvider):
|
|
6
|
-
"""
|
|
7
|
-
Provides comprehensive unit testing environment services for the Orionis framework.
|
|
8
|
-
|
|
9
|
-
This service provider integrates a native unit testing framework into the Orionis
|
|
10
|
-
application ecosystem, enabling advanced testing capabilities with configurable
|
|
11
|
-
execution modes, parallel processing, and persistent result storage. The provider
|
|
12
|
-
registers the testing service as a singleton within the application's dependency
|
|
13
|
-
injection container, making it available throughout the application lifecycle.
|
|
14
|
-
|
|
15
|
-
The TestingProvider handles the complete lifecycle of testing services, from
|
|
16
|
-
initial configuration and test discovery to storage preparation and service
|
|
17
|
-
registration. It supports various testing patterns, execution strategies, and
|
|
18
|
-
reporting mechanisms to accommodate different testing scenarios and requirements.
|
|
19
|
-
|
|
20
|
-
Attributes
|
|
21
|
-
----------
|
|
22
|
-
app : Application
|
|
23
|
-
The Orionis application container instance that manages service registration,
|
|
24
|
-
configuration access, and dependency injection throughout the framework.
|
|
25
|
-
|
|
26
|
-
Notes
|
|
27
|
-
-----
|
|
28
|
-
This provider follows the Orionis service provider pattern, implementing both
|
|
29
|
-
register() and boot() methods to ensure proper service initialization and
|
|
30
|
-
post-registration setup. The testing service is registered with the interface
|
|
31
|
-
binding IUnitTest and can be resolved using the alias "x-orionis.test.core.unit_test".
|
|
32
|
-
|
|
33
|
-
The provider requires a valid testing configuration section in the application
|
|
34
|
-
configuration, which should include settings for verbosity, execution mode,
|
|
35
|
-
worker configuration, and storage paths.
|
|
36
|
-
"""
|
|
37
6
|
|
|
38
7
|
def register(self) -> None:
|
|
39
8
|
"""
|
|
40
|
-
|
|
9
|
+
Registers and configures the unit testing service within the application container.
|
|
41
10
|
|
|
42
|
-
This method
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
11
|
+
This method retrieves the application's testing configuration, creates an instance
|
|
12
|
+
of the UnitTest service, and registers it as a singleton in the dependency injection
|
|
13
|
+
container. The service is bound to the `IUnitTest` interface and is accessible via
|
|
14
|
+
the alias `"x-orionis.test.contracts.unit_test.IUnitTest"`.
|
|
46
15
|
|
|
47
16
|
The registration process includes:
|
|
48
|
-
- Retrieving testing configuration from the application settings.
|
|
49
|
-
- Instantiating the UnitTest service with the
|
|
17
|
+
- Retrieving the testing configuration from the application settings.
|
|
18
|
+
- Instantiating the UnitTest service with the retrieved configuration.
|
|
50
19
|
- Registering the UnitTest service as a singleton in the container.
|
|
51
|
-
- Binding the service to the IUnitTest interface and alias.
|
|
20
|
+
- Binding the service to the `IUnitTest` interface and an alias for resolution.
|
|
52
21
|
|
|
53
22
|
Returns
|
|
54
23
|
-------
|
|
@@ -59,19 +28,4 @@ class TestingProvider(ServiceProvider):
|
|
|
59
28
|
|
|
60
29
|
# Register the UnitTest service as a singleton in the application container.
|
|
61
30
|
# The service is bound to the IUnitTest interface and can be resolved using the alias.
|
|
62
|
-
self.app.singleton(IUnitTest, UnitTest, alias=
|
|
63
|
-
|
|
64
|
-
def boot(self) -> None:
|
|
65
|
-
"""
|
|
66
|
-
Finalize initialization for the testing provider after service registration.
|
|
67
|
-
|
|
68
|
-
This method is called after the registration phase to allow for any additional
|
|
69
|
-
setup required for the testing environment. In this implementation, no further
|
|
70
|
-
actions are performed during the boot phase.
|
|
71
|
-
|
|
72
|
-
Returns
|
|
73
|
-
-------
|
|
74
|
-
None
|
|
75
|
-
This method does not return any value.
|
|
76
|
-
"""
|
|
77
|
-
pass
|
|
31
|
+
self.app.singleton(IUnitTest, UnitTest, alias="x-orionis.test.contracts.unit_test.IUnitTest")
|
|
@@ -3,80 +3,16 @@ from orionis.services.system.contracts.workers import IWorkers
|
|
|
3
3
|
from orionis.services.system.workers import Workers
|
|
4
4
|
|
|
5
5
|
class WorkersProvider(ServiceProvider):
|
|
6
|
-
"""
|
|
7
|
-
Service provider for worker management functionality within the Orionis framework.
|
|
8
|
-
|
|
9
|
-
This provider is responsible for registering and configuring the worker management
|
|
10
|
-
service implementation in the application's dependency injection container. It
|
|
11
|
-
establishes the binding between the IWorkers interface contract and its concrete
|
|
12
|
-
Workers implementation, enabling consistent worker operations throughout the
|
|
13
|
-
application lifecycle.
|
|
14
|
-
|
|
15
|
-
The provider follows the standard service provider pattern, offering both
|
|
16
|
-
registration and boot phases for complete service lifecycle management.
|
|
17
|
-
|
|
18
|
-
Attributes
|
|
19
|
-
----------
|
|
20
|
-
app : Application
|
|
21
|
-
The main application container instance used for service registration
|
|
22
|
-
and dependency injection management.
|
|
23
|
-
|
|
24
|
-
Notes
|
|
25
|
-
-----
|
|
26
|
-
This provider registers the worker service with transient lifetime, ensuring
|
|
27
|
-
that each request for worker functionality receives a fresh instance. This
|
|
28
|
-
approach is optimal for worker operations that may maintain temporary state
|
|
29
|
-
or require isolation between different execution contexts.
|
|
30
|
-
"""
|
|
31
6
|
|
|
32
7
|
def register(self) -> None:
|
|
33
8
|
"""
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
This method registers the concrete Workers implementation as the service
|
|
37
|
-
provider for the IWorkers interface contract. The service is configured
|
|
38
|
-
as transient, meaning a new instance will be created each time it is
|
|
39
|
-
requested from the container. The registration includes a descriptive
|
|
40
|
-
alias for easy identification and retrieval.
|
|
41
|
-
|
|
42
|
-
Parameters
|
|
43
|
-
----------
|
|
44
|
-
None
|
|
45
|
-
|
|
46
|
-
Returns
|
|
47
|
-
-------
|
|
48
|
-
None
|
|
49
|
-
This method does not return any value. It performs registration
|
|
50
|
-
side effects on the application container.
|
|
51
|
-
|
|
52
|
-
Notes
|
|
53
|
-
-----
|
|
54
|
-
The service is registered with transient lifetime, which means:
|
|
55
|
-
- A new instance is created for each resolution request
|
|
56
|
-
- No instance caching or singleton behavior is applied
|
|
57
|
-
- Suitable for stateless or short-lived worker operations
|
|
58
|
-
"""
|
|
59
|
-
|
|
60
|
-
self.app.transient(IWorkers, Workers, alias=f"x-{IWorkers.__module__}.{IWorkers.__name__}")
|
|
61
|
-
|
|
62
|
-
def boot(self) -> None:
|
|
63
|
-
"""
|
|
64
|
-
Perform post-registration initialization for the worker management service.
|
|
65
|
-
|
|
66
|
-
This method is called after all services have been registered in the container
|
|
67
|
-
and provides an opportunity to perform any additional setup, configuration,
|
|
68
|
-
or initialization logic that depends on other services being available.
|
|
69
|
-
|
|
70
|
-
The boot phase occurs after the registration phase and allows for:
|
|
71
|
-
- Cross-service dependency configuration
|
|
72
|
-
- Service warm-up operations
|
|
73
|
-
- Additional service binding or decoration
|
|
74
|
-
- Runtime configuration validation
|
|
9
|
+
Registers the worker management service in the application container.
|
|
75
10
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
11
|
+
This method binds the `IWorkers` interface to its concrete implementation
|
|
12
|
+
`Workers` within the application's dependency injection container. The
|
|
13
|
+
registration uses a transient lifetime, ensuring that a new instance of
|
|
14
|
+
`Workers` is created each time the service is resolved. An alias is also
|
|
15
|
+
provided for convenient identification and retrieval.
|
|
80
16
|
|
|
81
17
|
Parameters
|
|
82
18
|
----------
|
|
@@ -85,14 +21,19 @@ class WorkersProvider(ServiceProvider):
|
|
|
85
21
|
Returns
|
|
86
22
|
-------
|
|
87
23
|
None
|
|
88
|
-
This method
|
|
89
|
-
|
|
24
|
+
This method does not return any value. It performs a side effect by
|
|
25
|
+
registering the service in the application container.
|
|
90
26
|
|
|
91
27
|
Notes
|
|
92
28
|
-----
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
29
|
+
- The service is registered with a transient lifetime:
|
|
30
|
+
- A new instance is created for each resolution request.
|
|
31
|
+
- No instance is cached or reused.
|
|
32
|
+
- This is suitable for stateless or short-lived worker operations.
|
|
33
|
+
- The alias used for registration is
|
|
34
|
+
"x-orionis.services.system.contracts.workers.IWorkers".
|
|
96
35
|
"""
|
|
97
36
|
|
|
98
|
-
|
|
37
|
+
# Register the Workers implementation as a transient service for IWorkers.
|
|
38
|
+
# Each resolution will create a new instance.
|
|
39
|
+
self.app.transient(IWorkers, Workers, alias="x-orionis.services.system.contracts.workers.IWorkers")
|
orionis/metadata/framework.py
CHANGED
|
@@ -1,24 +1,22 @@
|
|
|
1
1
|
from orionis.container.facades.facade import Facade
|
|
2
|
-
from orionis.foundation.contracts.application import IApplication
|
|
3
2
|
|
|
4
3
|
class Application(Facade):
|
|
5
4
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls) -> str:
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Retrieve the service container binding key for the application component.
|
|
10
9
|
|
|
11
|
-
This method
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
service implementation.
|
|
10
|
+
This class method provides the unique string identifier (binding key) that is registered
|
|
11
|
+
in the service container for the application interface. The facade uses this key to resolve
|
|
12
|
+
and access the underlying application service implementation from the dependency injection container.
|
|
15
13
|
|
|
16
14
|
Returns
|
|
17
15
|
-------
|
|
18
16
|
str
|
|
19
|
-
The
|
|
20
|
-
|
|
17
|
+
The binding key "x-orionis.foundation.contracts.application.IApplication" used to resolve
|
|
18
|
+
the application service from the service container.
|
|
21
19
|
"""
|
|
22
20
|
|
|
23
|
-
# Return the predefined binding key for the
|
|
24
|
-
return
|
|
21
|
+
# Return the predefined binding key for the application service
|
|
22
|
+
return "x-orionis.foundation.contracts.application.IApplication"
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
from orionis.console.contracts.console import IConsole
|
|
2
1
|
from orionis.container.facades.facade import Facade
|
|
3
2
|
|
|
4
3
|
class Console(Facade):
|
|
@@ -6,19 +5,19 @@ class Console(Facade):
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls) -> str:
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Returns the binding key used to resolve the console service from the service container.
|
|
10
9
|
|
|
11
|
-
This method
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
10
|
+
This method provides the unique string identifier associated with the console output
|
|
11
|
+
service in the dependency injection container. The facade uses this key to retrieve
|
|
12
|
+
the underlying implementation of the console service, enabling decoupled access to
|
|
13
|
+
console output functionality throughout the application.
|
|
15
14
|
|
|
16
15
|
Returns
|
|
17
16
|
-------
|
|
18
17
|
str
|
|
19
|
-
The
|
|
20
|
-
|
|
18
|
+
The binding key 'x-orionis.console.contracts.console.IConsole' that identifies
|
|
19
|
+
the console service in the service container.
|
|
21
20
|
"""
|
|
22
21
|
|
|
23
22
|
# Return the predefined binding key for the console output service
|
|
24
|
-
return
|
|
23
|
+
return "x-orionis.console.contracts.console.IConsole"
|
|
@@ -1,22 +1,23 @@
|
|
|
1
1
|
from orionis.container.facades.facade import Facade
|
|
2
|
-
from orionis.services.file.contracts.directory import IDirectory
|
|
3
2
|
|
|
4
3
|
class Directory(Facade):
|
|
5
4
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls):
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Returns the binding key used by the service container to resolve the directory service.
|
|
10
9
|
|
|
11
|
-
This method provides the binding key that the service container uses
|
|
12
|
-
|
|
13
|
-
the facade and the underlying service registration
|
|
10
|
+
This method provides the unique identifier (binding key) that the service container uses
|
|
11
|
+
to locate and instantiate the implementation of the directory service. It acts as a bridge
|
|
12
|
+
between the facade and the underlying service registration, ensuring that the correct
|
|
13
|
+
service is retrieved when requested.
|
|
14
14
|
|
|
15
15
|
Returns
|
|
16
16
|
-------
|
|
17
17
|
str
|
|
18
|
-
The
|
|
19
|
-
|
|
18
|
+
The binding key for the directory service implementation:
|
|
19
|
+
'x-orionis.services.file.contracts.directory.IDirectory'.
|
|
20
20
|
"""
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
# Return the unique binding key for the directory service in the container
|
|
23
|
+
return "x-orionis.services.file.contracts.directory.IDirectory"
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
from orionis.console.contracts.debug import IDebug
|
|
2
1
|
from orionis.container.facades.facade import Facade
|
|
3
2
|
|
|
4
3
|
class Dumper(Facade):
|
|
@@ -6,18 +5,18 @@ class Dumper(Facade):
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls) -> str:
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Retrieves the binding key for the dumper service in the application's service container.
|
|
10
9
|
|
|
11
|
-
This method
|
|
12
|
-
|
|
10
|
+
This method specifies the unique identifier used by the service container to resolve
|
|
11
|
+
the dumper service instance. The returned binding key allows the facade to provide
|
|
13
12
|
a static interface to the underlying dumper service implementation.
|
|
14
13
|
|
|
15
14
|
Returns
|
|
16
15
|
-------
|
|
17
16
|
str
|
|
18
|
-
The
|
|
19
|
-
|
|
17
|
+
The string "x-orionis.console.contracts.debug.IDebug", which is the binding key
|
|
18
|
+
used to identify and resolve the dumper service from the service container.
|
|
20
19
|
"""
|
|
21
20
|
|
|
22
|
-
# Return the
|
|
23
|
-
return
|
|
21
|
+
# Return the unique binding key for the dumper service in the container
|
|
22
|
+
return "x-orionis.console.contracts.debug.IDebug"
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
from orionis.console.contracts.executor import IExecutor
|
|
2
1
|
from orionis.container.facades.facade import Facade
|
|
3
2
|
|
|
4
3
|
class ConsoleExecutor(Facade):
|
|
@@ -6,20 +5,20 @@ class ConsoleExecutor(Facade):
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls) -> str:
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Retrieves the binding key used by the service container to resolve the executor service.
|
|
10
9
|
|
|
11
|
-
This method
|
|
12
|
-
|
|
13
|
-
responsible for
|
|
14
|
-
|
|
10
|
+
This method returns the unique string identifier associated with the executor service
|
|
11
|
+
in the Orionis framework's dependency injection container. The executor service is
|
|
12
|
+
responsible for managing command-line operations and console output within the framework.
|
|
13
|
+
By providing this binding key, the facade enables the framework to locate and instantiate
|
|
14
|
+
the correct executor implementation.
|
|
15
15
|
|
|
16
16
|
Returns
|
|
17
17
|
-------
|
|
18
18
|
str
|
|
19
|
-
The
|
|
20
|
-
the
|
|
21
|
-
from the dependency injection container.
|
|
19
|
+
The binding key 'x-orionis.console.contracts.executor.IExecutor' that identifies
|
|
20
|
+
the executor service in the service container.
|
|
22
21
|
"""
|
|
23
22
|
|
|
24
|
-
# Return the predefined binding key for the executor service
|
|
25
|
-
return
|
|
23
|
+
# Return the predefined binding key for the executor service in the container
|
|
24
|
+
return "x-orionis.console.contracts.executor.IExecutor"
|
|
@@ -1,24 +1,23 @@
|
|
|
1
1
|
from orionis.container.facades.facade import Facade
|
|
2
|
-
from orionis.services.inspirational.contracts.inspire import IInspire
|
|
3
2
|
|
|
4
3
|
class Inspire(Facade):
|
|
5
4
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls):
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Retrieves the service container binding key for the inspirational service.
|
|
10
9
|
|
|
11
|
-
This method
|
|
12
|
-
inspirational service implementation
|
|
13
|
-
|
|
14
|
-
|
|
10
|
+
This method provides the unique identifier used by the facade system to resolve
|
|
11
|
+
the underlying inspirational service implementation from the IoC container. The
|
|
12
|
+
returned binding key allows the facade to delegate method calls to the correct
|
|
13
|
+
service instance registered within the application.
|
|
15
14
|
|
|
16
15
|
Returns
|
|
17
16
|
-------
|
|
18
17
|
str
|
|
19
|
-
The
|
|
20
|
-
|
|
18
|
+
The binding key 'x-orionis.services.inspirational.contracts.inspire.IInspire'
|
|
19
|
+
that identifies the inspirational service in the service container.
|
|
21
20
|
"""
|
|
22
21
|
|
|
23
|
-
# Return the
|
|
24
|
-
return
|
|
22
|
+
# Return the unique binding key for the inspirational service in the IoC container
|
|
23
|
+
return "x-orionis.services.inspirational.contracts.inspire.IInspire"
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
from orionis.container.facades.facade import Facade
|
|
2
|
-
from orionis.services.log.contracts.log_service import ILogger
|
|
3
2
|
|
|
4
3
|
class Log(Facade):
|
|
5
4
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls) -> str:
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Retrieves the service container binding key for the logger service.
|
|
10
9
|
|
|
11
|
-
This method returns the
|
|
12
|
-
the logger service implementation.
|
|
13
|
-
facade and the actual service instance registered
|
|
10
|
+
This method returns the unique string identifier used by the service container
|
|
11
|
+
to resolve and provide the logger service implementation. The returned key acts
|
|
12
|
+
as a bridge between the facade and the actual logger service instance registered
|
|
13
|
+
in the dependency injection container.
|
|
14
14
|
|
|
15
15
|
Returns
|
|
16
16
|
-------
|
|
17
17
|
str
|
|
18
|
-
The
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
The string identifier
|
|
19
|
+
"x-orionis.services.log.contracts.log_service.ILogger"
|
|
20
|
+
which is used to resolve the logger service instance from the service container.
|
|
21
21
|
"""
|
|
22
22
|
|
|
23
|
-
# Return the
|
|
24
|
-
return f"x-
|
|
23
|
+
# Return the unique binding key for the logger service in the container
|
|
24
|
+
return f"x-orionis.services.log.contracts.log_service.ILogger"
|
|
@@ -1,22 +1,23 @@
|
|
|
1
1
|
from orionis.container.facades.facade import Facade
|
|
2
|
-
from orionis.support.performance.contracts.counter import IPerformanceCounter
|
|
3
2
|
|
|
4
3
|
class PerformanceCounter(Facade):
|
|
5
4
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls):
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Returns the registered binding key for the performance counter service in the service container.
|
|
10
9
|
|
|
11
|
-
This method provides the
|
|
12
|
-
|
|
13
|
-
the facade and the underlying service registration
|
|
10
|
+
This method provides the unique string identifier used by the service container to resolve
|
|
11
|
+
and retrieve the implementation of the performance counter service. It acts as the connection
|
|
12
|
+
point between the facade and the underlying service registration, ensuring that the correct
|
|
13
|
+
service is accessed when requested through the facade.
|
|
14
14
|
|
|
15
15
|
Returns
|
|
16
16
|
-------
|
|
17
17
|
str
|
|
18
|
-
The
|
|
19
|
-
|
|
18
|
+
The binding key 'x-orionis.support.performance.contracts.counter.IPerformanceCounter'
|
|
19
|
+
which identifies the performance counter service implementation in the service container.
|
|
20
20
|
"""
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
# Return the unique binding key for the performance counter service
|
|
23
|
+
return "x-orionis.support.performance.contracts.counter.IPerformanceCounter"
|
|
@@ -1,22 +1,24 @@
|
|
|
1
1
|
from orionis.container.facades.facade import Facade
|
|
2
|
-
from orionis.console.contracts.progress_bar import IProgressBar
|
|
3
2
|
|
|
4
3
|
class ProgressBar(Facade):
|
|
5
4
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls):
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Returns the service container binding key for the progress bar component.
|
|
10
9
|
|
|
11
|
-
This method
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
This method provides the unique string identifier used by the service container
|
|
11
|
+
to resolve and retrieve the progress bar implementation. The facade relies on
|
|
12
|
+
this binding key to delegate static method calls to the underlying progress bar
|
|
13
|
+
service.
|
|
14
14
|
|
|
15
15
|
Returns
|
|
16
16
|
-------
|
|
17
17
|
str
|
|
18
|
-
The
|
|
19
|
-
used to
|
|
18
|
+
The string 'x-orionis.console.contracts.progress_bar.IProgressBar', which
|
|
19
|
+
is the binding key used to obtain the progress bar service instance from
|
|
20
|
+
the service container.
|
|
20
21
|
"""
|
|
21
22
|
|
|
22
|
-
|
|
23
|
+
# Return the binding key for the progress bar service in the container
|
|
24
|
+
return "x-orionis.console.contracts.progress_bar.IProgressBar"
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
from orionis.container.facades.facade import Facade
|
|
2
|
-
from orionis.console.contracts.reactor import IReactor
|
|
3
2
|
|
|
4
3
|
class Reactor(Facade):
|
|
5
4
|
|
|
6
5
|
@classmethod
|
|
7
6
|
def getFacadeAccessor(cls) -> str:
|
|
8
7
|
"""
|
|
9
|
-
|
|
8
|
+
Returns the service container binding key for the reactor component.
|
|
10
9
|
|
|
11
|
-
This method
|
|
12
|
-
the
|
|
13
|
-
|
|
14
|
-
|
|
10
|
+
This method provides the unique identifier used by the service container
|
|
11
|
+
to resolve the implementation of the reactor component. The facade uses
|
|
12
|
+
this key to retrieve the appropriate service instance whenever static
|
|
13
|
+
methods are invoked on the facade.
|
|
15
14
|
|
|
16
15
|
Returns
|
|
17
16
|
-------
|
|
18
17
|
str
|
|
19
|
-
The
|
|
20
|
-
|
|
18
|
+
The string "x-orionis.console.contracts.reactor.IReactor", which is
|
|
19
|
+
the binding key for the reactor component in the service container.
|
|
21
20
|
"""
|
|
22
21
|
|
|
23
|
-
|
|
22
|
+
# Return the binding key for the reactor component in the service container
|
|
23
|
+
return "x-orionis.console.contracts.reactor.IReactor"
|