class documentation

class _FrameFiling(ROS2SpatialMixin):

Constructor: _FrameFiling(*args, **kwargs)

View In Hierarchy

Creates Locations and files them under a SpatialObject, through the mutation chokepoint.

Method __init__ Start out with nothing rendered, and pass every argument to opensmi.
Async Method _admit Put one tick's new Locations through the declaring item's chokepoint.
Method _alternative_base Return the node one alternative's base frame is, or None when it has none.
Method _base_node Return the node one Location's Base points at.
Async Method _create_new_locations Create a Location for every frame this object owns and has not rendered yet.
Async Method _file File one Location in one of the three frame folders of a SpatialObject.
Method _location_type Return the NodeId of the type a Location is instantiated as, for a model change.
Async Method _mark_constant Set the constant access bit on one static frame's value, so nobody subscribes to it.
Async Method _open_alternative Create one composed Location in AlternativeFrames, through the chokepoint.
Async Method _open_composed Create the node one alternative is, and record it.
Async Method _open_location Create one Location and record it, with its Base already set.
Async Method _opened_folders Return the folder nodes opensmi created with a batch, for the model change.
Async Method _report_absent_base Say, once, that a declared alternative has no base node to be relative to.
Async Method _report_frame_collision Say, as a BindingEvent, that a frame has no Location because its name is taken. Once per frame.
Method _require_world Return the list's World Frame node, which every Base terminates at.
Instance Variable _transform_index Undocumented
Instance Variable _transform_objects Undocumented
Instance Variable _transform_world Undocumented
Property _rsl_namespace Return the index this server imported OPC 10000-210's namespace at.
def __init__(self, *args: Any, **kwargs: Any):

Start out with nothing rendered, and pass every argument to opensmi.

async def _admit(self, owner: _Owner, planned: Sequence[tuple[str, str, str]], *, parents: Mapping[str, str]) -> bool:

Put one tick's new Locations through the declaring item's chokepoint.

The declaring item's cap applies and its Notification gets the BindingEvents. The Machine-wide tally counts too.

def _alternative_base(self, base: str, frames: Mapping[str, FrameLink]) -> ua.NodeId | None:

Return the node one alternative's base frame is, or None when it has none.

It is never re-based onto an ancestor, because the pose was composed against that frame. The root of the TF tree is the list's World Frame.

def _base_node(self, frame: str, *, parents: Mapping[str, str]) -> ua.NodeId:

Return the node one Location's Base points at.

Delegates to ~opensmi.ros2.server.spatial.base_node_of and adds the frame index and World Frame node of the live Machine.

async def _create_new_locations(self, owner: _Owner, *, parents: Mapping[str, str], attach: frozenset[str]):

Create a Location for every frame this object owns and has not rendered yet.

One chokepoint call per tick, so a client gets one model change naming all the new frames.

async def _file(self, owner: _Owner, folder: str, location: _Observed):

File one Location in one of the three frame folders of a SpatialObject.

attach_points is used only for a real attach point, because 6.1.1 forbids using an internal frame as one. The folder's add is used instead of add_internal_frame and its siblings, because those build a plain CartesianFrame and a Location here is a subclass.

def _location_type(self) -> ua.NodeId:

Return the NodeId of the type a Location is instantiated as, for a model change.

That is CartesianFrameAngleOrientationType, the angle-based subtype opensmi's CartesianFrame is.

async def _mark_constant(self, node: Node):

Set the constant access bit on one static frame's value, so nobody subscribes to it.

This reaches into asyncua's address space, because asyncua gives no node an AccessLevelEx attribute and writing one through Node fails with BadAttributeIdInvalid. The bit goes on the Location, its Position and Orientation and their scalars, not on the Base, which moves when the tree is re-partitioned.

async def _open_alternative(self, owner: _Owner, base: str, frame: str, node: ua.NodeId) -> _Frame | None:

Create one composed Location in AlternativeFrames, through the chokepoint.

async def _open_composed(self, owner: _Owner, base: str, frame: str, browse: str, node: ua.NodeId) -> Node:

Create the node one alternative is, and record it.

async def _open_location(self, owner: _Owner, frame: str, browse: str, folder: str, *, parents: Mapping[str, str]) -> tuple[Node, ua.NodeId | int]:

Create one Location and record it, with its Base already set.

A client therefore never sees the new Location at the World Frame.

async def _opened_folders(self, owner: _Owner, names: set[str]) -> list[tuple[Node, ua.NodeId | int]]:

Return the folder nodes opensmi created with a batch, for the model change.

opensmi creates a folder on first use, so it is found after the batch. Recording it keeps later batches from counting or announcing it again.

async def _report_absent_base(self, owner: _Owner, base: str, frame: str):

Say, once, that a declared alternative has no base node to be relative to.

async def _report_frame_collision(self, owner: _Owner, frame: str, browse: str, taken: str | None):

Say, as a BindingEvent, that a frame has no Location because its name is taken. Once per frame.

def _require_world(self) -> ua.NodeId:

Return the list's World Frame node, which every Base terminates at.

Raises
DeclarationErrorWhen the mirror was never initialised, which is a Machine with no spatial-object list and is refused long before this.
_transform_index: dict[str, ua.NodeId] =

Undocumented

_transform_objects: tuple[_Owner, ...] =

Undocumented

_transform_world: ua.NodeId | None =

Undocumented

@property
_rsl_namespace: int =

Return the index this server imported OPC 10000-210's namespace at.