Skip to content

Paginators#

Index > MQ > Paginators

Auto-generated documentation for MQ type annotations stubs module mypy-boto3-mq.

ListBrokersPaginator#

Type annotations and code completion for boto3.client("mq").get_paginator("list_brokers"). boto3 documentation

# ListBrokersPaginator usage example

from boto3.session import Session

from mypy_boto3_mq.paginator import ListBrokersPaginator

def get_list_brokers_paginator() -> ListBrokersPaginator:
    return Session().client("mq").get_paginator("list_brokers")
# ListBrokersPaginator usage example with type annotations

from boto3.session import Session

from mypy_boto3_mq.paginator import ListBrokersPaginator

session = Session()

client = Session().client("mq")  # (1)
paginator: ListBrokersPaginator = client.get_paginator("list_brokers")  # (2)
for item in paginator.paginate(...):
    print(item)  # (3)
  1. client: MQClient
  2. paginator: ListBrokersPaginator
  3. item: ListBrokersResponseTypeDef

paginate#

Type annotations and code completion for ListBrokersPaginator.paginate method.

# paginate method definition

def paginate(
    self,
    *,
    PaginationConfig: PaginatorConfigTypeDef = ...,  # (1)
) -> _PageIterator[ListBrokersResponseTypeDef]:  # (2)
    ...
  1. See PaginatorConfigTypeDef
  2. See ListBrokersResponseTypeDef
# paginate method usage example with argument unpacking

kwargs: ListBrokersRequestListBrokersPaginateTypeDef = {  # (1)
    "PaginationConfig": ...,
}

parent.paginate(**kwargs)
  1. See ListBrokersRequestListBrokersPaginateTypeDef