Skip to content

iter_list_components

iter_list_components(
    workspace_id: Id,
    entity_id: EntityId,
    *,
    config_overrides: Optional[IoTTwinMakerClientConfig] = None,
    component_path: Optional[ComponentPath] = None,
    max_results: Optional[MaxResults] = None,
    next_token: Optional[NextToken] = None,
) -> Iterator[ListComponentsResponse]
Source code in docs_src/capo_iottwinmaker/_services/io_t_twin_maker.py
def iter_list_components(
    self,
    workspace_id: "capo_iottwinmaker.types.id.Id",
    entity_id: "capo_iottwinmaker.types.entity_id.EntityId",
    *,
    config_overrides: Optional[IoTTwinMakerClientConfig] = None,
    component_path: Optional[
        "capo_iottwinmaker.types.component_path.ComponentPath"
    ] = None,
    max_results: Optional["capo_iottwinmaker.types.max_results.MaxResults"] = None,
    next_token: Optional["capo_iottwinmaker.types.next_token.NextToken"] = None,
) -> "Iterator[capo_iottwinmaker.types.list_components_response.ListComponentsResponse]":
    _token = next_token
    while True:
        _response = self.list_components(
            workspace_id,
            entity_id,
            config_overrides=config_overrides,
            component_path=component_path,
            max_results=max_results,
            next_token=_token,
        )
        yield _response
        _token = _resolve_path(_response, ("next_token",))
        if not _token:
            break