class documentation

class ACMEContainerTree(Container):

Constructor: ACMEContainerTree(id)

View In Hierarchy

The Resources tree view for the ACME text UI.

Method __init__ Initialize the view.
Method action_refresh_resources Handle the Refresh action.
Method compose Build the view.
Method on_click Handle Click events.
Method on_show Handle the show event.
Async Method on_tabbed_content_tab_activated Handle TabActivated message sent by TabbedContent.
Method refreshCurrentNode Refresh the current node.
Method refreshCurrentParrentNode Refresh the parent node of the current node.
Method setResourceHeader Set the header of the resource view.
Method setResourceSubtitle Set the subtitle of the resource view.
Method update Update the whole tree view.
Method updateResource Update the resource view.
Method updateResourceView Update the resource view with a value or an error message.
Constant BINDINGS Key bindings for the Resources view.
Class Variable dispatcher Injected Dispatcher instance.
Class Variable treeTabResourceID The ID of the resource tab.
Class Variable validator Injected Validator instance.
Instance Variable currentResource The current resource.
Property createView Return the CREATE view.
Property deleteView Return the DELETE view.
Property diagram Return the diagram view.
Property requestView Return the requests view.
Property resourceContainer Return the resource container.
Property resourceTree Return the resource tree.
Property resourceView Return the resource view.
Property servicesView Return the services view.
Property tabs Return the tabs.
Property updateView Return the UPDATE view.
Method _update_requests Update the requests view.
Instance Variable _app The application.
Instance Variable _resourceView The resource view.
Instance Variable _resourceViewContainer The container for the resource view.
Instance Variable _treeTabCreate The CREATE request tab.
Instance Variable _treeTabDelete The DELETE request tab.
Instance Variable _treeTabDiagram The diagram tab.
Instance Variable _treeTabDiagramView The diagram view for the diagram tab.
Instance Variable _treeTabRequests The requests tab.
Instance Variable _treeTabRequestsView The requests view for the requests tab.
Instance Variable _treeTabResourceCreate The CREATE view for the CREATE request tab.
Instance Variable _treeTabResourceDelete The DELETE view for the DELETE request tab.
Instance Variable _treeTabResourceServices The services view for the services tab.
Instance Variable _treeTabResourceUpdate The UPDATE view for the UPDATE request tab.
Instance Variable _treeTabs The tabs of the tree view.
Instance Variable _treeTabServices The services tab.
Instance Variable _treeTabUpdate The UPDATE request tab.
Instance Variable _treeView The tree view.
def __init__(self, id: str):

Initialize the view.

Parameters
id:strThe view ID.
def action_refresh_resources(self):

Handle the Refresh action.

def compose(self) -> ComposeResult:

Build the view.

Yields
The view content.
def on_click(self, event: events.Click):

Handle Click events.

Parameters
event:events.ClickThe Click event.
def on_show(self):

Handle the show event.

async def on_tabbed_content_tab_activated(self, event: TabbedContent.TabActivated):

Handle TabActivated message sent by TabbedContent.

Parameters
event:TabbedContent.TabActivatedThe TabActivated event.
def refreshCurrentNode(self):

Refresh the current node.

def refreshCurrentParrentNode(self):

Refresh the parent node of the current node.

def setResourceHeader(self, header: str):

Set the header of the resource view.

Parameters
header:strThe header to set.
def setResourceSubtitle(self, subtitle: str):

Set the subtitle of the resource view.

Parameters
subtitle:strThe subtitle to set.
def update(self):

Update the whole tree view.

def updateResource(self, resource: Resource | None = None):

Update the resource view.

Parameters
resource:Resource | NoneThe resource to update.
def updateResourceView(self, value: str | Resource | None = None, error: str | None = None):

Update the resource view with a value or an error message.

Parameters
value:str | Resource | NoneThe value to display.
error:str | NoneThe error message to display.
BINDINGS =

Key bindings for the Resources view.

Value
[Binding('r', 'refresh_resources', 'Refresh')]
dispatcher: Dispatcher =

Injected Dispatcher instance.

treeTabResourceID: str =

The ID of the resource tab.

validator: Validator =

Injected Validator instance.

currentResource: Resource =

The current resource.

@property
createView: ACMEContainerCreate =

Return the CREATE view.

Returns
The CREATE view.
@property
deleteView: ACMEContainerDelete =

Return the DELETE view.

Returns
The DELETE view.
@property
diagram: ACMEContainerDiagram =

Return the diagram view.

Returns
The diagram view.
@property
requestView: ACMEViewRequests =

Return the requests view.

Returns
The requests view.
@property
resourceContainer: Container =

Return the resource container.

Returns
The resource container
@property
resourceTree: ACMEResourceTree =

Return the resource tree.

Returns
The resource tree.
@property
resourceView: Static =

Return the resource view.

Returns
The resource view.
@property
servicesView: ACMEContainerResourceServices =

Return the services view.

Returns
The services view.
@property
tabs: TabbedContent =

Return the tabs.

Returns
The tabs.
@property
updateView: ACMEContainerUpdate =

Return the UPDATE view.

Returns
The UPDATE view.
def _update_requests(self, ri: str | None = None):

Update the requests view.

Parameters
ri:str | NoneThe resource id to set as the current resource.
_app =

The application.

_resourceView =

The resource view.

_resourceViewContainer =

The container for the resource view.

_treeTabCreate =

The CREATE request tab.

_treeTabDelete =

The DELETE request tab.

_treeTabDiagram =

The diagram tab.

_treeTabDiagramView =

The diagram view for the diagram tab.

_treeTabRequests =

The requests tab.

_treeTabRequestsView =

The requests view for the requests tab.

_treeTabResourceCreate =

The CREATE view for the CREATE request tab.

_treeTabResourceDelete =

The DELETE view for the DELETE request tab.

_treeTabResourceServices =

The services view for the services tab.

_treeTabResourceUpdate =

The UPDATE view for the UPDATE request tab.

_treeTabs =

The tabs of the tree view.

_treeTabServices =

The services tab.

_treeTabUpdate =

The UPDATE request tab.

_treeView =

The tree view.