mirror of
https://github.com/koloideal/Argenta.git
synced 2026-06-10 18:15:28 +03:00
last steps work on new docs, full complete write docstring for all objects
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
__all__ = ["ArgParse"]
|
||||
__all__ = ["ArgParser"]
|
||||
|
||||
|
||||
from argenta.orchestrator.argparse.entity import ArgParse
|
||||
from argenta.orchestrator.argparser.entity import ArgParser
|
||||
@@ -1,6 +1,6 @@
|
||||
__all__ = ["BooleanArgument", "PositionalArgument", "OptionalArgument"]
|
||||
|
||||
|
||||
from argenta.orchestrator.argparse.arguments.models import (BooleanArgument,
|
||||
PositionalArgument,
|
||||
OptionalArgument)
|
||||
from argenta.orchestrator.argparser.arguments.models import (BooleanArgument,
|
||||
PositionalArgument,
|
||||
OptionalArgument)
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
from argparse import ArgumentParser
|
||||
|
||||
from argenta.orchestrator.argparse.arguments.models import (BooleanArgument,
|
||||
OptionalArgument,
|
||||
PositionalArgument)
|
||||
from argenta.orchestrator.argparser.arguments.models import (BooleanArgument,
|
||||
OptionalArgument,
|
||||
PositionalArgument)
|
||||
|
||||
|
||||
class ArgParse:
|
||||
class ArgParser:
|
||||
def __init__(self,
|
||||
processed_args: list[PositionalArgument | OptionalArgument | BooleanArgument],
|
||||
name: str = 'Argenta',
|
||||
|
||||
@@ -1,24 +1,24 @@
|
||||
from argparse import Namespace
|
||||
|
||||
from argenta.app import App
|
||||
from argenta.orchestrator.argparse import ArgParse
|
||||
from argenta.orchestrator.argparser import ArgParser
|
||||
|
||||
|
||||
class Orchestrator:
|
||||
def __init__(self, arg_parser: ArgParse = False):
|
||||
def __init__(self, arg_parser: ArgParser = False):
|
||||
"""
|
||||
An orchestrator and configurator that defines the behavior of an integrated system, one level higher than the App
|
||||
Public. An orchestrator and configurator that defines the behavior of an integrated system, one level higher than the App
|
||||
:param arg_parser: Cmd argument parser and configurator at startup
|
||||
:return: None
|
||||
"""
|
||||
self.arg_parser: ArgParse | False = arg_parser
|
||||
self.arg_parser: ArgParser | False = arg_parser
|
||||
if arg_parser:
|
||||
self.arg_parser.register_args()
|
||||
|
||||
@staticmethod
|
||||
def start_polling(app: App) -> None:
|
||||
"""
|
||||
Starting the user input processing cycle
|
||||
Public. Starting the user input processing cycle
|
||||
:param app: a running application
|
||||
:return: None
|
||||
"""
|
||||
@@ -26,7 +26,7 @@ class Orchestrator:
|
||||
|
||||
def get_input_args(self) -> Namespace | None:
|
||||
"""
|
||||
Returns the arguments parsed
|
||||
Public. Returns the arguments parsed
|
||||
:return: None
|
||||
"""
|
||||
if self.arg_parser:
|
||||
|
||||
Reference in New Issue
Block a user