Skip to content

Examples#

Index > ARCZonalShift > Examples

Auto-generated documentation for ARCZonalShift type annotations stubs module types-boto3-arc-zonal-shift.

Client#

Implicit type annotations#

Can be used with types-boto3[arc-zonal-shift] package installed.

Write your ARCZonalShift code as usual, type checking and code completion should work out of the box.

Client method usage example#

# ARCZonalShiftClient usage example

from boto3.session import Session


session = Session()

client = session.client("arc-zonal-shift")  # (1)
result = client.cancel_practice_run()  # (2)
  1. client: ARCZonalShiftClient
  2. result: CancelPracticeRunResponseTypeDef

Paginator usage example#

# ListAutoshiftsPaginator usage example

from boto3.session import Session


session = Session()
client = session.client("arc-zonal-shift")  # (1)

paginator = client.get_paginator("list_autoshifts")  # (2)
for item in paginator.paginate(...):
    print(item)  # (3)
  1. client: ARCZonalShiftClient
  2. paginator: ListAutoshiftsPaginator
  3. item: ListAutoshiftsResponseTypeDef

Explicit type annotations#

With types-boto3-lite[arc-zonal-shift] or a standalone types_boto3_arc_zonal_shift package, you have to explicitly specify client: ARCZonalShiftClient type annotation.

All other type annotations are optional, as types should be discovered automatically. However, these type annotations can be helpful in your functions and methods.

Client method usage example#

# ARCZonalShiftClient usage example with type annotations

from boto3.session import Session

from types_boto3_arc_zonal_shift.client import ARCZonalShiftClient
from types_boto3_arc_zonal_shift.type_defs import CancelPracticeRunResponseTypeDef
from types_boto3_arc_zonal_shift.type_defs import CancelPracticeRunRequestTypeDef


session = Session()

client: ARCZonalShiftClient = session.client("arc-zonal-shift")

kwargs: CancelPracticeRunRequestTypeDef = {...}
result: CancelPracticeRunResponseTypeDef = client.cancel_practice_run(**kwargs)

Paginator usage example#

# ListAutoshiftsPaginator usage example with type annotations

from boto3.session import Session

from types_boto3_arc_zonal_shift.client import ARCZonalShiftClient
from types_boto3_arc_zonal_shift.paginator import ListAutoshiftsPaginator
from types_boto3_arc_zonal_shift.type_defs import ListAutoshiftsResponseTypeDef


session = Session()
client: ARCZonalShiftClient = session.client("arc-zonal-shift")

paginator: ListAutoshiftsPaginator = client.get_paginator("list_autoshifts")
for item in paginator.paginate(...):
    item: ListAutoshiftsResponseTypeDef
    print(item)