Documentation ¶
Index ¶
- type APIKey
- type APIKeyCollection
- type BlockchainMember
- type BlockchainMemberCollection
- type BlockchainMemberNodesSKU
- type BlockchainMemberOperationResultsClient
- type BlockchainMemberOperationResultsGetOptions
- type BlockchainMemberOperationResultsGetResponse
- type BlockchainMemberOperationResultsGetResult
- type BlockchainMemberProperties
- type BlockchainMemberPropertiesUpdate
- type BlockchainMemberProvisioningState
- type BlockchainMemberUpdate
- type BlockchainMembersBeginCreateOptions
- type BlockchainMembersBeginDeleteOptions
- type BlockchainMembersClient
- func (client *BlockchainMembersClient) BeginCreate(ctx context.Context, blockchainMemberName string, resourceGroupName string, ...) (BlockchainMembersCreatePollerResponse, error)
- func (client *BlockchainMembersClient) BeginDelete(ctx context.Context, blockchainMemberName string, resourceGroupName string, ...) (BlockchainMembersDeletePollerResponse, error)
- func (client *BlockchainMembersClient) Get(ctx context.Context, blockchainMemberName string, resourceGroupName string, ...) (BlockchainMembersGetResponse, error)
- func (client *BlockchainMembersClient) List(resourceGroupName string, options *BlockchainMembersListOptions) *BlockchainMembersListPager
- func (client *BlockchainMembersClient) ListAPIKeys(ctx context.Context, blockchainMemberName string, resourceGroupName string, ...) (BlockchainMembersListAPIKeysResponse, error)
- func (client *BlockchainMembersClient) ListAll(options *BlockchainMembersListAllOptions) *BlockchainMembersListAllPager
- func (client *BlockchainMembersClient) ListConsortiumMembers(blockchainMemberName string, resourceGroupName string, ...) *BlockchainMembersListConsortiumMembersPager
- func (client *BlockchainMembersClient) ListRegenerateAPIKeys(ctx context.Context, blockchainMemberName string, resourceGroupName string, ...) (BlockchainMembersListRegenerateAPIKeysResponse, error)
- func (client *BlockchainMembersClient) Update(ctx context.Context, blockchainMemberName string, resourceGroupName string, ...) (BlockchainMembersUpdateResponse, error)
- type BlockchainMembersCreatePoller
- func (p *BlockchainMembersCreatePoller) Done() bool
- func (p *BlockchainMembersCreatePoller) FinalResponse(ctx context.Context) (BlockchainMembersCreateResponse, error)
- func (p *BlockchainMembersCreatePoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *BlockchainMembersCreatePoller) ResumeToken() (string, error)
- type BlockchainMembersCreatePollerResponse
- type BlockchainMembersCreateResponse
- type BlockchainMembersCreateResult
- type BlockchainMembersDeletePoller
- func (p *BlockchainMembersDeletePoller) Done() bool
- func (p *BlockchainMembersDeletePoller) FinalResponse(ctx context.Context) (BlockchainMembersDeleteResponse, error)
- func (p *BlockchainMembersDeletePoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *BlockchainMembersDeletePoller) ResumeToken() (string, error)
- type BlockchainMembersDeletePollerResponse
- type BlockchainMembersDeleteResponse
- type BlockchainMembersGetOptions
- type BlockchainMembersGetResponse
- type BlockchainMembersGetResult
- type BlockchainMembersListAPIKeysOptions
- type BlockchainMembersListAPIKeysResponse
- type BlockchainMembersListAPIKeysResult
- type BlockchainMembersListAllOptions
- type BlockchainMembersListAllPager
- type BlockchainMembersListAllResponse
- type BlockchainMembersListAllResult
- type BlockchainMembersListConsortiumMembersOptions
- type BlockchainMembersListConsortiumMembersPager
- type BlockchainMembersListConsortiumMembersResponse
- type BlockchainMembersListConsortiumMembersResult
- type BlockchainMembersListOptions
- type BlockchainMembersListPager
- type BlockchainMembersListRegenerateAPIKeysOptions
- type BlockchainMembersListRegenerateAPIKeysResponse
- type BlockchainMembersListRegenerateAPIKeysResult
- type BlockchainMembersListResponse
- type BlockchainMembersListResult
- type BlockchainMembersUpdateOptions
- type BlockchainMembersUpdateResponse
- type BlockchainMembersUpdateResult
- type BlockchainProtocol
- type Consortium
- type ConsortiumCollection
- type ConsortiumMember
- type ConsortiumMemberCollection
- type FirewallRule
- type LocationsCheckNameAvailabilityOptions
- type LocationsCheckNameAvailabilityResponse
- type LocationsCheckNameAvailabilityResult
- type LocationsClient
- type LocationsListConsortiumsOptions
- type LocationsListConsortiumsResponse
- type LocationsListConsortiumsResult
- type NameAvailability
- type NameAvailabilityReason
- type NameAvailabilityRequest
- type NodeProvisioningState
- type OperationResult
- type OperationsClient
- type OperationsListOptions
- type OperationsListPager
- type OperationsListResponse
- type OperationsListResult
- type Resource
- type ResourceProviderOperation
- type ResourceProviderOperationCollection
- type ResourceProviderOperationDisplay
- type ResourceTypeSKU
- type ResourceTypeSKUCollection
- type SKU
- type SKUSetting
- type SKUsClient
- type SKUsListOptions
- type SKUsListResponse
- type SKUsListResult
- type TrackedResource
- type TransactionNode
- type TransactionNodeCollection
- type TransactionNodeProperties
- type TransactionNodePropertiesUpdate
- type TransactionNodeUpdate
- type TransactionNodesBeginCreateOptions
- type TransactionNodesBeginDeleteOptions
- type TransactionNodesClient
- func (client *TransactionNodesClient) BeginCreate(ctx context.Context, blockchainMemberName string, transactionNodeName string, ...) (TransactionNodesCreatePollerResponse, error)
- func (client *TransactionNodesClient) BeginDelete(ctx context.Context, blockchainMemberName string, transactionNodeName string, ...) (TransactionNodesDeletePollerResponse, error)
- func (client *TransactionNodesClient) Get(ctx context.Context, blockchainMemberName string, transactionNodeName string, ...) (TransactionNodesGetResponse, error)
- func (client *TransactionNodesClient) List(blockchainMemberName string, resourceGroupName string, ...) *TransactionNodesListPager
- func (client *TransactionNodesClient) ListAPIKeys(ctx context.Context, blockchainMemberName string, transactionNodeName string, ...) (TransactionNodesListAPIKeysResponse, error)
- func (client *TransactionNodesClient) ListRegenerateAPIKeys(ctx context.Context, blockchainMemberName string, transactionNodeName string, ...) (TransactionNodesListRegenerateAPIKeysResponse, error)
- func (client *TransactionNodesClient) Update(ctx context.Context, blockchainMemberName string, transactionNodeName string, ...) (TransactionNodesUpdateResponse, error)
- type TransactionNodesCreatePoller
- func (p *TransactionNodesCreatePoller) Done() bool
- func (p *TransactionNodesCreatePoller) FinalResponse(ctx context.Context) (TransactionNodesCreateResponse, error)
- func (p *TransactionNodesCreatePoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *TransactionNodesCreatePoller) ResumeToken() (string, error)
- type TransactionNodesCreatePollerResponse
- type TransactionNodesCreateResponse
- type TransactionNodesCreateResult
- type TransactionNodesDeletePoller
- func (p *TransactionNodesDeletePoller) Done() bool
- func (p *TransactionNodesDeletePoller) FinalResponse(ctx context.Context) (TransactionNodesDeleteResponse, error)
- func (p *TransactionNodesDeletePoller) Poll(ctx context.Context) (*http.Response, error)
- func (p *TransactionNodesDeletePoller) ResumeToken() (string, error)
- type TransactionNodesDeletePollerResponse
- type TransactionNodesDeleteResponse
- type TransactionNodesGetOptions
- type TransactionNodesGetResponse
- type TransactionNodesGetResult
- type TransactionNodesListAPIKeysOptions
- type TransactionNodesListAPIKeysResponse
- type TransactionNodesListAPIKeysResult
- type TransactionNodesListOptions
- type TransactionNodesListPager
- type TransactionNodesListRegenerateAPIKeysOptions
- type TransactionNodesListRegenerateAPIKeysResponse
- type TransactionNodesListRegenerateAPIKeysResult
- type TransactionNodesListResponse
- type TransactionNodesListResult
- type TransactionNodesUpdateOptions
- type TransactionNodesUpdateResponse
- type TransactionNodesUpdateResult
Examples ¶
- BlockchainMemberOperationResultsClient.Get
- BlockchainMembersClient.BeginCreate
- BlockchainMembersClient.BeginDelete
- BlockchainMembersClient.Get
- BlockchainMembersClient.List
- BlockchainMembersClient.ListAPIKeys
- BlockchainMembersClient.ListAll
- BlockchainMembersClient.ListConsortiumMembers
- BlockchainMembersClient.ListRegenerateAPIKeys
- BlockchainMembersClient.Update
- LocationsClient.CheckNameAvailability
- LocationsClient.ListConsortiums
- OperationsClient.List
- SKUsClient.List
- TransactionNodesClient.BeginCreate
- TransactionNodesClient.BeginDelete
- TransactionNodesClient.Get
- TransactionNodesClient.List
- TransactionNodesClient.ListAPIKeys
- TransactionNodesClient.ListRegenerateAPIKeys
- TransactionNodesClient.Update
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIKey ¶
type APIKey struct { // Gets or sets the API key name. KeyName *string `json:"keyName,omitempty"` // Gets or sets the API key value. Value *string `json:"value,omitempty"` }
APIKey - API key payload which is exposed in the request/response of the resource provider.
type APIKeyCollection ¶
type APIKeyCollection struct { // Gets or sets the collection of API key. Keys []*APIKey `json:"keys,omitempty"` }
APIKeyCollection - Collection of the API key payload which is exposed in the response of the resource provider.
func (APIKeyCollection) MarshalJSON ¶
func (a APIKeyCollection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type APIKeyCollection.
type BlockchainMember ¶
type BlockchainMember struct { TrackedResource // Gets or sets the blockchain member properties. Properties *BlockchainMemberProperties `json:"properties,omitempty"` // Gets or sets the blockchain member Sku. SKU *SKU `json:"sku,omitempty"` }
BlockchainMember - Payload of the blockchain member which is exposed in the request/response of the resource provider.
func (BlockchainMember) MarshalJSON ¶
func (b BlockchainMember) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlockchainMember.
type BlockchainMemberCollection ¶
type BlockchainMemberCollection struct { // Gets or sets the URL, that the client should use to fetch the next page (per server side paging). It's null for now, added for future use. NextLink *string `json:"nextLink,omitempty"` // Gets or sets the collection of blockchain members. Value []*BlockchainMember `json:"value,omitempty"` }
BlockchainMemberCollection - Collection of the blockchain member payload which is exposed in the request/response of the resource provider.
func (BlockchainMemberCollection) MarshalJSON ¶
func (b BlockchainMemberCollection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlockchainMemberCollection.
type BlockchainMemberNodesSKU ¶
type BlockchainMemberNodesSKU struct { // Gets or sets the nodes capacity. Capacity *int32 `json:"capacity,omitempty"` }
BlockchainMemberNodesSKU - Payload of the blockchain member nodes Sku for a blockchain member.
type BlockchainMemberOperationResultsClient ¶
type BlockchainMemberOperationResultsClient struct {
// contains filtered or unexported fields
}
BlockchainMemberOperationResultsClient contains the methods for the BlockchainMemberOperationResults group. Don't use this type directly, use NewBlockchainMemberOperationResultsClient() instead.
func NewBlockchainMemberOperationResultsClient ¶
func NewBlockchainMemberOperationResultsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *BlockchainMemberOperationResultsClient
NewBlockchainMemberOperationResultsClient creates a new instance of BlockchainMemberOperationResultsClient with the specified values.
func (*BlockchainMemberOperationResultsClient) Get ¶
func (client *BlockchainMemberOperationResultsClient) Get(ctx context.Context, locationName string, operationID string, options *BlockchainMemberOperationResultsGetOptions) (BlockchainMemberOperationResultsGetResponse, error)
Get - Get Async operation result. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMemberOperationResults_Get.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMemberOperationResultsClient("<subscription-id>", cred, nil) _, err = client.Get(ctx, "<location-name>", "<operation-id>", nil) if err != nil { log.Fatal(err) } }
Output:
type BlockchainMemberOperationResultsGetOptions ¶
type BlockchainMemberOperationResultsGetOptions struct { }
BlockchainMemberOperationResultsGetOptions contains the optional parameters for the BlockchainMemberOperationResults.Get method.
type BlockchainMemberOperationResultsGetResponse ¶
type BlockchainMemberOperationResultsGetResponse struct { BlockchainMemberOperationResultsGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMemberOperationResultsGetResponse contains the response from method BlockchainMemberOperationResults.Get.
type BlockchainMemberOperationResultsGetResult ¶
type BlockchainMemberOperationResultsGetResult struct {
OperationResult
}
BlockchainMemberOperationResultsGetResult contains the result from method BlockchainMemberOperationResults.Get.
type BlockchainMemberProperties ¶
type BlockchainMemberProperties struct { // Gets or sets the consortium for the blockchain member. Consortium *string `json:"consortium,omitempty"` // Sets the managed consortium management account password. ConsortiumManagementAccountPassword *string `json:"consortiumManagementAccountPassword,omitempty"` // Gets the display name of the member in the consortium. ConsortiumMemberDisplayName *string `json:"consortiumMemberDisplayName,omitempty"` // Gets the role of the member in the consortium. ConsortiumRole *string `json:"consortiumRole,omitempty"` // Gets or sets firewall rules FirewallRules []*FirewallRule `json:"firewallRules,omitempty"` // Sets the basic auth password of the blockchain member. Password *string `json:"password,omitempty"` // Gets or sets the blockchain protocol. Protocol *BlockchainProtocol `json:"protocol,omitempty"` // Gets or sets the blockchain validator nodes Sku. ValidatorNodesSKU *BlockchainMemberNodesSKU `json:"validatorNodesSku,omitempty"` // READ-ONLY; Gets the managed consortium management account address. ConsortiumManagementAccountAddress *string `json:"consortiumManagementAccountAddress,omitempty" azure:"ro"` // READ-ONLY; Gets the dns endpoint of the blockchain member. DNS *string `json:"dns,omitempty" azure:"ro"` // READ-ONLY; Gets or sets the blockchain member provision state. ProvisioningState *BlockchainMemberProvisioningState `json:"provisioningState,omitempty" azure:"ro"` // READ-ONLY; Gets the public key of the blockchain member (default transaction node). PublicKey *string `json:"publicKey,omitempty" azure:"ro"` // READ-ONLY; Gets the Ethereum root contract address of the blockchain. RootContractAddress *string `json:"rootContractAddress,omitempty" azure:"ro"` // READ-ONLY; Gets the auth user name of the blockchain member. UserName *string `json:"userName,omitempty" azure:"ro"` }
BlockchainMemberProperties - Payload of the blockchain member properties for a blockchain member.
func (BlockchainMemberProperties) MarshalJSON ¶
func (b BlockchainMemberProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlockchainMemberProperties.
type BlockchainMemberPropertiesUpdate ¶
type BlockchainMemberPropertiesUpdate struct { TransactionNodePropertiesUpdate // Sets the managed consortium management account password. ConsortiumManagementAccountPassword *string `json:"consortiumManagementAccountPassword,omitempty"` }
BlockchainMemberPropertiesUpdate - Update the payload of the blockchain member properties for a blockchain member.
func (BlockchainMemberPropertiesUpdate) MarshalJSON ¶
func (b BlockchainMemberPropertiesUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlockchainMemberPropertiesUpdate.
type BlockchainMemberProvisioningState ¶
type BlockchainMemberProvisioningState string
BlockchainMemberProvisioningState - Gets or sets the blockchain member provision state.
const ( BlockchainMemberProvisioningStateDeleting BlockchainMemberProvisioningState = "Deleting" BlockchainMemberProvisioningStateFailed BlockchainMemberProvisioningState = "Failed" BlockchainMemberProvisioningStateNotSpecified BlockchainMemberProvisioningState = "NotSpecified" BlockchainMemberProvisioningStateStale BlockchainMemberProvisioningState = "Stale" BlockchainMemberProvisioningStateSucceeded BlockchainMemberProvisioningState = "Succeeded" BlockchainMemberProvisioningStateUpdating BlockchainMemberProvisioningState = "Updating" )
func PossibleBlockchainMemberProvisioningStateValues ¶
func PossibleBlockchainMemberProvisioningStateValues() []BlockchainMemberProvisioningState
PossibleBlockchainMemberProvisioningStateValues returns the possible values for the BlockchainMemberProvisioningState const type.
func (BlockchainMemberProvisioningState) ToPtr ¶
func (c BlockchainMemberProvisioningState) ToPtr() *BlockchainMemberProvisioningState
ToPtr returns a *BlockchainMemberProvisioningState pointing to the current value.
type BlockchainMemberUpdate ¶
type BlockchainMemberUpdate struct { // Gets or sets the blockchain member update properties. Properties *BlockchainMemberPropertiesUpdate `json:"properties,omitempty"` // Tags of the service which is a list of key value pairs that describes the resource. Tags map[string]*string `json:"tags,omitempty"` }
BlockchainMemberUpdate - Update the payload of the blockchain member which is exposed in the request/response of the resource provider.
func (BlockchainMemberUpdate) MarshalJSON ¶
func (b BlockchainMemberUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type BlockchainMemberUpdate.
type BlockchainMembersBeginCreateOptions ¶
type BlockchainMembersBeginCreateOptions struct { // Payload to create a blockchain member. BlockchainMember *BlockchainMember }
BlockchainMembersBeginCreateOptions contains the optional parameters for the BlockchainMembers.BeginCreate method.
type BlockchainMembersBeginDeleteOptions ¶
type BlockchainMembersBeginDeleteOptions struct { }
BlockchainMembersBeginDeleteOptions contains the optional parameters for the BlockchainMembers.BeginDelete method.
type BlockchainMembersClient ¶
type BlockchainMembersClient struct {
// contains filtered or unexported fields
}
BlockchainMembersClient contains the methods for the BlockchainMembers group. Don't use this type directly, use NewBlockchainMembersClient() instead.
func NewBlockchainMembersClient ¶
func NewBlockchainMembersClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *BlockchainMembersClient
NewBlockchainMembersClient creates a new instance of BlockchainMembersClient with the specified values.
func (*BlockchainMembersClient) BeginCreate ¶
func (client *BlockchainMembersClient) BeginCreate(ctx context.Context, blockchainMemberName string, resourceGroupName string, options *BlockchainMembersBeginCreateOptions) (BlockchainMembersCreatePollerResponse, error)
BeginCreate - Create a blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_Create.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) poller, err := client.BeginCreate(ctx, "<blockchain-member-name>", "<resource-group-name>", &armblockchain.BlockchainMembersBeginCreateOptions{BlockchainMember: &armblockchain.BlockchainMember{ TrackedResource: armblockchain.TrackedResource{ Location: to.StringPtr("<location>"), }, Properties: &armblockchain.BlockchainMemberProperties{ Consortium: to.StringPtr("<consortium>"), ConsortiumManagementAccountPassword: to.StringPtr("<consortium-management-account-password>"), Password: to.StringPtr("<password>"), ValidatorNodesSKU: &armblockchain.BlockchainMemberNodesSKU{ Capacity: to.Int32Ptr(2), }, Protocol: armblockchain.BlockchainProtocolQuorum.ToPtr(), }, }, }) if err != nil { log.Fatal(err) } res, err := poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } log.Printf("BlockchainMember.ID: %s\n", *res.ID) }
Output:
func (*BlockchainMembersClient) BeginDelete ¶
func (client *BlockchainMembersClient) BeginDelete(ctx context.Context, blockchainMemberName string, resourceGroupName string, options *BlockchainMembersBeginDeleteOptions) (BlockchainMembersDeletePollerResponse, error)
BeginDelete - Delete a blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_Delete.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) poller, err := client.BeginDelete(ctx, "<blockchain-member-name>", "<resource-group-name>", nil) if err != nil { log.Fatal(err) } _, err = poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } }
Output:
func (*BlockchainMembersClient) Get ¶
func (client *BlockchainMembersClient) Get(ctx context.Context, blockchainMemberName string, resourceGroupName string, options *BlockchainMembersGetOptions) (BlockchainMembersGetResponse, error)
Get - Get details about a blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_Get.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<blockchain-member-name>", "<resource-group-name>", nil) if err != nil { log.Fatal(err) } log.Printf("BlockchainMember.ID: %s\n", *res.ID) }
Output:
func (*BlockchainMembersClient) List ¶
func (client *BlockchainMembersClient) List(resourceGroupName string, options *BlockchainMembersListOptions) *BlockchainMembersListPager
List - Lists the blockchain members for a resource group. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_List.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) pager := client.List("<resource-group-name>", nil) for pager.NextPage(ctx) { if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range pager.PageResponse().Value { log.Printf("BlockchainMember.ID: %s\n", *v.ID) } } }
Output:
func (*BlockchainMembersClient) ListAPIKeys ¶
func (client *BlockchainMembersClient) ListAPIKeys(ctx context.Context, blockchainMemberName string, resourceGroupName string, options *BlockchainMembersListAPIKeysOptions) (BlockchainMembersListAPIKeysResponse, error)
ListAPIKeys - Lists the API keys for a blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_ListApiKeys.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) _, err = client.ListAPIKeys(ctx, "<blockchain-member-name>", "<resource-group-name>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*BlockchainMembersClient) ListAll ¶
func (client *BlockchainMembersClient) ListAll(options *BlockchainMembersListAllOptions) *BlockchainMembersListAllPager
ListAll - Lists the blockchain members for a subscription. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_ListAll.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) pager := client.ListAll(nil) for pager.NextPage(ctx) { if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range pager.PageResponse().Value { log.Printf("BlockchainMember.ID: %s\n", *v.ID) } } }
Output:
func (*BlockchainMembersClient) ListConsortiumMembers ¶
func (client *BlockchainMembersClient) ListConsortiumMembers(blockchainMemberName string, resourceGroupName string, options *BlockchainMembersListConsortiumMembersOptions) *BlockchainMembersListConsortiumMembersPager
ListConsortiumMembers - Lists the consortium members for a blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_ListConsortiumMembers.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) pager := client.ListConsortiumMembers("<blockchain-member-name>", "<resource-group-name>", nil) for pager.NextPage(ctx) { if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } } }
Output:
func (*BlockchainMembersClient) ListRegenerateAPIKeys ¶
func (client *BlockchainMembersClient) ListRegenerateAPIKeys(ctx context.Context, blockchainMemberName string, resourceGroupName string, options *BlockchainMembersListRegenerateAPIKeysOptions) (BlockchainMembersListRegenerateAPIKeysResponse, error)
ListRegenerateAPIKeys - Regenerate the API keys for a blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_ListRegenerateApiKeys.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) _, err = client.ListRegenerateAPIKeys(ctx, "<blockchain-member-name>", "<resource-group-name>", &armblockchain.BlockchainMembersListRegenerateAPIKeysOptions{APIKey: &armblockchain.APIKey{ KeyName: to.StringPtr("<key-name>"), }, }) if err != nil { log.Fatal(err) } }
Output:
func (*BlockchainMembersClient) Update ¶
func (client *BlockchainMembersClient) Update(ctx context.Context, blockchainMemberName string, resourceGroupName string, options *BlockchainMembersUpdateOptions) (BlockchainMembersUpdateResponse, error)
Update - Update a blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/BlockchainMembers_Update.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewBlockchainMembersClient("<subscription-id>", cred, nil) res, err := client.Update(ctx, "<blockchain-member-name>", "<resource-group-name>", &armblockchain.BlockchainMembersUpdateOptions{BlockchainMember: &armblockchain.BlockchainMemberUpdate{ Properties: &armblockchain.BlockchainMemberPropertiesUpdate{ TransactionNodePropertiesUpdate: armblockchain.TransactionNodePropertiesUpdate{ FirewallRules: []*armblockchain.FirewallRule{}, Password: to.StringPtr("<password>"), }, ConsortiumManagementAccountPassword: to.StringPtr("<consortium-management-account-password>"), }, Tags: map[string]*string{}, }, }) if err != nil { log.Fatal(err) } log.Printf("BlockchainMember.ID: %s\n", *res.ID) }
Output:
type BlockchainMembersCreatePoller ¶
type BlockchainMembersCreatePoller struct {
// contains filtered or unexported fields
}
BlockchainMembersCreatePoller provides polling facilities until the operation reaches a terminal state.
func (*BlockchainMembersCreatePoller) Done ¶
func (p *BlockchainMembersCreatePoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*BlockchainMembersCreatePoller) FinalResponse ¶
func (p *BlockchainMembersCreatePoller) FinalResponse(ctx context.Context) (BlockchainMembersCreateResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final BlockchainMembersCreateResponse will be returned.
func (*BlockchainMembersCreatePoller) Poll ¶
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*BlockchainMembersCreatePoller) ResumeToken ¶
func (p *BlockchainMembersCreatePoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type BlockchainMembersCreatePollerResponse ¶
type BlockchainMembersCreatePollerResponse struct { // Poller contains an initialized poller. Poller *BlockchainMembersCreatePoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersCreatePollerResponse contains the response from method BlockchainMembers.Create.
func (BlockchainMembersCreatePollerResponse) PollUntilDone ¶
func (l BlockchainMembersCreatePollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (BlockchainMembersCreateResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*BlockchainMembersCreatePollerResponse) Resume ¶
func (l *BlockchainMembersCreatePollerResponse) Resume(ctx context.Context, client *BlockchainMembersClient, token string) error
Resume rehydrates a BlockchainMembersCreatePollerResponse from the provided client and resume token.
type BlockchainMembersCreateResponse ¶
type BlockchainMembersCreateResponse struct { BlockchainMembersCreateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersCreateResponse contains the response from method BlockchainMembers.Create.
type BlockchainMembersCreateResult ¶
type BlockchainMembersCreateResult struct {
BlockchainMember
}
BlockchainMembersCreateResult contains the result from method BlockchainMembers.Create.
type BlockchainMembersDeletePoller ¶
type BlockchainMembersDeletePoller struct {
// contains filtered or unexported fields
}
BlockchainMembersDeletePoller provides polling facilities until the operation reaches a terminal state.
func (*BlockchainMembersDeletePoller) Done ¶
func (p *BlockchainMembersDeletePoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*BlockchainMembersDeletePoller) FinalResponse ¶
func (p *BlockchainMembersDeletePoller) FinalResponse(ctx context.Context) (BlockchainMembersDeleteResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final BlockchainMembersDeleteResponse will be returned.
func (*BlockchainMembersDeletePoller) Poll ¶
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*BlockchainMembersDeletePoller) ResumeToken ¶
func (p *BlockchainMembersDeletePoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type BlockchainMembersDeletePollerResponse ¶
type BlockchainMembersDeletePollerResponse struct { // Poller contains an initialized poller. Poller *BlockchainMembersDeletePoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersDeletePollerResponse contains the response from method BlockchainMembers.Delete.
func (BlockchainMembersDeletePollerResponse) PollUntilDone ¶
func (l BlockchainMembersDeletePollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (BlockchainMembersDeleteResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*BlockchainMembersDeletePollerResponse) Resume ¶
func (l *BlockchainMembersDeletePollerResponse) Resume(ctx context.Context, client *BlockchainMembersClient, token string) error
Resume rehydrates a BlockchainMembersDeletePollerResponse from the provided client and resume token.
type BlockchainMembersDeleteResponse ¶
type BlockchainMembersDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersDeleteResponse contains the response from method BlockchainMembers.Delete.
type BlockchainMembersGetOptions ¶
type BlockchainMembersGetOptions struct { }
BlockchainMembersGetOptions contains the optional parameters for the BlockchainMembers.Get method.
type BlockchainMembersGetResponse ¶
type BlockchainMembersGetResponse struct { BlockchainMembersGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersGetResponse contains the response from method BlockchainMembers.Get.
type BlockchainMembersGetResult ¶
type BlockchainMembersGetResult struct {
BlockchainMember
}
BlockchainMembersGetResult contains the result from method BlockchainMembers.Get.
type BlockchainMembersListAPIKeysOptions ¶
type BlockchainMembersListAPIKeysOptions struct { }
BlockchainMembersListAPIKeysOptions contains the optional parameters for the BlockchainMembers.ListAPIKeys method.
type BlockchainMembersListAPIKeysResponse ¶
type BlockchainMembersListAPIKeysResponse struct { BlockchainMembersListAPIKeysResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersListAPIKeysResponse contains the response from method BlockchainMembers.ListAPIKeys.
type BlockchainMembersListAPIKeysResult ¶
type BlockchainMembersListAPIKeysResult struct {
APIKeyCollection
}
BlockchainMembersListAPIKeysResult contains the result from method BlockchainMembers.ListAPIKeys.
type BlockchainMembersListAllOptions ¶
type BlockchainMembersListAllOptions struct { }
BlockchainMembersListAllOptions contains the optional parameters for the BlockchainMembers.ListAll method.
type BlockchainMembersListAllPager ¶
type BlockchainMembersListAllPager struct {
// contains filtered or unexported fields
}
BlockchainMembersListAllPager provides operations for iterating over paged responses.
func (*BlockchainMembersListAllPager) Err ¶
func (p *BlockchainMembersListAllPager) Err() error
Err returns the last error encountered while paging.
func (*BlockchainMembersListAllPager) NextPage ¶
func (p *BlockchainMembersListAllPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*BlockchainMembersListAllPager) PageResponse ¶
func (p *BlockchainMembersListAllPager) PageResponse() BlockchainMembersListAllResponse
PageResponse returns the current BlockchainMembersListAllResponse page.
type BlockchainMembersListAllResponse ¶
type BlockchainMembersListAllResponse struct { BlockchainMembersListAllResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersListAllResponse contains the response from method BlockchainMembers.ListAll.
type BlockchainMembersListAllResult ¶
type BlockchainMembersListAllResult struct {
BlockchainMemberCollection
}
BlockchainMembersListAllResult contains the result from method BlockchainMembers.ListAll.
type BlockchainMembersListConsortiumMembersOptions ¶
type BlockchainMembersListConsortiumMembersOptions struct { }
BlockchainMembersListConsortiumMembersOptions contains the optional parameters for the BlockchainMembers.ListConsortiumMembers method.
type BlockchainMembersListConsortiumMembersPager ¶
type BlockchainMembersListConsortiumMembersPager struct {
// contains filtered or unexported fields
}
BlockchainMembersListConsortiumMembersPager provides operations for iterating over paged responses.
func (*BlockchainMembersListConsortiumMembersPager) Err ¶
func (p *BlockchainMembersListConsortiumMembersPager) Err() error
Err returns the last error encountered while paging.
func (*BlockchainMembersListConsortiumMembersPager) NextPage ¶
func (p *BlockchainMembersListConsortiumMembersPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*BlockchainMembersListConsortiumMembersPager) PageResponse ¶
func (p *BlockchainMembersListConsortiumMembersPager) PageResponse() BlockchainMembersListConsortiumMembersResponse
PageResponse returns the current BlockchainMembersListConsortiumMembersResponse page.
type BlockchainMembersListConsortiumMembersResponse ¶
type BlockchainMembersListConsortiumMembersResponse struct { BlockchainMembersListConsortiumMembersResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersListConsortiumMembersResponse contains the response from method BlockchainMembers.ListConsortiumMembers.
type BlockchainMembersListConsortiumMembersResult ¶
type BlockchainMembersListConsortiumMembersResult struct {
ConsortiumMemberCollection
}
BlockchainMembersListConsortiumMembersResult contains the result from method BlockchainMembers.ListConsortiumMembers.
type BlockchainMembersListOptions ¶
type BlockchainMembersListOptions struct { }
BlockchainMembersListOptions contains the optional parameters for the BlockchainMembers.List method.
type BlockchainMembersListPager ¶
type BlockchainMembersListPager struct {
// contains filtered or unexported fields
}
BlockchainMembersListPager provides operations for iterating over paged responses.
func (*BlockchainMembersListPager) Err ¶
func (p *BlockchainMembersListPager) Err() error
Err returns the last error encountered while paging.
func (*BlockchainMembersListPager) NextPage ¶
func (p *BlockchainMembersListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*BlockchainMembersListPager) PageResponse ¶
func (p *BlockchainMembersListPager) PageResponse() BlockchainMembersListResponse
PageResponse returns the current BlockchainMembersListResponse page.
type BlockchainMembersListRegenerateAPIKeysOptions ¶
type BlockchainMembersListRegenerateAPIKeysOptions struct { // api key to be regenerate APIKey *APIKey }
BlockchainMembersListRegenerateAPIKeysOptions contains the optional parameters for the BlockchainMembers.ListRegenerateAPIKeys method.
type BlockchainMembersListRegenerateAPIKeysResponse ¶
type BlockchainMembersListRegenerateAPIKeysResponse struct { BlockchainMembersListRegenerateAPIKeysResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersListRegenerateAPIKeysResponse contains the response from method BlockchainMembers.ListRegenerateAPIKeys.
type BlockchainMembersListRegenerateAPIKeysResult ¶
type BlockchainMembersListRegenerateAPIKeysResult struct {
APIKeyCollection
}
BlockchainMembersListRegenerateAPIKeysResult contains the result from method BlockchainMembers.ListRegenerateAPIKeys.
type BlockchainMembersListResponse ¶
type BlockchainMembersListResponse struct { BlockchainMembersListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersListResponse contains the response from method BlockchainMembers.List.
type BlockchainMembersListResult ¶
type BlockchainMembersListResult struct {
BlockchainMemberCollection
}
BlockchainMembersListResult contains the result from method BlockchainMembers.List.
type BlockchainMembersUpdateOptions ¶
type BlockchainMembersUpdateOptions struct { // Payload to update the blockchain member. BlockchainMember *BlockchainMemberUpdate }
BlockchainMembersUpdateOptions contains the optional parameters for the BlockchainMembers.Update method.
type BlockchainMembersUpdateResponse ¶
type BlockchainMembersUpdateResponse struct { BlockchainMembersUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
BlockchainMembersUpdateResponse contains the response from method BlockchainMembers.Update.
type BlockchainMembersUpdateResult ¶
type BlockchainMembersUpdateResult struct {
BlockchainMember
}
BlockchainMembersUpdateResult contains the result from method BlockchainMembers.Update.
type BlockchainProtocol ¶
type BlockchainProtocol string
BlockchainProtocol - Gets or sets the blockchain protocol.
const ( BlockchainProtocolCorda BlockchainProtocol = "Corda" BlockchainProtocolNotSpecified BlockchainProtocol = "NotSpecified" BlockchainProtocolParity BlockchainProtocol = "Parity" BlockchainProtocolQuorum BlockchainProtocol = "Quorum" )
func PossibleBlockchainProtocolValues ¶
func PossibleBlockchainProtocolValues() []BlockchainProtocol
PossibleBlockchainProtocolValues returns the possible values for the BlockchainProtocol const type.
func (BlockchainProtocol) ToPtr ¶
func (c BlockchainProtocol) ToPtr() *BlockchainProtocol
ToPtr returns a *BlockchainProtocol pointing to the current value.
type Consortium ¶
type Consortium struct { // Gets or sets the blockchain member name. Name *string `json:"name,omitempty"` // Gets or sets the protocol for the consortium. Protocol *BlockchainProtocol `json:"protocol,omitempty"` }
Consortium payload
type ConsortiumCollection ¶
type ConsortiumCollection struct { // Gets or sets the collection of consortiums. Value []*Consortium `json:"value,omitempty"` }
ConsortiumCollection - Collection of the consortium payload.
func (ConsortiumCollection) MarshalJSON ¶
func (c ConsortiumCollection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConsortiumCollection.
type ConsortiumMember ¶
type ConsortiumMember struct { // Gets the consortium member modified date. DateModified *time.Time `json:"dateModified,omitempty"` // Gets the consortium member display name. DisplayName *string `json:"displayName,omitempty"` // Gets the consortium member join date. JoinDate *time.Time `json:"joinDate,omitempty"` // Gets the consortium member name. Name *string `json:"name,omitempty"` // Gets the consortium member role. Role *string `json:"role,omitempty"` // Gets the consortium member status. Status *string `json:"status,omitempty"` // Gets the consortium member subscription id. SubscriptionID *string `json:"subscriptionId,omitempty"` }
ConsortiumMember - Consortium approval
func (ConsortiumMember) MarshalJSON ¶
func (c ConsortiumMember) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConsortiumMember.
func (*ConsortiumMember) UnmarshalJSON ¶
func (c *ConsortiumMember) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ConsortiumMember.
type ConsortiumMemberCollection ¶
type ConsortiumMemberCollection struct { // Gets or sets the URL, that the client should use to fetch the next page (per server side paging). It's null for now, added for future use. NextLink *string `json:"nextLink,omitempty"` // Gets or sets the collection of consortiums. Value []*ConsortiumMember `json:"value,omitempty"` }
ConsortiumMemberCollection - Collection of consortium payload.
func (ConsortiumMemberCollection) MarshalJSON ¶
func (c ConsortiumMemberCollection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ConsortiumMemberCollection.
type FirewallRule ¶
type FirewallRule struct { // Gets or sets the end IP address of the firewall rule range. EndIPAddress *string `json:"endIpAddress,omitempty"` // Gets or sets the name of the firewall rules. RuleName *string `json:"ruleName,omitempty"` // Gets or sets the start IP address of the firewall rule range. StartIPAddress *string `json:"startIpAddress,omitempty"` }
FirewallRule - Ip range for firewall rules
type LocationsCheckNameAvailabilityOptions ¶
type LocationsCheckNameAvailabilityOptions struct { // Name availability request payload. NameAvailabilityRequest *NameAvailabilityRequest }
LocationsCheckNameAvailabilityOptions contains the optional parameters for the Locations.CheckNameAvailability method.
type LocationsCheckNameAvailabilityResponse ¶
type LocationsCheckNameAvailabilityResponse struct { LocationsCheckNameAvailabilityResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
LocationsCheckNameAvailabilityResponse contains the response from method Locations.CheckNameAvailability.
type LocationsCheckNameAvailabilityResult ¶
type LocationsCheckNameAvailabilityResult struct {
NameAvailability
}
LocationsCheckNameAvailabilityResult contains the result from method Locations.CheckNameAvailability.
type LocationsClient ¶
type LocationsClient struct {
// contains filtered or unexported fields
}
LocationsClient contains the methods for the Locations group. Don't use this type directly, use NewLocationsClient() instead.
func NewLocationsClient ¶
func NewLocationsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *LocationsClient
NewLocationsClient creates a new instance of LocationsClient with the specified values.
func (*LocationsClient) CheckNameAvailability ¶
func (client *LocationsClient) CheckNameAvailability(ctx context.Context, locationName string, options *LocationsCheckNameAvailabilityOptions) (LocationsCheckNameAvailabilityResponse, error)
CheckNameAvailability - To check whether a resource name is available. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/Locations_CheckNameAvailability.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewLocationsClient("<subscription-id>", cred, nil) _, err = client.CheckNameAvailability(ctx, "<location-name>", &armblockchain.LocationsCheckNameAvailabilityOptions{NameAvailabilityRequest: &armblockchain.NameAvailabilityRequest{ Name: to.StringPtr("<name>"), Type: to.StringPtr("<type>"), }, }) if err != nil { log.Fatal(err) } }
Output:
func (*LocationsClient) ListConsortiums ¶
func (client *LocationsClient) ListConsortiums(ctx context.Context, locationName string, options *LocationsListConsortiumsOptions) (LocationsListConsortiumsResponse, error)
ListConsortiums - Lists the available consortiums for a subscription. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/Locations_ListConsortiums.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewLocationsClient("<subscription-id>", cred, nil) _, err = client.ListConsortiums(ctx, "<location-name>", nil) if err != nil { log.Fatal(err) } }
Output:
type LocationsListConsortiumsOptions ¶
type LocationsListConsortiumsOptions struct { }
LocationsListConsortiumsOptions contains the optional parameters for the Locations.ListConsortiums method.
type LocationsListConsortiumsResponse ¶
type LocationsListConsortiumsResponse struct { LocationsListConsortiumsResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
LocationsListConsortiumsResponse contains the response from method Locations.ListConsortiums.
type LocationsListConsortiumsResult ¶
type LocationsListConsortiumsResult struct {
ConsortiumCollection
}
LocationsListConsortiumsResult contains the result from method Locations.ListConsortiums.
type NameAvailability ¶
type NameAvailability struct { // Gets or sets the message. Message *string `json:"message,omitempty"` // Gets or sets the value indicating whether the name is available. NameAvailable *bool `json:"nameAvailable,omitempty"` // Gets or sets the name availability reason. Reason *NameAvailabilityReason `json:"reason,omitempty"` }
NameAvailability - Name availability payload which is exposed in the response of the resource provider.
type NameAvailabilityReason ¶
type NameAvailabilityReason string
NameAvailabilityReason - Gets or sets the name availability reason.
const ( NameAvailabilityReasonAlreadyExists NameAvailabilityReason = "AlreadyExists" NameAvailabilityReasonInvalid NameAvailabilityReason = "Invalid" NameAvailabilityReasonNotSpecified NameAvailabilityReason = "NotSpecified" )
func PossibleNameAvailabilityReasonValues ¶
func PossibleNameAvailabilityReasonValues() []NameAvailabilityReason
PossibleNameAvailabilityReasonValues returns the possible values for the NameAvailabilityReason const type.
func (NameAvailabilityReason) ToPtr ¶
func (c NameAvailabilityReason) ToPtr() *NameAvailabilityReason
ToPtr returns a *NameAvailabilityReason pointing to the current value.
type NameAvailabilityRequest ¶
type NameAvailabilityRequest struct { // Gets or sets the name to check. Name *string `json:"name,omitempty"` // Gets or sets the type of the resource to check. Type *string `json:"type,omitempty"` }
NameAvailabilityRequest - Name availability request payload which is exposed in the request of the resource provider.
type NodeProvisioningState ¶
type NodeProvisioningState string
NodeProvisioningState - Gets or sets the blockchain member provision state.
const ( NodeProvisioningStateDeleting NodeProvisioningState = "Deleting" NodeProvisioningStateFailed NodeProvisioningState = "Failed" NodeProvisioningStateNotSpecified NodeProvisioningState = "NotSpecified" NodeProvisioningStateSucceeded NodeProvisioningState = "Succeeded" NodeProvisioningStateUpdating NodeProvisioningState = "Updating" )
func PossibleNodeProvisioningStateValues ¶
func PossibleNodeProvisioningStateValues() []NodeProvisioningState
PossibleNodeProvisioningStateValues returns the possible values for the NodeProvisioningState const type.
func (NodeProvisioningState) ToPtr ¶
func (c NodeProvisioningState) ToPtr() *NodeProvisioningState
ToPtr returns a *NodeProvisioningState pointing to the current value.
type OperationResult ¶
type OperationResult struct { // Gets or sets the operation end time. EndTime *time.Time `json:"endTime,omitempty"` // Gets or sets the operation name. Name *string `json:"name,omitempty"` // Gets or sets the operation start time. StartTime *time.Time `json:"startTime,omitempty"` }
OperationResult - Operation result payload which is exposed in the response of the resource provider.
func (OperationResult) MarshalJSON ¶
func (o OperationResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationResult.
func (*OperationResult) UnmarshalJSON ¶
func (o *OperationResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationResult.
type OperationsClient ¶
type OperationsClient struct {
// contains filtered or unexported fields
}
OperationsClient contains the methods for the Operations group. Don't use this type directly, use NewOperationsClient() instead.
func NewOperationsClient ¶
func NewOperationsClient(credential azcore.TokenCredential, options *arm.ClientOptions) *OperationsClient
NewOperationsClient creates a new instance of OperationsClient with the specified values.
func (*OperationsClient) List ¶
func (client *OperationsClient) List(options *OperationsListOptions) *OperationsListPager
List - Lists the available operations of Microsoft.Blockchain resource provider. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/Operations_List.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewOperationsClient(cred, nil) pager := client.List(nil) for pager.NextPage(ctx) { if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } } }
Output:
type OperationsListOptions ¶
type OperationsListOptions struct { }
OperationsListOptions contains the optional parameters for the Operations.List method.
type OperationsListPager ¶
type OperationsListPager struct {
// contains filtered or unexported fields
}
OperationsListPager provides operations for iterating over paged responses.
func (*OperationsListPager) Err ¶
func (p *OperationsListPager) Err() error
Err returns the last error encountered while paging.
func (*OperationsListPager) NextPage ¶
func (p *OperationsListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*OperationsListPager) PageResponse ¶
func (p *OperationsListPager) PageResponse() OperationsListResponse
PageResponse returns the current OperationsListResponse page.
type OperationsListResponse ¶
type OperationsListResponse struct { OperationsListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
OperationsListResponse contains the response from method Operations.List.
type OperationsListResult ¶
type OperationsListResult struct {
ResourceProviderOperationCollection
}
OperationsListResult contains the result from method Operations.List.
type Resource ¶
type Resource struct { // READ-ONLY; Fully qualified resource Id of the resource. ID *string `json:"id,omitempty" azure:"ro"` // READ-ONLY; The name of the resource. Name *string `json:"name,omitempty" azure:"ro"` // READ-ONLY; The type of the service - e.g. "Microsoft.Blockchain" Type *string `json:"type,omitempty" azure:"ro"` }
Resource - The core properties of the resources.
func (Resource) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Resource.
type ResourceProviderOperation ¶
type ResourceProviderOperation struct { // Gets or sets operation display Display *ResourceProviderOperationDisplay `json:"display,omitempty"` // Gets or sets a value indicating whether the operation is a data action or not. IsDataAction *bool `json:"isDataAction,omitempty"` // Gets or sets the operation name. Name *string `json:"name,omitempty"` // Gets or sets the origin. Origin *string `json:"origin,omitempty"` }
ResourceProviderOperation - Operation payload which is exposed in the response of the resource provider.
type ResourceProviderOperationCollection ¶
type ResourceProviderOperationCollection struct { // Gets or sets the URL, that the client should use to fetch the next page (per server side paging). It's null for now, added for future use. NextLink *string `json:"nextLink,omitempty"` // Gets or sets the collection of operations. Value []*ResourceProviderOperation `json:"value,omitempty"` }
ResourceProviderOperationCollection - Collection of operation payload which is exposed in the response of the resource provider.
func (ResourceProviderOperationCollection) MarshalJSON ¶
func (r ResourceProviderOperationCollection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ResourceProviderOperationCollection.
type ResourceProviderOperationDisplay ¶
type ResourceProviderOperationDisplay struct { // Gets or sets the description of the provider for display purposes. Description *string `json:"description,omitempty"` // Gets or sets the name of the operation for display purposes. Operation *string `json:"operation,omitempty"` // Gets or sets the name of the provider for display purposes. Provider *string `json:"provider,omitempty"` // Gets or sets the name of the resource type for display purposes. Resource *string `json:"resource,omitempty"` }
ResourceProviderOperationDisplay - Operation display payload which is exposed in the response of the resource provider.
type ResourceTypeSKU ¶
type ResourceTypeSKU struct { // Gets or sets the resource type ResourceType *string `json:"resourceType,omitempty"` // Gets or sets the Skus SKUs []*SKUSetting `json:"skus,omitempty"` }
ResourceTypeSKU - Resource type Sku.
func (ResourceTypeSKU) MarshalJSON ¶
func (r ResourceTypeSKU) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ResourceTypeSKU.
type ResourceTypeSKUCollection ¶
type ResourceTypeSKUCollection struct { // Gets or sets the collection of resource type Sku. Value []*ResourceTypeSKU `json:"value,omitempty"` }
ResourceTypeSKUCollection - Collection of the resource type Sku.
func (ResourceTypeSKUCollection) MarshalJSON ¶
func (r ResourceTypeSKUCollection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ResourceTypeSKUCollection.
type SKU ¶
type SKU struct { // Gets or sets Sku name Name *string `json:"name,omitempty"` // Gets or sets Sku tier Tier *string `json:"tier,omitempty"` }
SKU - Blockchain member Sku in payload
type SKUSetting ¶
type SKUSetting struct { // Gets or sets the locations. Locations []*string `json:"locations,omitempty"` // Gets or sets the Sku name. Name *string `json:"name,omitempty"` // Gets or sets the required features. RequiredFeatures []*string `json:"requiredFeatures,omitempty"` // Gets or sets the Sku tier. Tier *string `json:"tier,omitempty"` }
SKUSetting - Sku Setting.
func (SKUSetting) MarshalJSON ¶
func (s SKUSetting) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SKUSetting.
type SKUsClient ¶
type SKUsClient struct {
// contains filtered or unexported fields
}
SKUsClient contains the methods for the SKUs group. Don't use this type directly, use NewSKUsClient() instead.
func NewSKUsClient ¶
func NewSKUsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *SKUsClient
NewSKUsClient creates a new instance of SKUsClient with the specified values.
func (*SKUsClient) List ¶
func (client *SKUsClient) List(ctx context.Context, options *SKUsListOptions) (SKUsListResponse, error)
List - Lists the Skus of the resource type. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/Skus_List.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewSKUsClient("<subscription-id>", cred, nil) _, err = client.List(ctx, nil) if err != nil { log.Fatal(err) } }
Output:
type SKUsListOptions ¶
type SKUsListOptions struct { }
SKUsListOptions contains the optional parameters for the SKUs.List method.
type SKUsListResponse ¶
type SKUsListResponse struct { SKUsListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
SKUsListResponse contains the response from method SKUs.List.
type SKUsListResult ¶
type SKUsListResult struct {
ResourceTypeSKUCollection
}
SKUsListResult contains the result from method SKUs.List.
type TrackedResource ¶
type TrackedResource struct { Resource // The GEO location of the blockchain service. Location *string `json:"location,omitempty"` // Tags of the service which is a list of key value pairs that describes the resource. Tags map[string]*string `json:"tags,omitempty"` }
TrackedResource - The resource model definition for a top level resource.
func (TrackedResource) MarshalJSON ¶
func (t TrackedResource) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TrackedResource.
type TransactionNode ¶
type TransactionNode struct { Resource // Gets or sets the transaction node location. Location *string `json:"location,omitempty"` // Gets or sets the blockchain member properties. Properties *TransactionNodeProperties `json:"properties,omitempty"` }
TransactionNode - Payload of the transaction node which is the request/response of the resource provider.
func (TransactionNode) MarshalJSON ¶
func (t TransactionNode) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TransactionNode.
type TransactionNodeCollection ¶
type TransactionNodeCollection struct { // Gets or sets the URL, that the client should use to fetch the next page (per server side paging). It's null for now, added for future use. NextLink *string `json:"nextLink,omitempty"` // Gets or sets the collection of transaction nodes. Value []*TransactionNode `json:"value,omitempty"` }
TransactionNodeCollection - Collection of transaction node payload which is exposed in the request/response of the resource provider.
func (TransactionNodeCollection) MarshalJSON ¶
func (t TransactionNodeCollection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TransactionNodeCollection.
type TransactionNodeProperties ¶
type TransactionNodeProperties struct { // Gets or sets the firewall rules. FirewallRules []*FirewallRule `json:"firewallRules,omitempty"` // Sets the transaction node dns endpoint basic auth password. Password *string `json:"password,omitempty"` // READ-ONLY; Gets or sets the transaction node dns endpoint. DNS *string `json:"dns,omitempty" azure:"ro"` // READ-ONLY; Gets or sets the blockchain member provision state. ProvisioningState *NodeProvisioningState `json:"provisioningState,omitempty" azure:"ro"` // READ-ONLY; Gets or sets the transaction node public key. PublicKey *string `json:"publicKey,omitempty" azure:"ro"` // READ-ONLY; Gets or sets the transaction node dns endpoint basic auth user name. UserName *string `json:"userName,omitempty" azure:"ro"` }
TransactionNodeProperties - Payload of transaction node properties payload in the transaction node payload.
func (TransactionNodeProperties) MarshalJSON ¶
func (t TransactionNodeProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TransactionNodeProperties.
type TransactionNodePropertiesUpdate ¶
type TransactionNodePropertiesUpdate struct { // Gets or sets the firewall rules. FirewallRules []*FirewallRule `json:"firewallRules,omitempty"` // Sets the transaction node dns endpoint basic auth password. Password *string `json:"password,omitempty"` }
TransactionNodePropertiesUpdate - Update the payload of the transaction node properties in the transaction node payload.
func (TransactionNodePropertiesUpdate) MarshalJSON ¶
func (t TransactionNodePropertiesUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TransactionNodePropertiesUpdate.
type TransactionNodeUpdate ¶
type TransactionNodeUpdate struct { // Gets or sets the transaction node update properties. Properties *TransactionNodePropertiesUpdate `json:"properties,omitempty"` }
TransactionNodeUpdate - Update the transaction node payload which is exposed in the request/response of the resource provider.
func (TransactionNodeUpdate) MarshalJSON ¶
func (t TransactionNodeUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type TransactionNodeUpdate.
type TransactionNodesBeginCreateOptions ¶
type TransactionNodesBeginCreateOptions struct { // Payload to create the transaction node. TransactionNode *TransactionNode }
TransactionNodesBeginCreateOptions contains the optional parameters for the TransactionNodes.BeginCreate method.
type TransactionNodesBeginDeleteOptions ¶
type TransactionNodesBeginDeleteOptions struct { }
TransactionNodesBeginDeleteOptions contains the optional parameters for the TransactionNodes.BeginDelete method.
type TransactionNodesClient ¶
type TransactionNodesClient struct {
// contains filtered or unexported fields
}
TransactionNodesClient contains the methods for the TransactionNodes group. Don't use this type directly, use NewTransactionNodesClient() instead.
func NewTransactionNodesClient ¶
func NewTransactionNodesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) *TransactionNodesClient
NewTransactionNodesClient creates a new instance of TransactionNodesClient with the specified values.
func (*TransactionNodesClient) BeginCreate ¶
func (client *TransactionNodesClient) BeginCreate(ctx context.Context, blockchainMemberName string, transactionNodeName string, resourceGroupName string, options *TransactionNodesBeginCreateOptions) (TransactionNodesCreatePollerResponse, error)
BeginCreate - Create or update the transaction node. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/TransactionNodes_Create.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewTransactionNodesClient("<subscription-id>", cred, nil) poller, err := client.BeginCreate(ctx, "<blockchain-member-name>", "<transaction-node-name>", "<resource-group-name>", &armblockchain.TransactionNodesBeginCreateOptions{TransactionNode: &armblockchain.TransactionNode{ Location: to.StringPtr("<location>"), Properties: &armblockchain.TransactionNodeProperties{ Password: to.StringPtr("<password>"), }, }, }) if err != nil { log.Fatal(err) } res, err := poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } log.Printf("TransactionNode.ID: %s\n", *res.ID) }
Output:
func (*TransactionNodesClient) BeginDelete ¶
func (client *TransactionNodesClient) BeginDelete(ctx context.Context, blockchainMemberName string, transactionNodeName string, resourceGroupName string, options *TransactionNodesBeginDeleteOptions) (TransactionNodesDeletePollerResponse, error)
BeginDelete - Delete the transaction node. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/TransactionNodes_Delete.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewTransactionNodesClient("<subscription-id>", cred, nil) poller, err := client.BeginDelete(ctx, "<blockchain-member-name>", "<transaction-node-name>", "<resource-group-name>", nil) if err != nil { log.Fatal(err) } _, err = poller.PollUntilDone(ctx, 30*time.Second) if err != nil { log.Fatal(err) } }
Output:
func (*TransactionNodesClient) Get ¶
func (client *TransactionNodesClient) Get(ctx context.Context, blockchainMemberName string, transactionNodeName string, resourceGroupName string, options *TransactionNodesGetOptions) (TransactionNodesGetResponse, error)
Get - Get the details of the transaction node. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/TransactionNodes_Get.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewTransactionNodesClient("<subscription-id>", cred, nil) res, err := client.Get(ctx, "<blockchain-member-name>", "<transaction-node-name>", "<resource-group-name>", nil) if err != nil { log.Fatal(err) } log.Printf("TransactionNode.ID: %s\n", *res.ID) }
Output:
func (*TransactionNodesClient) List ¶
func (client *TransactionNodesClient) List(blockchainMemberName string, resourceGroupName string, options *TransactionNodesListOptions) *TransactionNodesListPager
List - Lists the transaction nodes for a blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/TransactionNodes_List.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewTransactionNodesClient("<subscription-id>", cred, nil) pager := client.List("<blockchain-member-name>", "<resource-group-name>", nil) for pager.NextPage(ctx) { if err := pager.Err(); err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range pager.PageResponse().Value { log.Printf("TransactionNode.ID: %s\n", *v.ID) } } }
Output:
func (*TransactionNodesClient) ListAPIKeys ¶
func (client *TransactionNodesClient) ListAPIKeys(ctx context.Context, blockchainMemberName string, transactionNodeName string, resourceGroupName string, options *TransactionNodesListAPIKeysOptions) (TransactionNodesListAPIKeysResponse, error)
ListAPIKeys - List the API keys for the transaction node. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/TransactionNodes_ListApiKeys.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewTransactionNodesClient("<subscription-id>", cred, nil) _, err = client.ListAPIKeys(ctx, "<blockchain-member-name>", "<transaction-node-name>", "<resource-group-name>", nil) if err != nil { log.Fatal(err) } }
Output:
func (*TransactionNodesClient) ListRegenerateAPIKeys ¶
func (client *TransactionNodesClient) ListRegenerateAPIKeys(ctx context.Context, blockchainMemberName string, transactionNodeName string, resourceGroupName string, options *TransactionNodesListRegenerateAPIKeysOptions) (TransactionNodesListRegenerateAPIKeysResponse, error)
ListRegenerateAPIKeys - Regenerate the API keys for the blockchain member. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/TransactionNodes_ListRegenerateApiKeys.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewTransactionNodesClient("<subscription-id>", cred, nil) _, err = client.ListRegenerateAPIKeys(ctx, "<blockchain-member-name>", "<transaction-node-name>", "<resource-group-name>", &armblockchain.TransactionNodesListRegenerateAPIKeysOptions{APIKey: &armblockchain.APIKey{ KeyName: to.StringPtr("<key-name>"), }, }) if err != nil { log.Fatal(err) } }
Output:
func (*TransactionNodesClient) Update ¶
func (client *TransactionNodesClient) Update(ctx context.Context, blockchainMemberName string, transactionNodeName string, resourceGroupName string, options *TransactionNodesUpdateOptions) (TransactionNodesUpdateResponse, error)
Update - Update the transaction node. If the operation fails it returns a generic error.
Example ¶
x-ms-original-file: specification/blockchain/resource-manager/Microsoft.Blockchain/preview/2018-06-01-preview/examples/TransactionNodes_Update.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/blockchain/armblockchain" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() client := armblockchain.NewTransactionNodesClient("<subscription-id>", cred, nil) res, err := client.Update(ctx, "<blockchain-member-name>", "<transaction-node-name>", "<resource-group-name>", &armblockchain.TransactionNodesUpdateOptions{TransactionNode: &armblockchain.TransactionNodeUpdate{ Properties: &armblockchain.TransactionNodePropertiesUpdate{ Password: to.StringPtr("<password>"), }, }, }) if err != nil { log.Fatal(err) } log.Printf("TransactionNode.ID: %s\n", *res.ID) }
Output:
type TransactionNodesCreatePoller ¶
type TransactionNodesCreatePoller struct {
// contains filtered or unexported fields
}
TransactionNodesCreatePoller provides polling facilities until the operation reaches a terminal state.
func (*TransactionNodesCreatePoller) Done ¶
func (p *TransactionNodesCreatePoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*TransactionNodesCreatePoller) FinalResponse ¶
func (p *TransactionNodesCreatePoller) FinalResponse(ctx context.Context) (TransactionNodesCreateResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final TransactionNodesCreateResponse will be returned.
func (*TransactionNodesCreatePoller) Poll ¶
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*TransactionNodesCreatePoller) ResumeToken ¶
func (p *TransactionNodesCreatePoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type TransactionNodesCreatePollerResponse ¶
type TransactionNodesCreatePollerResponse struct { // Poller contains an initialized poller. Poller *TransactionNodesCreatePoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesCreatePollerResponse contains the response from method TransactionNodes.Create.
func (TransactionNodesCreatePollerResponse) PollUntilDone ¶
func (l TransactionNodesCreatePollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (TransactionNodesCreateResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*TransactionNodesCreatePollerResponse) Resume ¶
func (l *TransactionNodesCreatePollerResponse) Resume(ctx context.Context, client *TransactionNodesClient, token string) error
Resume rehydrates a TransactionNodesCreatePollerResponse from the provided client and resume token.
type TransactionNodesCreateResponse ¶
type TransactionNodesCreateResponse struct { TransactionNodesCreateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesCreateResponse contains the response from method TransactionNodes.Create.
type TransactionNodesCreateResult ¶
type TransactionNodesCreateResult struct {
TransactionNode
}
TransactionNodesCreateResult contains the result from method TransactionNodes.Create.
type TransactionNodesDeletePoller ¶
type TransactionNodesDeletePoller struct {
// contains filtered or unexported fields
}
TransactionNodesDeletePoller provides polling facilities until the operation reaches a terminal state.
func (*TransactionNodesDeletePoller) Done ¶
func (p *TransactionNodesDeletePoller) Done() bool
Done returns true if the LRO has reached a terminal state.
func (*TransactionNodesDeletePoller) FinalResponse ¶
func (p *TransactionNodesDeletePoller) FinalResponse(ctx context.Context) (TransactionNodesDeleteResponse, error)
FinalResponse performs a final GET to the service and returns the final response for the polling operation. If there is an error performing the final GET then an error is returned. If the final GET succeeded then the final TransactionNodesDeleteResponse will be returned.
func (*TransactionNodesDeletePoller) Poll ¶
Poll fetches the latest state of the LRO. It returns an HTTP response or error. If the LRO has completed successfully, the poller's state is updated and the HTTP response is returned. If the LRO has completed with failure or was cancelled, the poller's state is updated and the error is returned. If the LRO has not reached a terminal state, the poller's state is updated and the latest HTTP response is returned. If Poll fails, the poller's state is unmodified and the error is returned. Calling Poll on an LRO that has reached a terminal state will return the final HTTP response or error.
func (*TransactionNodesDeletePoller) ResumeToken ¶
func (p *TransactionNodesDeletePoller) ResumeToken() (string, error)
ResumeToken returns a value representing the poller that can be used to resume the LRO at a later time. ResumeTokens are unique per service operation.
type TransactionNodesDeletePollerResponse ¶
type TransactionNodesDeletePollerResponse struct { // Poller contains an initialized poller. Poller *TransactionNodesDeletePoller // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesDeletePollerResponse contains the response from method TransactionNodes.Delete.
func (TransactionNodesDeletePollerResponse) PollUntilDone ¶
func (l TransactionNodesDeletePollerResponse) PollUntilDone(ctx context.Context, freq time.Duration) (TransactionNodesDeleteResponse, error)
PollUntilDone will poll the service endpoint until a terminal state is reached or an error is received. freq: the time to wait between intervals in absence of a Retry-After header. Allowed minimum is one second. A good starting value is 30 seconds. Note that some resources might benefit from a different value.
func (*TransactionNodesDeletePollerResponse) Resume ¶
func (l *TransactionNodesDeletePollerResponse) Resume(ctx context.Context, client *TransactionNodesClient, token string) error
Resume rehydrates a TransactionNodesDeletePollerResponse from the provided client and resume token.
type TransactionNodesDeleteResponse ¶
type TransactionNodesDeleteResponse struct { // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesDeleteResponse contains the response from method TransactionNodes.Delete.
type TransactionNodesGetOptions ¶
type TransactionNodesGetOptions struct { }
TransactionNodesGetOptions contains the optional parameters for the TransactionNodes.Get method.
type TransactionNodesGetResponse ¶
type TransactionNodesGetResponse struct { TransactionNodesGetResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesGetResponse contains the response from method TransactionNodes.Get.
type TransactionNodesGetResult ¶
type TransactionNodesGetResult struct {
TransactionNode
}
TransactionNodesGetResult contains the result from method TransactionNodes.Get.
type TransactionNodesListAPIKeysOptions ¶
type TransactionNodesListAPIKeysOptions struct { }
TransactionNodesListAPIKeysOptions contains the optional parameters for the TransactionNodes.ListAPIKeys method.
type TransactionNodesListAPIKeysResponse ¶
type TransactionNodesListAPIKeysResponse struct { TransactionNodesListAPIKeysResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesListAPIKeysResponse contains the response from method TransactionNodes.ListAPIKeys.
type TransactionNodesListAPIKeysResult ¶
type TransactionNodesListAPIKeysResult struct {
APIKeyCollection
}
TransactionNodesListAPIKeysResult contains the result from method TransactionNodes.ListAPIKeys.
type TransactionNodesListOptions ¶
type TransactionNodesListOptions struct { }
TransactionNodesListOptions contains the optional parameters for the TransactionNodes.List method.
type TransactionNodesListPager ¶
type TransactionNodesListPager struct {
// contains filtered or unexported fields
}
TransactionNodesListPager provides operations for iterating over paged responses.
func (*TransactionNodesListPager) Err ¶
func (p *TransactionNodesListPager) Err() error
Err returns the last error encountered while paging.
func (*TransactionNodesListPager) NextPage ¶
func (p *TransactionNodesListPager) NextPage(ctx context.Context) bool
NextPage returns true if the pager advanced to the next page. Returns false if there are no more pages or an error occurred.
func (*TransactionNodesListPager) PageResponse ¶
func (p *TransactionNodesListPager) PageResponse() TransactionNodesListResponse
PageResponse returns the current TransactionNodesListResponse page.
type TransactionNodesListRegenerateAPIKeysOptions ¶
type TransactionNodesListRegenerateAPIKeysOptions struct { // api key to be regenerated APIKey *APIKey }
TransactionNodesListRegenerateAPIKeysOptions contains the optional parameters for the TransactionNodes.ListRegenerateAPIKeys method.
type TransactionNodesListRegenerateAPIKeysResponse ¶
type TransactionNodesListRegenerateAPIKeysResponse struct { TransactionNodesListRegenerateAPIKeysResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesListRegenerateAPIKeysResponse contains the response from method TransactionNodes.ListRegenerateAPIKeys.
type TransactionNodesListRegenerateAPIKeysResult ¶
type TransactionNodesListRegenerateAPIKeysResult struct {
APIKeyCollection
}
TransactionNodesListRegenerateAPIKeysResult contains the result from method TransactionNodes.ListRegenerateAPIKeys.
type TransactionNodesListResponse ¶
type TransactionNodesListResponse struct { TransactionNodesListResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesListResponse contains the response from method TransactionNodes.List.
type TransactionNodesListResult ¶
type TransactionNodesListResult struct {
TransactionNodeCollection
}
TransactionNodesListResult contains the result from method TransactionNodes.List.
type TransactionNodesUpdateOptions ¶
type TransactionNodesUpdateOptions struct { // Payload to create the transaction node. TransactionNode *TransactionNodeUpdate }
TransactionNodesUpdateOptions contains the optional parameters for the TransactionNodes.Update method.
type TransactionNodesUpdateResponse ¶
type TransactionNodesUpdateResponse struct { TransactionNodesUpdateResult // RawResponse contains the underlying HTTP response. RawResponse *http.Response }
TransactionNodesUpdateResponse contains the response from method TransactionNodes.Update.
type TransactionNodesUpdateResult ¶
type TransactionNodesUpdateResult struct {
TransactionNode
}
TransactionNodesUpdateResult contains the result from method TransactionNodes.Update.
Source Files ¶
- build.go
- zz_generated_blockchainmemberoperationresults_client.go
- zz_generated_blockchainmembers_client.go
- zz_generated_constants.go
- zz_generated_locations_client.go
- zz_generated_models.go
- zz_generated_operations_client.go
- zz_generated_pagers.go
- zz_generated_pollers.go
- zz_generated_response_types.go
- zz_generated_skus_client.go
- zz_generated_time_rfc3339.go
- zz_generated_transactionnodes_client.go