Struct trust_dns::client::SyncClient
[−]
[src]
pub struct SyncClient { /* fields omitted */ }
The Client is abstracted over either trust_dns::tcp::TcpClientConnection or trust_dns::udp::UdpClientConnection.
Usage of TCP or UDP is up to the user. Some DNS servers disallow TCP in some cases, so if TCP double check if UDP works.
Methods
impl SyncClient
[src]
fn new<CC: ClientConnection>(client_connection: CC) -> SyncClient where
<CC as ClientConnection>::MessageStream: Stream<Item = Vec<u8>, Error = Error> + 'static,
[src]
<CC as ClientConnection>::MessageStream: Stream<Item = Vec<u8>, Error = Error> + 'static,
Creates a new DNS client with the specified connection type
Arguments
client_connection
- the client_connection to use for all communication
fn with_signer<CC: ClientConnection>(
client_connection: CC,
signer: Signer
) -> SyncClient where
<CC as ClientConnection>::MessageStream: Stream<Item = Vec<u8>, Error = Error> + 'static,
[src]
client_connection: CC,
signer: Signer
) -> SyncClient where
<CC as ClientConnection>::MessageStream: Stream<Item = Vec<u8>, Error = Error> + 'static,
Creates a new DNS client with the specified connection type and a SIG0 signer.
This is necessary for signed udpate requests to update trust-dns-server entries.
Arguments
client_connection
- the client_connection to use for all communicationsigner
- signer to use, this needs an associated private key
Trait Implementations
impl Client<BasicClientHandle> for SyncClient
[src]
fn get_io_loop(&self) -> RefMut<Core>
[src]
get a mutable reference to the tokio Core associated to the Client
fn get_client_handle(&self) -> RefMut<BasicClientHandle>
[src]
Get a mutable handle reference tot the Core assiated to the Client
fn query(
&self,
name: &Name,
query_class: DNSClass,
query_type: RecordType
) -> ClientResult<Message>
[src]
&self,
name: &Name,
query_class: DNSClass,
query_type: RecordType
) -> ClientResult<Message>
A classic DNS query, i.e. does not perform and DNSSec operations Read more
fn notify<R>(
&mut self,
name: Name,
query_class: DNSClass,
query_type: RecordType,
rrset: Option<R>
) -> ClientResult<Message> where
R: IntoRecordSet,
[src]
&mut self,
name: Name,
query_class: DNSClass,
query_type: RecordType,
rrset: Option<R>
) -> ClientResult<Message> where
R: IntoRecordSet,
Sends a NOTIFY message to the remote system Read more
fn create<R>(&self, rrset: R, zone_origin: Name) -> ClientResult<Message> where
R: IntoRecordSet,
[src]
R: IntoRecordSet,
Sends a record to create on the server, this will fail if the record exists (atomicity depends on the server) Read more
fn append<R>(
&self,
rrset: R,
zone_origin: Name,
must_exist: bool
) -> ClientResult<Message> where
R: IntoRecordSet,
[src]
&self,
rrset: R,
zone_origin: Name,
must_exist: bool
) -> ClientResult<Message> where
R: IntoRecordSet,
Appends a record to an existing rrset, optionally require the rrset to exis (atomicity depends on the server) Read more
fn compare_and_swap<CR, NR>(
&self,
current: CR,
new: NR,
zone_origin: Name
) -> ClientResult<Message> where
CR: IntoRecordSet,
NR: IntoRecordSet,
[src]
&self,
current: CR,
new: NR,
zone_origin: Name
) -> ClientResult<Message> where
CR: IntoRecordSet,
NR: IntoRecordSet,
Compares and if it matches, swaps it for the new value (atomicity depends on the server) Read more
fn delete_by_rdata<R>(
&self,
record: R,
zone_origin: Name
) -> ClientResult<Message> where
R: IntoRecordSet,
[src]
&self,
record: R,
zone_origin: Name
) -> ClientResult<Message> where
R: IntoRecordSet,
Deletes a record (by rdata) from an rrset, optionally require the rrset to exist. Read more
fn delete_rrset(
&self,
record: Record,
zone_origin: Name
) -> ClientResult<Message>
[src]
&self,
record: Record,
zone_origin: Name
) -> ClientResult<Message>
Deletes an entire rrset, optionally require the rrset to exist. Read more
fn delete_all(
&self,
name_of_records: Name,
zone_origin: Name,
dns_class: DNSClass
) -> ClientResult<Message>
[src]
&self,
name_of_records: Name,
zone_origin: Name,
dns_class: DNSClass
) -> ClientResult<Message>
Deletes all records at the specified name Read more