pub struct Client { /* private fields */ }
Expand description
Client for Amazon Managed Blockchain
Client for invoking operations on Amazon Managed Blockchain. Each operation on Amazon Managed Blockchain is a method on this
this struct. .send()
MUST be invoked on the generated operations to dispatch the request to the service.
§Constructing a Client
A Config
is required to construct a client. For most use cases, the aws-config
crate should be used to automatically resolve this config using
aws_config::load_from_env()
, since this will resolve an SdkConfig
which can be shared
across multiple different AWS SDK clients. This config resolution process can be customized
by calling aws_config::from_env()
instead, which returns a ConfigLoader
that uses
the builder pattern to customize the default config.
In the simplest case, creating a client looks as follows:
let config = aws_config::load_from_env().await;
let client = aws_sdk_managedblockchain::Client::new(&config);
Occasionally, SDKs may have additional service-specific values that can be set on the Config
that
is absent from SdkConfig
, or slightly different settings for a specific client may be desired.
The Builder
struct implements From<&SdkConfig>
, so setting these specific settings can be
done as follows:
let sdk_config = ::aws_config::load_from_env().await;
let config = aws_sdk_managedblockchain::config::Builder::from(&sdk_config)
.some_service_specific_setting("value")
.build();
See the aws-config
docs and Config
for more information on customizing configuration.
Note: Client construction is expensive due to connection thread pool initialization, and should be done once at application start-up.
§Using the Client
A client has a function for every operation that can be performed by the service.
For example, the CreateAccessor
operation has
a Client::create_accessor
, function which returns a builder for that operation.
The fluent builder ultimately has a send()
function that returns an async future that
returns a result, as illustrated below:
let result = client.create_accessor()
.client_request_token("example")
.send()
.await;
The underlying HTTP requests that get made by this can be modified with the customize_operation
function on the fluent builder. See the customize
module for more
information.
Implementations§
Source§impl Client
impl Client
Sourcepub fn create_accessor(&self) -> CreateAccessorFluentBuilder
pub fn create_accessor(&self) -> CreateAccessorFluentBuilder
Constructs a fluent builder for the CreateAccessor
operation.
- The fluent builder is configurable:
client_request_token(impl Into<String>)
/set_client_request_token(Option<String>)
:
required: trueThis is a unique, case-sensitive identifier that you provide to ensure the idempotency of the operation. An idempotent operation completes no more than once. This identifier is required only if you make a service request directly using an HTTP client. It is generated automatically if you use an Amazon Web Services SDK or the Amazon Web Services CLI.
accessor_type(AccessorType)
/set_accessor_type(Option<AccessorType>)
:
required: trueThe type of accessor.
Currently, accessor type is restricted to
BILLING_TOKEN
.tags(impl Into<String>, impl Into<String>)
/set_tags(Option<HashMap::<String, String>>)
:
required: falseTags to assign to the Accessor.
Each tag consists of a key and an optional value. You can specify multiple key-value pairs in a single request with an overall maximum of 50 tags allowed per resource.
For more information about tags, see Tagging Resources in the Amazon Managed Blockchain Ethereum Developer Guide, or Tagging Resources in the Amazon Managed Blockchain Hyperledger Fabric Developer Guide.
network_type(AccessorNetworkType)
/set_network_type(Option<AccessorNetworkType>)
:
required: falseThe blockchain network that the
Accessor
token is created for.-
Use the actual
networkType
value for the blockchain network that you are creating theAccessor
token for. -
With the shut down of the Ethereum Goerli and Polygon Mumbai Testnet networks the following
networkType
values are no longer available for selection and use.-
ETHEREUM_MAINNET_AND_GOERLI
-
ETHEREUM_GOERLI
-
POLYGON_MUMBAI
However, your existing
Accessor
tokens with thesenetworkType
values will remain unchanged. -
-
- On success, responds with
CreateAccessorOutput
with field(s):accessor_id(Option<String>)
:The unique identifier of the accessor.
billing_token(Option<String>)
:The billing token is a property of the Accessor. Use this token to when making calls to the blockchain network. The billing token is used to track your accessor token for billing requests.
network_type(Option<AccessorNetworkType>)
:The blockchain network that the accessor token is created for.
- On failure, responds with
SdkError<CreateAccessorError>
Source§impl Client
impl Client
Sourcepub fn create_member(&self) -> CreateMemberFluentBuilder
pub fn create_member(&self) -> CreateMemberFluentBuilder
Constructs a fluent builder for the CreateMember
operation.
- The fluent builder is configurable:
client_request_token(impl Into<String>)
/set_client_request_token(Option<String>)
:
required: trueA unique, case-sensitive identifier that you provide to ensure the idempotency of the operation. An idempotent operation completes no more than one time. This identifier is required only if you make a service request directly using an HTTP client. It is generated automatically if you use an Amazon Web Services SDK or the CLI.
invitation_id(impl Into<String>)
/set_invitation_id(Option<String>)
:
required: trueThe unique identifier of the invitation that is sent to the member to join the network.
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network in which the member is created.
member_configuration(MemberConfiguration)
/set_member_configuration(Option<MemberConfiguration>)
:
required: trueMember configuration parameters.
- On success, responds with
CreateMemberOutput
with field(s):member_id(Option<String>)
:The unique identifier of the member.
- On failure, responds with
SdkError<CreateMemberError>
Source§impl Client
impl Client
Sourcepub fn create_network(&self) -> CreateNetworkFluentBuilder
pub fn create_network(&self) -> CreateNetworkFluentBuilder
Constructs a fluent builder for the CreateNetwork
operation.
- The fluent builder is configurable:
client_request_token(impl Into<String>)
/set_client_request_token(Option<String>)
:
required: trueThis is a unique, case-sensitive identifier that you provide to ensure the idempotency of the operation. An idempotent operation completes no more than once. This identifier is required only if you make a service request directly using an HTTP client. It is generated automatically if you use an Amazon Web Services SDK or the Amazon Web Services CLI.
name(impl Into<String>)
/set_name(Option<String>)
:
required: trueThe name of the network.
description(impl Into<String>)
/set_description(Option<String>)
:
required: falseAn optional description for the network.
framework(Framework)
/set_framework(Option<Framework>)
:
required: trueThe blockchain framework that the network uses.
framework_version(impl Into<String>)
/set_framework_version(Option<String>)
:
required: trueThe version of the blockchain framework that the network uses.
framework_configuration(NetworkFrameworkConfiguration)
/set_framework_configuration(Option<NetworkFrameworkConfiguration>)
:
required: falseConfiguration properties of the blockchain framework relevant to the network configuration.
voting_policy(VotingPolicy)
/set_voting_policy(Option<VotingPolicy>)
:
required: trueThe voting rules used by the network to determine if a proposal is approved.
member_configuration(MemberConfiguration)
/set_member_configuration(Option<MemberConfiguration>)
:
required: trueConfiguration properties for the first member within the network.
tags(impl Into<String>, impl Into<String>)
/set_tags(Option<HashMap::<String, String>>)
:
required: falseTags to assign to the network.
Each tag consists of a key and an optional value. You can specify multiple key-value pairs in a single request with an overall maximum of 50 tags allowed per resource.
For more information about tags, see Tagging Resources in the Amazon Managed Blockchain Ethereum Developer Guide, or Tagging Resources in the Amazon Managed Blockchain Hyperledger Fabric Developer Guide.
- On success, responds with
CreateNetworkOutput
with field(s):network_id(Option<String>)
:The unique identifier for the network.
member_id(Option<String>)
:The unique identifier for the first member within the network.
- On failure, responds with
SdkError<CreateNetworkError>
Source§impl Client
impl Client
Sourcepub fn create_node(&self) -> CreateNodeFluentBuilder
pub fn create_node(&self) -> CreateNodeFluentBuilder
Constructs a fluent builder for the CreateNode
operation.
- The fluent builder is configurable:
client_request_token(impl Into<String>)
/set_client_request_token(Option<String>)
:
required: trueA unique, case-sensitive identifier that you provide to ensure the idempotency of the operation. An idempotent operation completes no more than one time. This identifier is required only if you make a service request directly using an HTTP client. It is generated automatically if you use an Amazon Web Services SDK or the CLI.
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network for the node.
Ethereum public networks have the following
NetworkId
s:-
n-ethereum-mainnet
-
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: falseThe unique identifier of the member that owns this node.
Applies only to Hyperledger Fabric.
node_configuration(NodeConfiguration)
/set_node_configuration(Option<NodeConfiguration>)
:
required: trueThe properties of a node configuration.
tags(impl Into<String>, impl Into<String>)
/set_tags(Option<HashMap::<String, String>>)
:
required: falseTags to assign to the node.
Each tag consists of a key and an optional value. You can specify multiple key-value pairs in a single request with an overall maximum of 50 tags allowed per resource.
For more information about tags, see Tagging Resources in the Amazon Managed Blockchain Ethereum Developer Guide, or Tagging Resources in the Amazon Managed Blockchain Hyperledger Fabric Developer Guide.
- On success, responds with
CreateNodeOutput
with field(s):node_id(Option<String>)
:The unique identifier of the node.
- On failure, responds with
SdkError<CreateNodeError>
Source§impl Client
impl Client
Sourcepub fn create_proposal(&self) -> CreateProposalFluentBuilder
pub fn create_proposal(&self) -> CreateProposalFluentBuilder
Constructs a fluent builder for the CreateProposal
operation.
- The fluent builder is configurable:
client_request_token(impl Into<String>)
/set_client_request_token(Option<String>)
:
required: trueA unique, case-sensitive identifier that you provide to ensure the idempotency of the operation. An idempotent operation completes no more than one time. This identifier is required only if you make a service request directly using an HTTP client. It is generated automatically if you use an Amazon Web Services SDK or the CLI.
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network for which the proposal is made.
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: trueThe unique identifier of the member that is creating the proposal. This identifier is especially useful for identifying the member making the proposal when multiple members exist in a single Amazon Web Services account.
actions(ProposalActions)
/set_actions(Option<ProposalActions>)
:
required: trueThe type of actions proposed, such as inviting a member or removing a member. The types of
Actions
in a proposal are mutually exclusive. For example, a proposal withInvitations
actions cannot also containRemovals
actions.description(impl Into<String>)
/set_description(Option<String>)
:
required: falseA description for the proposal that is visible to voting members, for example, “Proposal to add Example Corp. as member.”
tags(impl Into<String>, impl Into<String>)
/set_tags(Option<HashMap::<String, String>>)
:
required: falseTags to assign to the proposal.
Each tag consists of a key and an optional value. You can specify multiple key-value pairs in a single request with an overall maximum of 50 tags allowed per resource.
For more information about tags, see Tagging Resources in the Amazon Managed Blockchain Ethereum Developer Guide, or Tagging Resources in the Amazon Managed Blockchain Hyperledger Fabric Developer Guide.
- On success, responds with
CreateProposalOutput
with field(s):proposal_id(Option<String>)
:The unique identifier of the proposal.
- On failure, responds with
SdkError<CreateProposalError>
Source§impl Client
impl Client
Sourcepub fn delete_accessor(&self) -> DeleteAccessorFluentBuilder
pub fn delete_accessor(&self) -> DeleteAccessorFluentBuilder
Constructs a fluent builder for the DeleteAccessor
operation.
- The fluent builder is configurable:
accessor_id(impl Into<String>)
/set_accessor_id(Option<String>)
:
required: trueThe unique identifier of the accessor.
- On success, responds with
DeleteAccessorOutput
- On failure, responds with
SdkError<DeleteAccessorError>
Source§impl Client
impl Client
Sourcepub fn delete_member(&self) -> DeleteMemberFluentBuilder
pub fn delete_member(&self) -> DeleteMemberFluentBuilder
Constructs a fluent builder for the DeleteMember
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network from which the member is removed.
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: trueThe unique identifier of the member to remove.
- On success, responds with
DeleteMemberOutput
- On failure, responds with
SdkError<DeleteMemberError>
Source§impl Client
impl Client
Sourcepub fn delete_node(&self) -> DeleteNodeFluentBuilder
pub fn delete_node(&self) -> DeleteNodeFluentBuilder
Constructs a fluent builder for the DeleteNode
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network that the node is on.
Ethereum public networks have the following
NetworkId
s:-
n-ethereum-mainnet
-
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: falseThe unique identifier of the member that owns this node.
Applies only to Hyperledger Fabric and is required for Hyperledger Fabric.
node_id(impl Into<String>)
/set_node_id(Option<String>)
:
required: trueThe unique identifier of the node.
- On success, responds with
DeleteNodeOutput
- On failure, responds with
SdkError<DeleteNodeError>
Source§impl Client
impl Client
Sourcepub fn get_accessor(&self) -> GetAccessorFluentBuilder
pub fn get_accessor(&self) -> GetAccessorFluentBuilder
Constructs a fluent builder for the GetAccessor
operation.
- The fluent builder is configurable:
accessor_id(impl Into<String>)
/set_accessor_id(Option<String>)
:
required: trueThe unique identifier of the accessor.
- On success, responds with
GetAccessorOutput
with field(s):accessor(Option<Accessor>)
:The properties of the accessor.
- On failure, responds with
SdkError<GetAccessorError>
Source§impl Client
impl Client
Sourcepub fn get_member(&self) -> GetMemberFluentBuilder
pub fn get_member(&self) -> GetMemberFluentBuilder
Constructs a fluent builder for the GetMember
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network to which the member belongs.
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: trueThe unique identifier of the member.
- On success, responds with
GetMemberOutput
with field(s):member(Option<Member>)
:The properties of a member.
- On failure, responds with
SdkError<GetMemberError>
Source§impl Client
impl Client
Sourcepub fn get_network(&self) -> GetNetworkFluentBuilder
pub fn get_network(&self) -> GetNetworkFluentBuilder
Constructs a fluent builder for the GetNetwork
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network to get information about.
- On success, responds with
GetNetworkOutput
with field(s):network(Option<Network>)
:An object containing network configuration parameters.
- On failure, responds with
SdkError<GetNetworkError>
Source§impl Client
impl Client
Sourcepub fn get_node(&self) -> GetNodeFluentBuilder
pub fn get_node(&self) -> GetNodeFluentBuilder
Constructs a fluent builder for the GetNode
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network that the node is on.
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: falseThe unique identifier of the member that owns the node.
Applies only to Hyperledger Fabric and is required for Hyperledger Fabric.
node_id(impl Into<String>)
/set_node_id(Option<String>)
:
required: trueThe unique identifier of the node.
- On success, responds with
GetNodeOutput
with field(s):node(Option<Node>)
:Properties of the node configuration.
- On failure, responds with
SdkError<GetNodeError>
Source§impl Client
impl Client
Sourcepub fn get_proposal(&self) -> GetProposalFluentBuilder
pub fn get_proposal(&self) -> GetProposalFluentBuilder
Constructs a fluent builder for the GetProposal
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network for which the proposal is made.
proposal_id(impl Into<String>)
/set_proposal_id(Option<String>)
:
required: trueThe unique identifier of the proposal.
- On success, responds with
GetProposalOutput
with field(s):proposal(Option<Proposal>)
:Information about a proposal.
- On failure, responds with
SdkError<GetProposalError>
Source§impl Client
impl Client
Sourcepub fn list_accessors(&self) -> ListAccessorsFluentBuilder
pub fn list_accessors(&self) -> ListAccessorsFluentBuilder
Constructs a fluent builder for the ListAccessors
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of accessors to list.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseThe pagination token that indicates the next set of results to retrieve.
network_type(AccessorNetworkType)
/set_network_type(Option<AccessorNetworkType>)
:
required: falseThe blockchain network that the
Accessor
token is created for.Use the value
ETHEREUM_MAINNET_AND_GOERLI
for all existingAccessors
tokens that were created before thenetworkType
property was introduced.
- On success, responds with
ListAccessorsOutput
with field(s):accessors(Option<Vec::<AccessorSummary>>)
:An array of AccessorSummary objects that contain configuration properties for each accessor.
next_token(Option<String>)
:The pagination token that indicates the next set of results to retrieve.
- On failure, responds with
SdkError<ListAccessorsError>
Source§impl Client
impl Client
Sourcepub fn list_invitations(&self) -> ListInvitationsFluentBuilder
pub fn list_invitations(&self) -> ListInvitationsFluentBuilder
Constructs a fluent builder for the ListInvitations
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of invitations to return.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseThe pagination token that indicates the next set of results to retrieve.
- On success, responds with
ListInvitationsOutput
with field(s):invitations(Option<Vec::<Invitation>>)
:The invitations for the network.
next_token(Option<String>)
:The pagination token that indicates the next set of results to retrieve.
- On failure, responds with
SdkError<ListInvitationsError>
Source§impl Client
impl Client
Sourcepub fn list_members(&self) -> ListMembersFluentBuilder
pub fn list_members(&self) -> ListMembersFluentBuilder
Constructs a fluent builder for the ListMembers
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network for which to list members.
name(impl Into<String>)
/set_name(Option<String>)
:
required: falseThe optional name of the member to list.
status(MemberStatus)
/set_status(Option<MemberStatus>)
:
required: falseAn optional status specifier. If provided, only members currently in this status are listed.
is_owned(bool)
/set_is_owned(Option<bool>)
:
required: falseAn optional Boolean value. If provided, the request is limited either to members that the current Amazon Web Services account owns (
true
) or that other Amazon Web Services accountsn own (false
). If omitted, all members are listed.max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of members to return in the request.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseThe pagination token that indicates the next set of results to retrieve.
- On success, responds with
ListMembersOutput
with field(s):members(Option<Vec::<MemberSummary>>)
:An array of
MemberSummary
objects. Each object contains details about a network member.next_token(Option<String>)
:The pagination token that indicates the next set of results to retrieve.
- On failure, responds with
SdkError<ListMembersError>
Source§impl Client
impl Client
Sourcepub fn list_networks(&self) -> ListNetworksFluentBuilder
pub fn list_networks(&self) -> ListNetworksFluentBuilder
Constructs a fluent builder for the ListNetworks
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:
required: falseThe name of the network.
framework(Framework)
/set_framework(Option<Framework>)
:
required: falseAn optional framework specifier. If provided, only networks of this framework type are listed.
status(NetworkStatus)
/set_status(Option<NetworkStatus>)
:
required: falseAn optional status specifier. If provided, only networks currently in this status are listed.
Applies only to Hyperledger Fabric.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of networks to list.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseThe pagination token that indicates the next set of results to retrieve.
- On success, responds with
ListNetworksOutput
with field(s):networks(Option<Vec::<NetworkSummary>>)
:An array of
NetworkSummary
objects that contain configuration properties for each network.next_token(Option<String>)
:The pagination token that indicates the next set of results to retrieve.
- On failure, responds with
SdkError<ListNetworksError>
Source§impl Client
impl Client
Sourcepub fn list_nodes(&self) -> ListNodesFluentBuilder
pub fn list_nodes(&self) -> ListNodesFluentBuilder
Constructs a fluent builder for the ListNodes
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network for which to list nodes.
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: falseThe unique identifier of the member who owns the nodes to list.
Applies only to Hyperledger Fabric and is required for Hyperledger Fabric.
status(NodeStatus)
/set_status(Option<NodeStatus>)
:
required: falseAn optional status specifier. If provided, only nodes currently in this status are listed.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of nodes to list.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseThe pagination token that indicates the next set of results to retrieve.
- On success, responds with
ListNodesOutput
with field(s):nodes(Option<Vec::<NodeSummary>>)
:An array of
NodeSummary
objects that contain configuration properties for each node.next_token(Option<String>)
:The pagination token that indicates the next set of results to retrieve.
- On failure, responds with
SdkError<ListNodesError>
Source§impl Client
impl Client
Sourcepub fn list_proposal_votes(&self) -> ListProposalVotesFluentBuilder
pub fn list_proposal_votes(&self) -> ListProposalVotesFluentBuilder
Constructs a fluent builder for the ListProposalVotes
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network.
proposal_id(impl Into<String>)
/set_proposal_id(Option<String>)
:
required: trueThe unique identifier of the proposal.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of votes to return.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseThe pagination token that indicates the next set of results to retrieve.
- On success, responds with
ListProposalVotesOutput
with field(s):proposal_votes(Option<Vec::<VoteSummary>>)
:The list of votes.
next_token(Option<String>)
:The pagination token that indicates the next set of results to retrieve.
- On failure, responds with
SdkError<ListProposalVotesError>
Source§impl Client
impl Client
Sourcepub fn list_proposals(&self) -> ListProposalsFluentBuilder
pub fn list_proposals(&self) -> ListProposalsFluentBuilder
Constructs a fluent builder for the ListProposals
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network.
max_results(i32)
/set_max_results(Option<i32>)
:
required: falseThe maximum number of proposals to return.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:
required: falseThe pagination token that indicates the next set of results to retrieve.
- On success, responds with
ListProposalsOutput
with field(s):proposals(Option<Vec::<ProposalSummary>>)
:The summary of each proposal made on the network.
next_token(Option<String>)
:The pagination token that indicates the next set of results to retrieve.
- On failure, responds with
SdkError<ListProposalsError>
Source§impl Client
impl Client
Constructs a fluent builder for the ListTagsForResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:
required: trueThe Amazon Resource Name (ARN) of the resource. For more information about ARNs and their format, see Amazon Resource Names (ARNs) in the Amazon Web Services General Reference.
- On success, responds with
ListTagsForResourceOutput
with field(s):tags(Option<HashMap::<String, String>>)
:The tags assigned to the resource.
- On failure, responds with
SdkError<ListTagsForResourceError>
Source§impl Client
impl Client
Sourcepub fn reject_invitation(&self) -> RejectInvitationFluentBuilder
pub fn reject_invitation(&self) -> RejectInvitationFluentBuilder
Constructs a fluent builder for the RejectInvitation
operation.
- The fluent builder is configurable:
invitation_id(impl Into<String>)
/set_invitation_id(Option<String>)
:
required: trueThe unique identifier of the invitation to reject.
- On success, responds with
RejectInvitationOutput
- On failure, responds with
SdkError<RejectInvitationError>
Source§impl Client
impl Client
Sourcepub fn tag_resource(&self) -> TagResourceFluentBuilder
pub fn tag_resource(&self) -> TagResourceFluentBuilder
Constructs a fluent builder for the TagResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:
required: trueThe Amazon Resource Name (ARN) of the resource. For more information about ARNs and their format, see Amazon Resource Names (ARNs) in the Amazon Web Services General Reference.
tags(impl Into<String>, impl Into<String>)
/set_tags(Option<HashMap::<String, String>>)
:
required: trueThe tags to assign to the specified resource. Tag values can be empty, for example,
“MyTagKey” : “”
. You can specify multiple key-value pairs in a single request, with an overall maximum of 50 tags added to each resource.
- On success, responds with
TagResourceOutput
- On failure, responds with
SdkError<TagResourceError>
Source§impl Client
impl Client
Sourcepub fn untag_resource(&self) -> UntagResourceFluentBuilder
pub fn untag_resource(&self) -> UntagResourceFluentBuilder
Constructs a fluent builder for the UntagResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:
required: trueThe Amazon Resource Name (ARN) of the resource. For more information about ARNs and their format, see Amazon Resource Names (ARNs) in the Amazon Web Services General Reference.
tag_keys(impl Into<String>)
/set_tag_keys(Option<Vec::<String>>)
:
required: trueThe tag keys.
- On success, responds with
UntagResourceOutput
- On failure, responds with
SdkError<UntagResourceError>
Source§impl Client
impl Client
Sourcepub fn update_member(&self) -> UpdateMemberFluentBuilder
pub fn update_member(&self) -> UpdateMemberFluentBuilder
Constructs a fluent builder for the UpdateMember
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the Managed Blockchain network to which the member belongs.
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: trueThe unique identifier of the member.
log_publishing_configuration(MemberLogPublishingConfiguration)
/set_log_publishing_configuration(Option<MemberLogPublishingConfiguration>)
:
required: falseConfiguration properties for publishing to Amazon CloudWatch Logs.
- On success, responds with
UpdateMemberOutput
- On failure, responds with
SdkError<UpdateMemberError>
Source§impl Client
impl Client
Sourcepub fn update_node(&self) -> UpdateNodeFluentBuilder
pub fn update_node(&self) -> UpdateNodeFluentBuilder
Constructs a fluent builder for the UpdateNode
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network that the node is on.
member_id(impl Into<String>)
/set_member_id(Option<String>)
:
required: falseThe unique identifier of the member that owns the node.
Applies only to Hyperledger Fabric.
node_id(impl Into<String>)
/set_node_id(Option<String>)
:
required: trueThe unique identifier of the node.
log_publishing_configuration(NodeLogPublishingConfiguration)
/set_log_publishing_configuration(Option<NodeLogPublishingConfiguration>)
:
required: falseConfiguration properties for publishing to Amazon CloudWatch Logs.
- On success, responds with
UpdateNodeOutput
- On failure, responds with
SdkError<UpdateNodeError>
Source§impl Client
impl Client
Sourcepub fn vote_on_proposal(&self) -> VoteOnProposalFluentBuilder
pub fn vote_on_proposal(&self) -> VoteOnProposalFluentBuilder
Constructs a fluent builder for the VoteOnProposal
operation.
- The fluent builder is configurable:
network_id(impl Into<String>)
/set_network_id(Option<String>)
:
required: trueThe unique identifier of the network.
proposal_id(impl Into<String>)
/set_proposal_id(Option<String>)
:
required: trueThe unique identifier of the proposal.
voter_member_id(impl Into<String>)
/set_voter_member_id(Option<String>)
:
required: trueThe unique identifier of the member casting the vote.
vote(VoteValue)
/set_vote(Option<VoteValue>)
:
required: trueThe value of the vote.
- On success, responds with
VoteOnProposalOutput
- On failure, responds with
SdkError<VoteOnProposalError>
Source§impl Client
impl Client
Sourcepub fn from_conf(conf: Config) -> Self
pub fn from_conf(conf: Config) -> Self
Creates a new client from the service Config
.
§Panics
This method will panic in the following cases:
- Retries or timeouts are enabled without a
sleep_impl
configured. - Identity caching is enabled without a
sleep_impl
andtime_source
configured. - No
behavior_version
is provided.
The panic message for each of these will have instructions on how to resolve them.
Source§impl Client
impl Client
Sourcepub fn new(sdk_config: &SdkConfig) -> Self
pub fn new(sdk_config: &SdkConfig) -> Self
Creates a new client from an SDK Config.
§Panics
- This method will panic if the
sdk_config
is missing an async sleep implementation. If you experience this panic, set thesleep_impl
on the Config passed into this function to fix it. - This method will panic if the
sdk_config
is missing an HTTP connector. If you experience this panic, set thehttp_connector
on the Config passed into this function to fix it. - This method will panic if no
BehaviorVersion
is provided. If you experience this panic, setbehavior_version
on the Config or enable thebehavior-version-latest
Cargo feature.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Client
impl !RefUnwindSafe for Client
impl Send for Client
impl Sync for Client
impl Unpin for Client
impl !UnwindSafe for Client
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
Source§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the foreground set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red()
and
green()
, which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg()
:
use yansi::{Paint, Color};
painted.fg(Color::White);
Set foreground color to white using white()
.
use yansi::Paint;
painted.white();
Source§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
Source§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
Source§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
Source§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
Source§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
Source§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
Source§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
Source§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the background set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red()
and
on_green()
, which have the same functionality but
are pithier.
§Example
Set background color to red using fg()
:
use yansi::{Paint, Color};
painted.bg(Color::Red);
Set background color to red using on_red()
.
use yansi::Paint;
painted.on_red();
Source§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
Source§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
Source§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
Source§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
Source§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
Source§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling Attribute
value
.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold()
and
underline()
, which have the same functionality
but are pithier.
§Example
Make text bold using attr()
:
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);
Make text bold using using bold()
.
use yansi::Paint;
painted.bold();
Source§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
Source§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi
Quirk
value
.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask()
and
wrap()
, which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk()
:
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);
Enable wrapping using wrap()
.
use yansi::Paint;
painted.wrap();
Source§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.
fn clear(&self) -> Painted<&T>
resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.Source§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the Condition
value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted
only when both stdout
and stderr
are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);