pub enum DNSRecordKind {
A,
AAAA,
TXT,
CNAME,
MX,
NS,
SRV,
CAA,
}Expand description
DNS record kind (type) enumeration.
Represents the Kubernetes kind field for all DNS record custom resources.
This enum eliminates magic strings when matching record types and provides
type-safe conversions between string representations and enum values.
§Example
ⓘ
use bindy::crd::DNSRecordKind;
// Parse from string
let kind = DNSRecordKind::from("ARecord");
assert_eq!(kind, DNSRecordKind::A);
// Convert to string
assert_eq!(kind.as_str(), "ARecord");Variants§
A
IPv4 address record (A)
AAAA
IPv6 address record (AAAA)
TXT
Text record (TXT)
CNAME
Canonical name record (CNAME)
MX
Mail exchange record (MX)
NS
Nameserver record (NS)
SRV
Service record (SRV)
CAA
Certificate authority authorization record (CAA)
Implementations§
Source§impl DNSRecordKind
impl DNSRecordKind
Sourcepub const fn to_hickory_record_type(self) -> RecordType
pub const fn to_hickory_record_type(self) -> RecordType
Converts this DNS record kind to a Hickory DNS RecordType.
This is useful when interfacing with the Hickory DNS library for zone file generation or DNS protocol operations.
§Example
ⓘ
use bindy::crd::DNSRecordKind;
use hickory_client::rr::RecordType;
let kind = DNSRecordKind::A;
let record_type = kind.to_hickory_record_type();
assert_eq!(record_type, RecordType::A);Trait Implementations§
Source§impl Clone for DNSRecordKind
impl Clone for DNSRecordKind
Source§fn clone(&self) -> DNSRecordKind
fn clone(&self) -> DNSRecordKind
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DNSRecordKind
impl Debug for DNSRecordKind
Source§impl Display for DNSRecordKind
impl Display for DNSRecordKind
Source§impl From<&str> for DNSRecordKind
impl From<&str> for DNSRecordKind
Source§impl From<String> for DNSRecordKind
impl From<String> for DNSRecordKind
Source§impl Hash for DNSRecordKind
impl Hash for DNSRecordKind
Source§impl PartialEq for DNSRecordKind
impl PartialEq for DNSRecordKind
impl Copy for DNSRecordKind
impl Eq for DNSRecordKind
impl StructuralPartialEq for DNSRecordKind
Auto Trait Implementations§
impl Freeze for DNSRecordKind
impl RefUnwindSafe for DNSRecordKind
impl Send for DNSRecordKind
impl Sync for DNSRecordKind
impl Unpin for DNSRecordKind
impl UnwindSafe for DNSRecordKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Applies the layer to a service and wraps it in [
Layered].§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> ServiceExt for T
impl<T> ServiceExt for T
§fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
Apply a transformation to the response body. Read more
§fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using HTTP status codes. Read more
§fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using gRPC headers. Read more
§fn follow_redirects(self) -> FollowRedirect<Self>where
Self: Sized,
fn follow_redirects(self) -> FollowRedirect<Self>where
Self: Sized,
§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.