PipelineContext Class
A context object carried by the pipeline request and response containers.
This is transport specific and can contain data persisted between pipeline requests (for example reusing an open connection pool or "session"), as well as used by the SDK developer to carry arbitrary data through the pipeline.
Constructor
PipelineContext(transport: TransportType | None, **kwargs: Any)
Parameters
Name | Description |
---|---|
transport
Required
|
The HTTP transport type. |
kwargs
Required
|
Developer-defined keyword arguments. |
Methods
clear |
Context objects cannot be cleared. |
copy | |
fromkeys |
Create a new dictionary with keys from iterable and values set to value. |
get |
Return the value for key if key is in the dictionary, else default. |
items | |
keys | |
pop |
Removes specified key and returns the value. |
popitem |
Remove and return a (key, value) pair as a 2-tuple. Pairs are returned in LIFO (last-in, first-out) order. Raises KeyError if the dict is empty. |
setdefault |
Insert key with a value of default if key is not in the dictionary. Return the value for key if key is in the dictionary, else default. |
update |
Context objects cannot be updated. |
values |
clear
copy
copy() -> a shallow copy of D
fromkeys
Create a new dictionary with keys from iterable and values set to value.
fromkeys(value=None, /)
Positional-Only Parameters
Name | Description |
---|---|
iterable
Required
|
|
value
|
Default value: None
|
Parameters
Name | Description |
---|---|
type
Required
|
|
get
Return the value for key if key is in the dictionary, else default.
get(key, default=None, /)
Positional-Only Parameters
Name | Description |
---|---|
key
Required
|
|
default
|
Default value: None
|
items
items() -> a set-like object providing a view on D's items
keys
keys() -> a set-like object providing a view on D's keys
pop
popitem
Remove and return a (key, value) pair as a 2-tuple.
Pairs are returned in LIFO (last-in, first-out) order. Raises KeyError if the dict is empty.
popitem()
setdefault
Insert key with a value of default if key is not in the dictionary.
Return the value for key if key is in the dictionary, else default.
setdefault(key, default=None, /)
Positional-Only Parameters
Name | Description |
---|---|
key
Required
|
|
default
|
Default value: None
|
update
Context objects cannot be updated.
update(*args: Any, **kwargs: Any) -> None
Exceptions
Type | Description |
---|---|
values
values() -> an object providing a view on D's values
Azure SDK for Python