const ( // DefaultBaseURI is the default URI used for the service Dns DefaultBaseURI = "https://management.azure.com" )
func UserAgent() string
UserAgent returns the UserAgent string to use when sending http.Requests.
func Version() string
Version returns the semantic version (see http://semver.org) of the client.
ARecord an A record.
type ARecord struct { // Ipv4Address - The IPv4 address of this A record. Ipv4Address *string `json:"ipv4Address,omitempty"` }
AaaaRecord an AAAA record.
type AaaaRecord struct { // Ipv6Address - The IPv6 address of this AAAA record. Ipv6Address *string `json:"ipv6Address,omitempty"` }
BaseClient is the base client for Dns.
type BaseClient struct { autorest.Client BaseURI string SubscriptionID string }
func New(subscriptionID string) BaseClient
New creates an instance of the BaseClient client.
func NewWithBaseURI(baseURI string, subscriptionID string) BaseClient
NewWithBaseURI creates an instance of the BaseClient client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
CaaRecord a CAA record.
type CaaRecord struct { // Flags - The flags for this CAA record as an integer between 0 and 255. Flags *int32 `json:"flags,omitempty"` // Tag - The tag for this CAA record. Tag *string `json:"tag,omitempty"` // Value - The value for this CAA record. Value *string `json:"value,omitempty"` }
CloudError an error response from the service.
type CloudError struct { // Error - Cloud error body. Error *CloudErrorBody `json:"error,omitempty"` }
CloudErrorBody an error response from the service.
type CloudErrorBody struct { // Code - An identifier for the error. Codes are invariant and are intended to be consumed programmatically. Code *string `json:"code,omitempty"` // Message - A message describing the error, intended to be suitable for display in a user interface. Message *string `json:"message,omitempty"` // Target - The target of the particular error. For example, the name of the property in error. Target *string `json:"target,omitempty"` // Details - A list of additional details about the error. Details *[]CloudErrorBody `json:"details,omitempty"` }
CnameRecord a CNAME record.
type CnameRecord struct { // Cname - The canonical name for this CNAME record. Cname *string `json:"cname,omitempty"` }
MxRecord an MX record.
type MxRecord struct { // Preference - The preference value for this MX record. Preference *int32 `json:"preference,omitempty"` // Exchange - The domain name of the mail host for this MX record. Exchange *string `json:"exchange,omitempty"` }
NsRecord an NS record.
type NsRecord struct { // Nsdname - The name server name for this NS record. Nsdname *string `json:"nsdname,omitempty"` }
PtrRecord a PTR record.
type PtrRecord struct { // Ptrdname - The PTR target domain name for this PTR record. Ptrdname *string `json:"ptrdname,omitempty"` }
RecordSet describes a DNS record set (a collection of DNS records with the same name and type).
type RecordSet struct { autorest.Response `json:"-"` // ID - READ-ONLY; The ID of the record set. ID *string `json:"id,omitempty"` // Name - READ-ONLY; The name of the record set. Name *string `json:"name,omitempty"` // Type - READ-ONLY; The type of the record set. Type *string `json:"type,omitempty"` // Etag - The etag of the record set. Etag *string `json:"etag,omitempty"` // RecordSetProperties - The properties of the record set. *RecordSetProperties `json:"properties,omitempty"` }
func (rs RecordSet) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for RecordSet.
func (rs *RecordSet) UnmarshalJSON(body []byte) error
UnmarshalJSON is the custom unmarshaler for RecordSet struct.
RecordSetListResult the response to a record set List operation.
type RecordSetListResult struct { autorest.Response `json:"-"` // Value - Information about the record sets in the response. Value *[]RecordSet `json:"value,omitempty"` // NextLink - READ-ONLY; The continuation token for the next page of results. NextLink *string `json:"nextLink,omitempty"` }
func (rslr RecordSetListResult) IsEmpty() bool
IsEmpty returns true if the ListResult contains no values.
func (rslr RecordSetListResult) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for RecordSetListResult.
RecordSetListResultIterator provides access to a complete listing of RecordSet values.
type RecordSetListResultIterator struct {
// contains filtered or unexported fields
}
func NewRecordSetListResultIterator(page RecordSetListResultPage) RecordSetListResultIterator
Creates a new instance of the RecordSetListResultIterator type.
func (iter *RecordSetListResultIterator) Next() error
Next advances to the next value. If there was an error making the request the iterator does not advance and the error is returned. Deprecated: Use NextWithContext() instead.
func (iter *RecordSetListResultIterator) NextWithContext(ctx context.Context) (err error)
NextWithContext advances to the next value. If there was an error making the request the iterator does not advance and the error is returned.
func (iter RecordSetListResultIterator) NotDone() bool
NotDone returns true if the enumeration should be started or is not yet complete.
func (iter RecordSetListResultIterator) Response() RecordSetListResult
Response returns the raw server response from the last page request.
func (iter RecordSetListResultIterator) Value() RecordSet
Value returns the current value or a zero-initialized value if the iterator has advanced beyond the end of the collection.
RecordSetListResultPage contains a page of RecordSet values.
type RecordSetListResultPage struct {
// contains filtered or unexported fields
}
func NewRecordSetListResultPage(cur RecordSetListResult, getNextPage func(context.Context, RecordSetListResult) (RecordSetListResult, error)) RecordSetListResultPage
Creates a new instance of the RecordSetListResultPage type.
func (page *RecordSetListResultPage) Next() error
Next advances to the next page of values. If there was an error making the request the page does not advance and the error is returned. Deprecated: Use NextWithContext() instead.
func (page *RecordSetListResultPage) NextWithContext(ctx context.Context) (err error)
NextWithContext advances to the next page of values. If there was an error making the request the page does not advance and the error is returned.
func (page RecordSetListResultPage) NotDone() bool
NotDone returns true if the page enumeration should be started or is not yet complete.
func (page RecordSetListResultPage) Response() RecordSetListResult
Response returns the raw server response from the last page request.
func (page RecordSetListResultPage) Values() []RecordSet
Values returns the slice of values for the current page or nil if there are no values.
RecordSetProperties represents the properties of the records in the record set.
type RecordSetProperties struct { // Metadata - The metadata attached to the record set. Metadata map[string]*string `json:"metadata"` // TTL - The TTL (time-to-live) of the records in the record set. TTL *int64 `json:"TTL,omitempty"` // Fqdn - READ-ONLY; Fully qualified domain name of the record set. Fqdn *string `json:"fqdn,omitempty"` // ProvisioningState - READ-ONLY; provisioning State of the record set. ProvisioningState *string `json:"provisioningState,omitempty"` // TargetResource - A reference to an azure resource from where the dns resource value is taken. TargetResource *SubResource `json:"targetResource,omitempty"` // ARecords - The list of A records in the record set. ARecords *[]ARecord `json:"ARecords,omitempty"` // AaaaRecords - The list of AAAA records in the record set. AaaaRecords *[]AaaaRecord `json:"AAAARecords,omitempty"` // MxRecords - The list of MX records in the record set. MxRecords *[]MxRecord `json:"MXRecords,omitempty"` // NsRecords - The list of NS records in the record set. NsRecords *[]NsRecord `json:"NSRecords,omitempty"` // PtrRecords - The list of PTR records in the record set. PtrRecords *[]PtrRecord `json:"PTRRecords,omitempty"` // SrvRecords - The list of SRV records in the record set. SrvRecords *[]SrvRecord `json:"SRVRecords,omitempty"` // TxtRecords - The list of TXT records in the record set. TxtRecords *[]TxtRecord `json:"TXTRecords,omitempty"` // CnameRecord - The CNAME record in the record set. CnameRecord *CnameRecord `json:"CNAMERecord,omitempty"` // SoaRecord - The SOA record in the record set. SoaRecord *SoaRecord `json:"SOARecord,omitempty"` // CaaRecords - The list of CAA records in the record set. CaaRecords *[]CaaRecord `json:"caaRecords,omitempty"` }
func (rsp RecordSetProperties) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for RecordSetProperties.
RecordSetUpdateParameters parameters supplied to update a record set.
type RecordSetUpdateParameters struct { // RecordSet - Specifies information about the record set being updated. RecordSet *RecordSet `json:"RecordSet,omitempty"` }
RecordSetsClient is the the DNS Management Client.
type RecordSetsClient struct { BaseClient }
func NewRecordSetsClient(subscriptionID string) RecordSetsClient
NewRecordSetsClient creates an instance of the RecordSetsClient client.
func NewRecordSetsClientWithBaseURI(baseURI string, subscriptionID string) RecordSetsClient
NewRecordSetsClientWithBaseURI creates an instance of the RecordSetsClient client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
func (client RecordSetsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, zoneName string, relativeRecordSetName string, recordType RecordType, parameters RecordSet, ifMatch string, ifNoneMatch string) (result RecordSet, err error)
CreateOrUpdate creates or updates a record set within a DNS zone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). relativeRecordSetName - the name of the record set, relative to the name of the zone. recordType - the type of DNS record in this record set. Record sets of type SOA can be updated but not created (they are created when the DNS zone is created). parameters - parameters supplied to the CreateOrUpdate operation. ifMatch - the etag of the record set. Omit this value to always overwrite the current record set. Specify the last-seen etag value to prevent accidentally overwriting any concurrent changes. ifNoneMatch - set to '*' to allow a new record set to be created, but to prevent updating an existing record set. Other values will be ignored.
func (client RecordSetsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, zoneName string, relativeRecordSetName string, recordType RecordType, parameters RecordSet, ifMatch string, ifNoneMatch string) (*http.Request, error)
CreateOrUpdatePreparer prepares the CreateOrUpdate request.
func (client RecordSetsClient) CreateOrUpdateResponder(resp *http.Response) (result RecordSet, err error)
CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always closes the http.Response Body.
func (client RecordSetsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error)
CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the http.Response Body if it receives an error.
func (client RecordSetsClient) Delete(ctx context.Context, resourceGroupName string, zoneName string, relativeRecordSetName string, recordType RecordType, ifMatch string) (result autorest.Response, err error)
Delete deletes a record set from a DNS zone. This operation cannot be undone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). relativeRecordSetName - the name of the record set, relative to the name of the zone. recordType - the type of DNS record in this record set. Record sets of type SOA cannot be deleted (they are deleted when the DNS zone is deleted). ifMatch - the etag of the record set. Omit this value to always delete the current record set. Specify the last-seen etag value to prevent accidentally deleting any concurrent changes.
func (client RecordSetsClient) DeletePreparer(ctx context.Context, resourceGroupName string, zoneName string, relativeRecordSetName string, recordType RecordType, ifMatch string) (*http.Request, error)
DeletePreparer prepares the Delete request.
func (client RecordSetsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error)
DeleteResponder handles the response to the Delete request. The method always closes the http.Response Body.
func (client RecordSetsClient) DeleteSender(req *http.Request) (*http.Response, error)
DeleteSender sends the Delete request. The method will close the http.Response Body if it receives an error.
func (client RecordSetsClient) Get(ctx context.Context, resourceGroupName string, zoneName string, relativeRecordSetName string, recordType RecordType) (result RecordSet, err error)
Get gets a record set. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). relativeRecordSetName - the name of the record set, relative to the name of the zone. recordType - the type of DNS record in this record set.
func (client RecordSetsClient) GetPreparer(ctx context.Context, resourceGroupName string, zoneName string, relativeRecordSetName string, recordType RecordType) (*http.Request, error)
GetPreparer prepares the Get request.
func (client RecordSetsClient) GetResponder(resp *http.Response) (result RecordSet, err error)
GetResponder handles the response to the Get request. The method always closes the http.Response Body.
func (client RecordSetsClient) GetSender(req *http.Request) (*http.Response, error)
GetSender sends the Get request. The method will close the http.Response Body if it receives an error.
func (client RecordSetsClient) ListAllByDNSZone(ctx context.Context, resourceGroupName string, zoneName string, top *int32, recordSetNameSuffix string) (result RecordSetListResultPage, err error)
ListAllByDNSZone lists all record sets in a DNS zone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). top - the maximum number of record sets to return. If not specified, returns up to 100 record sets. recordSetNameSuffix - the suffix label of the record set name that has to be used to filter the record set enumerations. If this parameter is specified, Enumeration will return only records that end with .<recordSetNameSuffix>
func (client RecordSetsClient) ListAllByDNSZoneComplete(ctx context.Context, resourceGroupName string, zoneName string, top *int32, recordSetNameSuffix string) (result RecordSetListResultIterator, err error)
ListAllByDNSZoneComplete enumerates all values, automatically crossing page boundaries as required.
func (client RecordSetsClient) ListAllByDNSZonePreparer(ctx context.Context, resourceGroupName string, zoneName string, top *int32, recordSetNameSuffix string) (*http.Request, error)
ListAllByDNSZonePreparer prepares the ListAllByDNSZone request.
func (client RecordSetsClient) ListAllByDNSZoneResponder(resp *http.Response) (result RecordSetListResult, err error)
ListAllByDNSZoneResponder handles the response to the ListAllByDNSZone request. The method always closes the http.Response Body.
func (client RecordSetsClient) ListAllByDNSZoneSender(req *http.Request) (*http.Response, error)
ListAllByDNSZoneSender sends the ListAllByDNSZone request. The method will close the http.Response Body if it receives an error.
func (client RecordSetsClient) ListByDNSZone(ctx context.Context, resourceGroupName string, zoneName string, top *int32, recordsetnamesuffix string) (result RecordSetListResultPage, err error)
ListByDNSZone lists all record sets in a DNS zone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). top - the maximum number of record sets to return. If not specified, returns up to 100 record sets. recordsetnamesuffix - the suffix label of the record set name that has to be used to filter the record set enumerations. If this parameter is specified, Enumeration will return only records that end with .<recordSetNameSuffix>
func (client RecordSetsClient) ListByDNSZoneComplete(ctx context.Context, resourceGroupName string, zoneName string, top *int32, recordsetnamesuffix string) (result RecordSetListResultIterator, err error)
ListByDNSZoneComplete enumerates all values, automatically crossing page boundaries as required.
func (client RecordSetsClient) ListByDNSZonePreparer(ctx context.Context, resourceGroupName string, zoneName string, top *int32, recordsetnamesuffix string) (*http.Request, error)
ListByDNSZonePreparer prepares the ListByDNSZone request.
func (client RecordSetsClient) ListByDNSZoneResponder(resp *http.Response) (result RecordSetListResult, err error)
ListByDNSZoneResponder handles the response to the ListByDNSZone request. The method always closes the http.Response Body.
func (client RecordSetsClient) ListByDNSZoneSender(req *http.Request) (*http.Response, error)
ListByDNSZoneSender sends the ListByDNSZone request. The method will close the http.Response Body if it receives an error.
func (client RecordSetsClient) ListByType(ctx context.Context, resourceGroupName string, zoneName string, recordType RecordType, top *int32, recordsetnamesuffix string) (result RecordSetListResultPage, err error)
ListByType lists the record sets of a specified type in a DNS zone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). recordType - the type of record sets to enumerate. top - the maximum number of record sets to return. If not specified, returns up to 100 record sets. recordsetnamesuffix - the suffix label of the record set name that has to be used to filter the record set enumerations. If this parameter is specified, Enumeration will return only records that end with .<recordSetNameSuffix>
func (client RecordSetsClient) ListByTypeComplete(ctx context.Context, resourceGroupName string, zoneName string, recordType RecordType, top *int32, recordsetnamesuffix string) (result RecordSetListResultIterator, err error)
ListByTypeComplete enumerates all values, automatically crossing page boundaries as required.
func (client RecordSetsClient) ListByTypePreparer(ctx context.Context, resourceGroupName string, zoneName string, recordType RecordType, top *int32, recordsetnamesuffix string) (*http.Request, error)
ListByTypePreparer prepares the ListByType request.
func (client RecordSetsClient) ListByTypeResponder(resp *http.Response) (result RecordSetListResult, err error)
ListByTypeResponder handles the response to the ListByType request. The method always closes the http.Response Body.
func (client RecordSetsClient) ListByTypeSender(req *http.Request) (*http.Response, error)
ListByTypeSender sends the ListByType request. The method will close the http.Response Body if it receives an error.
func (client RecordSetsClient) Update(ctx context.Context, resourceGroupName string, zoneName string, relativeRecordSetName string, recordType RecordType, parameters RecordSet, ifMatch string) (result RecordSet, err error)
Update updates a record set within a DNS zone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). relativeRecordSetName - the name of the record set, relative to the name of the zone. recordType - the type of DNS record in this record set. parameters - parameters supplied to the Update operation. ifMatch - the etag of the record set. Omit this value to always overwrite the current record set. Specify the last-seen etag value to prevent accidentally overwriting concurrent changes.
func (client RecordSetsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, zoneName string, relativeRecordSetName string, recordType RecordType, parameters RecordSet, ifMatch string) (*http.Request, error)
UpdatePreparer prepares the Update request.
func (client RecordSetsClient) UpdateResponder(resp *http.Response) (result RecordSet, err error)
UpdateResponder handles the response to the Update request. The method always closes the http.Response Body.
func (client RecordSetsClient) UpdateSender(req *http.Request) (*http.Response, error)
UpdateSender sends the Update request. The method will close the http.Response Body if it receives an error.
RecordType enumerates the values for record type.
type RecordType string
const ( // A ... A RecordType = "A" // AAAA ... AAAA RecordType = "AAAA" // CAA ... CAA RecordType = "CAA" // CNAME ... CNAME RecordType = "CNAME" // MX ... MX RecordType = "MX" // NS ... NS RecordType = "NS" // PTR ... PTR RecordType = "PTR" // SOA ... SOA RecordType = "SOA" // SRV ... SRV RecordType = "SRV" // TXT ... TXT RecordType = "TXT" )
func PossibleRecordTypeValues() []RecordType
PossibleRecordTypeValues returns an array of possible values for the RecordType const type.
Resource common properties of an Azure Resource Manager resource
type Resource struct { // ID - READ-ONLY; Resource ID. ID *string `json:"id,omitempty"` // Name - READ-ONLY; Resource name. Name *string `json:"name,omitempty"` // Type - READ-ONLY; Resource type. Type *string `json:"type,omitempty"` // Location - Resource location. Location *string `json:"location,omitempty"` // Tags - Resource tags. Tags map[string]*string `json:"tags"` }
func (r Resource) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for Resource.
ResourceReference represents a single Azure resource and its referencing DNS records.
type ResourceReference struct { // DNSResources - A list of dns Records DNSResources *[]SubResource `json:"dnsResources,omitempty"` // TargetResource - A reference to an azure resource from where the dns resource value is taken. TargetResource *SubResource `json:"targetResource,omitempty"` }
ResourceReferenceClient is the the DNS Management Client.
type ResourceReferenceClient struct { BaseClient }
func NewResourceReferenceClient(subscriptionID string) ResourceReferenceClient
NewResourceReferenceClient creates an instance of the ResourceReferenceClient client.
func NewResourceReferenceClientWithBaseURI(baseURI string, subscriptionID string) ResourceReferenceClient
NewResourceReferenceClientWithBaseURI creates an instance of the ResourceReferenceClient client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
func (client ResourceReferenceClient) GetByTargetResources(ctx context.Context, parameters ResourceReferenceRequest) (result ResourceReferenceResult, err error)
GetByTargetResources returns the DNS records specified by the referencing targetResourceIds. Parameters: parameters - properties for dns resource reference request.
func (client ResourceReferenceClient) GetByTargetResourcesPreparer(ctx context.Context, parameters ResourceReferenceRequest) (*http.Request, error)
GetByTargetResourcesPreparer prepares the GetByTargetResources request.
func (client ResourceReferenceClient) GetByTargetResourcesResponder(resp *http.Response) (result ResourceReferenceResult, err error)
GetByTargetResourcesResponder handles the response to the GetByTargetResources request. The method always closes the http.Response Body.
func (client ResourceReferenceClient) GetByTargetResourcesSender(req *http.Request) (*http.Response, error)
GetByTargetResourcesSender sends the GetByTargetResources request. The method will close the http.Response Body if it receives an error.
ResourceReferenceRequest represents the properties of the Dns Resource Reference Request.
type ResourceReferenceRequest struct { // ResourceReferenceRequestProperties - The properties of the Resource Reference Request. *ResourceReferenceRequestProperties `json:"properties,omitempty"` }
func (rrr ResourceReferenceRequest) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for ResourceReferenceRequest.
func (rrr *ResourceReferenceRequest) UnmarshalJSON(body []byte) error
UnmarshalJSON is the custom unmarshaler for ResourceReferenceRequest struct.
ResourceReferenceRequestProperties represents the properties of the Dns Resource Reference Request.
type ResourceReferenceRequestProperties struct { // TargetResources - A list of references to azure resources for which referencing dns records need to be queried. TargetResources *[]SubResource `json:"targetResources,omitempty"` }
ResourceReferenceResult represents the properties of the Dns Resource Reference Result.
type ResourceReferenceResult struct { autorest.Response `json:"-"` // ResourceReferenceResultProperties - The result of dns resource reference request. Returns a list of dns resource references for each of the azure resource in the request. *ResourceReferenceResultProperties `json:"properties,omitempty"` }
func (rrr ResourceReferenceResult) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for ResourceReferenceResult.
func (rrr *ResourceReferenceResult) UnmarshalJSON(body []byte) error
UnmarshalJSON is the custom unmarshaler for ResourceReferenceResult struct.
ResourceReferenceResultProperties the result of dns resource reference request. Returns a list of dns resource references for each of the azure resource in the request.
type ResourceReferenceResultProperties struct { // DNSResourceReferences - The result of dns resource reference request. A list of dns resource references for each of the azure resource in the request DNSResourceReferences *[]ResourceReference `json:"dnsResourceReferences,omitempty"` }
SoaRecord an SOA record.
type SoaRecord struct { // Host - The domain name of the authoritative name server for this SOA record. Host *string `json:"host,omitempty"` // Email - The email contact for this SOA record. Email *string `json:"email,omitempty"` // SerialNumber - The serial number for this SOA record. SerialNumber *int64 `json:"serialNumber,omitempty"` // RefreshTime - The refresh value for this SOA record. RefreshTime *int64 `json:"refreshTime,omitempty"` // RetryTime - The retry time for this SOA record. RetryTime *int64 `json:"retryTime,omitempty"` // ExpireTime - The expire time for this SOA record. ExpireTime *int64 `json:"expireTime,omitempty"` // MinimumTTL - The minimum value for this SOA record. By convention this is used to determine the negative caching duration. MinimumTTL *int64 `json:"minimumTTL,omitempty"` }
SrvRecord an SRV record.
type SrvRecord struct { // Priority - The priority value for this SRV record. Priority *int32 `json:"priority,omitempty"` // Weight - The weight value for this SRV record. Weight *int32 `json:"weight,omitempty"` // Port - The port value for this SRV record. Port *int32 `json:"port,omitempty"` // Target - The target domain name for this SRV record. Target *string `json:"target,omitempty"` }
SubResource a reference to a another resource
type SubResource struct { // ID - Resource Id. ID *string `json:"id,omitempty"` }
TxtRecord a TXT record.
type TxtRecord struct { // Value - The text value of this TXT record. Value *[]string `json:"value,omitempty"` }
Zone describes a DNS zone.
type Zone struct { autorest.Response `json:"-"` // Etag - The etag of the zone. Etag *string `json:"etag,omitempty"` // ZoneProperties - The properties of the zone. *ZoneProperties `json:"properties,omitempty"` // ID - READ-ONLY; Resource ID. ID *string `json:"id,omitempty"` // Name - READ-ONLY; Resource name. Name *string `json:"name,omitempty"` // Type - READ-ONLY; Resource type. Type *string `json:"type,omitempty"` // Location - Resource location. Location *string `json:"location,omitempty"` // Tags - Resource tags. Tags map[string]*string `json:"tags"` }
func (z Zone) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for Zone.
func (z *Zone) UnmarshalJSON(body []byte) error
UnmarshalJSON is the custom unmarshaler for Zone struct.
ZoneListResult the response to a Zone List or ListAll operation.
type ZoneListResult struct { autorest.Response `json:"-"` // Value - Information about the DNS zones. Value *[]Zone `json:"value,omitempty"` // NextLink - READ-ONLY; The continuation token for the next page of results. NextLink *string `json:"nextLink,omitempty"` }
func (zlr ZoneListResult) IsEmpty() bool
IsEmpty returns true if the ListResult contains no values.
func (zlr ZoneListResult) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for ZoneListResult.
ZoneListResultIterator provides access to a complete listing of Zone values.
type ZoneListResultIterator struct {
// contains filtered or unexported fields
}
func NewZoneListResultIterator(page ZoneListResultPage) ZoneListResultIterator
Creates a new instance of the ZoneListResultIterator type.
func (iter *ZoneListResultIterator) Next() error
Next advances to the next value. If there was an error making the request the iterator does not advance and the error is returned. Deprecated: Use NextWithContext() instead.
func (iter *ZoneListResultIterator) NextWithContext(ctx context.Context) (err error)
NextWithContext advances to the next value. If there was an error making the request the iterator does not advance and the error is returned.
func (iter ZoneListResultIterator) NotDone() bool
NotDone returns true if the enumeration should be started or is not yet complete.
func (iter ZoneListResultIterator) Response() ZoneListResult
Response returns the raw server response from the last page request.
func (iter ZoneListResultIterator) Value() Zone
Value returns the current value or a zero-initialized value if the iterator has advanced beyond the end of the collection.
ZoneListResultPage contains a page of Zone values.
type ZoneListResultPage struct {
// contains filtered or unexported fields
}
func NewZoneListResultPage(cur ZoneListResult, getNextPage func(context.Context, ZoneListResult) (ZoneListResult, error)) ZoneListResultPage
Creates a new instance of the ZoneListResultPage type.
func (page *ZoneListResultPage) Next() error
Next advances to the next page of values. If there was an error making the request the page does not advance and the error is returned. Deprecated: Use NextWithContext() instead.
func (page *ZoneListResultPage) NextWithContext(ctx context.Context) (err error)
NextWithContext advances to the next page of values. If there was an error making the request the page does not advance and the error is returned.
func (page ZoneListResultPage) NotDone() bool
NotDone returns true if the page enumeration should be started or is not yet complete.
func (page ZoneListResultPage) Response() ZoneListResult
Response returns the raw server response from the last page request.
func (page ZoneListResultPage) Values() []Zone
Values returns the slice of values for the current page or nil if there are no values.
ZoneProperties represents the properties of the zone.
type ZoneProperties struct { // MaxNumberOfRecordSets - READ-ONLY; The maximum number of record sets that can be created in this DNS zone. This is a read-only property and any attempt to set this value will be ignored. MaxNumberOfRecordSets *int64 `json:"maxNumberOfRecordSets,omitempty"` // MaxNumberOfRecordsPerRecordSet - READ-ONLY; The maximum number of records per record set that can be created in this DNS zone. This is a read-only property and any attempt to set this value will be ignored. MaxNumberOfRecordsPerRecordSet *int64 `json:"maxNumberOfRecordsPerRecordSet,omitempty"` // NumberOfRecordSets - READ-ONLY; The current number of record sets in this DNS zone. This is a read-only property and any attempt to set this value will be ignored. NumberOfRecordSets *int64 `json:"numberOfRecordSets,omitempty"` // NameServers - READ-ONLY; The name servers for this DNS zone. This is a read-only property and any attempt to set this value will be ignored. NameServers *[]string `json:"nameServers,omitempty"` // ZoneType - The type of this DNS zone (Public or Private). Possible values include: 'Public', 'Private' ZoneType ZoneType `json:"zoneType,omitempty"` // RegistrationVirtualNetworks - A list of references to virtual networks that register hostnames in this DNS zone. This is a only when ZoneType is Private. RegistrationVirtualNetworks *[]SubResource `json:"registrationVirtualNetworks,omitempty"` // ResolutionVirtualNetworks - A list of references to virtual networks that resolve records in this DNS zone. This is a only when ZoneType is Private. ResolutionVirtualNetworks *[]SubResource `json:"resolutionVirtualNetworks,omitempty"` }
func (zp ZoneProperties) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for ZoneProperties.
ZoneType enumerates the values for zone type.
type ZoneType string
const ( // Private ... Private ZoneType = "Private" // Public ... Public ZoneType = "Public" )
func PossibleZoneTypeValues() []ZoneType
PossibleZoneTypeValues returns an array of possible values for the ZoneType const type.
ZoneUpdate describes a request to update a DNS zone.
type ZoneUpdate struct { // Tags - Resource tags. Tags map[string]*string `json:"tags"` }
func (zu ZoneUpdate) MarshalJSON() ([]byte, error)
MarshalJSON is the custom marshaler for ZoneUpdate.
ZonesClient is the the DNS Management Client.
type ZonesClient struct { BaseClient }
func NewZonesClient(subscriptionID string) ZonesClient
NewZonesClient creates an instance of the ZonesClient client.
func NewZonesClientWithBaseURI(baseURI string, subscriptionID string) ZonesClient
NewZonesClientWithBaseURI creates an instance of the ZonesClient client using a custom endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
func (client ZonesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, zoneName string, parameters Zone, ifMatch string, ifNoneMatch string) (result Zone, err error)
CreateOrUpdate creates or updates a DNS zone. Does not modify DNS records within the zone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). parameters - parameters supplied to the CreateOrUpdate operation. ifMatch - the etag of the DNS zone. Omit this value to always overwrite the current zone. Specify the last-seen etag value to prevent accidentally overwriting any concurrent changes. ifNoneMatch - set to '*' to allow a new DNS zone to be created, but to prevent updating an existing zone. Other values will be ignored.
func (client ZonesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, zoneName string, parameters Zone, ifMatch string, ifNoneMatch string) (*http.Request, error)
CreateOrUpdatePreparer prepares the CreateOrUpdate request.
func (client ZonesClient) CreateOrUpdateResponder(resp *http.Response) (result Zone, err error)
CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always closes the http.Response Body.
func (client ZonesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error)
CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the http.Response Body if it receives an error.
func (client ZonesClient) Delete(ctx context.Context, resourceGroupName string, zoneName string, ifMatch string) (result ZonesDeleteFuture, err error)
Delete deletes a DNS zone. WARNING: All DNS records in the zone will also be deleted. This operation cannot be undone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). ifMatch - the etag of the DNS zone. Omit this value to always delete the current zone. Specify the last-seen etag value to prevent accidentally deleting any concurrent changes.
func (client ZonesClient) DeletePreparer(ctx context.Context, resourceGroupName string, zoneName string, ifMatch string) (*http.Request, error)
DeletePreparer prepares the Delete request.
func (client ZonesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error)
DeleteResponder handles the response to the Delete request. The method always closes the http.Response Body.
func (client ZonesClient) DeleteSender(req *http.Request) (future ZonesDeleteFuture, err error)
DeleteSender sends the Delete request. The method will close the http.Response Body if it receives an error.
func (client ZonesClient) Get(ctx context.Context, resourceGroupName string, zoneName string) (result Zone, err error)
Get gets a DNS zone. Retrieves the zone properties, but not the record sets within the zone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot).
func (client ZonesClient) GetPreparer(ctx context.Context, resourceGroupName string, zoneName string) (*http.Request, error)
GetPreparer prepares the Get request.
func (client ZonesClient) GetResponder(resp *http.Response) (result Zone, err error)
GetResponder handles the response to the Get request. The method always closes the http.Response Body.
func (client ZonesClient) GetSender(req *http.Request) (*http.Response, error)
GetSender sends the Get request. The method will close the http.Response Body if it receives an error.
func (client ZonesClient) List(ctx context.Context, top *int32) (result ZoneListResultPage, err error)
List lists the DNS zones in all resource groups in a subscription. Parameters: top - the maximum number of DNS zones to return. If not specified, returns up to 100 zones.
func (client ZonesClient) ListByResourceGroup(ctx context.Context, resourceGroupName string, top *int32) (result ZoneListResultPage, err error)
ListByResourceGroup lists the DNS zones within a resource group. Parameters: resourceGroupName - the name of the resource group. top - the maximum number of record sets to return. If not specified, returns up to 100 record sets.
func (client ZonesClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string, top *int32) (result ZoneListResultIterator, err error)
ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
func (client ZonesClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string, top *int32) (*http.Request, error)
ListByResourceGroupPreparer prepares the ListByResourceGroup request.
func (client ZonesClient) ListByResourceGroupResponder(resp *http.Response) (result ZoneListResult, err error)
ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always closes the http.Response Body.
func (client ZonesClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error)
ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the http.Response Body if it receives an error.
func (client ZonesClient) ListComplete(ctx context.Context, top *int32) (result ZoneListResultIterator, err error)
ListComplete enumerates all values, automatically crossing page boundaries as required.
func (client ZonesClient) ListPreparer(ctx context.Context, top *int32) (*http.Request, error)
ListPreparer prepares the List request.
func (client ZonesClient) ListResponder(resp *http.Response) (result ZoneListResult, err error)
ListResponder handles the response to the List request. The method always closes the http.Response Body.
func (client ZonesClient) ListSender(req *http.Request) (*http.Response, error)
ListSender sends the List request. The method will close the http.Response Body if it receives an error.
func (client ZonesClient) Update(ctx context.Context, resourceGroupName string, zoneName string, parameters ZoneUpdate, ifMatch string) (result Zone, err error)
Update updates a DNS zone. Does not modify DNS records within the zone. Parameters: resourceGroupName - the name of the resource group. zoneName - the name of the DNS zone (without a terminating dot). parameters - parameters supplied to the Update operation. ifMatch - the etag of the DNS zone. Omit this value to always overwrite the current zone. Specify the last-seen etag value to prevent accidentally overwriting any concurrent changes.
func (client ZonesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, zoneName string, parameters ZoneUpdate, ifMatch string) (*http.Request, error)
UpdatePreparer prepares the Update request.
func (client ZonesClient) UpdateResponder(resp *http.Response) (result Zone, err error)
UpdateResponder handles the response to the Update request. The method always closes the http.Response Body.
func (client ZonesClient) UpdateSender(req *http.Request) (*http.Response, error)
UpdateSender sends the Update request. The method will close the http.Response Body if it receives an error.
ZonesDeleteFuture an abstraction for monitoring and retrieving the results of a long-running operation.
type ZonesDeleteFuture struct { azure.FutureAPI // Result returns the result of the asynchronous operation. // If the operation has not completed it will return an error. Result func(ZonesClient) (autorest.Response, error) }
func (future *ZonesDeleteFuture) UnmarshalJSON(body []byte) error
UnmarshalJSON is the custom unmarshaller for CreateFuture.