Interface DnsRpc (2.20.0)

public interface DnsRpc extends ServiceRpc

Implements

com.google.cloud.ServiceRpc

Methods

applyChangeRequest(String zoneName, Change changeRequest, Map<DnsRpc.Option,?> options)

public abstract Change applyChangeRequest(String zoneName, Change changeRequest, Map<DnsRpc.Option,?> options)

Applies change request to a zone.

Parameters
NameDescription
zoneNameString

the name of a zone to which the Change should be applied

changeRequestcom.google.api.services.dns.model.Change

change to be applied

optionsMap<Option,?>

a map of options for the service call

Returns
TypeDescription
com.google.api.services.dns.model.Change

updated change object with server-assigned ID

Exceptions
TypeDescription
DnsException

upon failure or if zone was not found

create(ManagedZone zone, Map<DnsRpc.Option,?> options)

public abstract ManagedZone create(ManagedZone zone, Map<DnsRpc.Option,?> options)

Creates a new zone.

Parameters
NameDescription
zonecom.google.api.services.dns.model.ManagedZone

a zone to be created

optionsMap<Option,?>

a map of options for the service call

Returns
TypeDescription
com.google.api.services.dns.model.ManagedZone

Updated ManagedZone object

Exceptions
TypeDescription
DnsException

upon failure

createBatch()

public abstract RpcBatch createBatch()

Creates an empty batch.

Returns
TypeDescription
RpcBatch

deleteZone(String zoneName)

public abstract boolean deleteZone(String zoneName)

Deletes the zone identified by the name.

Parameter
NameDescription
zoneNameString
Returns
TypeDescription
boolean

true if the zone was deleted and false otherwise

Exceptions
TypeDescription
DnsException

upon failure

getChangeRequest(String zoneName, String changeRequestId, Map<DnsRpc.Option,?> options)

public abstract Change getChangeRequest(String zoneName, String changeRequestId, Map<DnsRpc.Option,?> options)

Returns an existing change request.

Parameters
NameDescription
zoneNameString

the name of a zone to which the Change was be applied

changeRequestIdString

the unique id assigned to the change by the server

optionsMap<Option,?>

a map of options for the service call

Returns
TypeDescription
com.google.api.services.dns.model.Change

up-to-date change object or null if change was not found

Exceptions
TypeDescription
DnsException

upon failure or if zone was not found

getProject(Map<DnsRpc.Option,?> options)

public abstract Project getProject(Map<DnsRpc.Option,?> options)

Returns information about the current project.

Parameter
NameDescription
optionsMap<Option,?>

a map of options for the service call

Returns
TypeDescription
com.google.api.services.dns.model.Project

up-to-date project information

Exceptions
TypeDescription
DnsException

upon failure or if the project is not found

getZone(String zoneName, Map<DnsRpc.Option,?> options)

public abstract ManagedZone getZone(String zoneName, Map<DnsRpc.Option,?> options)

Retrieves and returns an existing zone.

Parameters
NameDescription
zoneNameString

name of the zone to be returned

optionsMap<Option,?>

a map of options for the service call

Returns
TypeDescription
com.google.api.services.dns.model.ManagedZone

a zone or null if not found

Exceptions
TypeDescription
DnsException

upon failure

listChangeRequests(String zoneName, Map<DnsRpc.Option,?> options)

public abstract DnsRpc.ListResult<Change> listChangeRequests(String zoneName, Map<DnsRpc.Option,?> options)

List existing change requests for a zone.

Parameters
NameDescription
zoneNameString

the name of a zone to which the Changes were be applied

optionsMap<Option,?>

a map of options for the service call

Returns
TypeDescription
ListResult<com.google.api.services.dns.model.Change>
Exceptions
TypeDescription
DnsException

upon failure or if zone was not found

listRecordSets(String zoneName, Map<DnsRpc.Option,?> options)

public abstract DnsRpc.ListResult<ResourceRecordSet> listRecordSets(String zoneName, Map<DnsRpc.Option,?> options)

Lists record sets for a given zone.

Parameters
NameDescription
zoneNameString

name of the zone to be listed

optionsMap<Option,?>

a map of options for the service call

Returns
TypeDescription
ListResult<com.google.api.services.dns.model.ResourceRecordSet>
Exceptions
TypeDescription
DnsException

upon failure or if zone was not found

listZones(Map<DnsRpc.Option,?> options)

public abstract DnsRpc.ListResult<ManagedZone> listZones(Map<DnsRpc.Option,?> options)

Lists the zones that exist within the project.

Parameter
NameDescription
optionsMap<Option,?>

a map of options for the service call

Returns
TypeDescription
ListResult<com.google.api.services.dns.model.ManagedZone>
Exceptions
TypeDescription
DnsException

upon failure