[−][src]Struct rpki::resources::IpResources
The IP Address Resources of an RPKI Certificate.
This type contains the resources for one of the address families that can be contained in the certificate.
Methods
impl IpResources
[src]
pub fn inherit() -> Self
[src]
Creates a new IpResources with a ResourcesChoice::Inherit
pub fn blocks(blocks: IpBlocks) -> Self
[src]
Creates a new IpResources for the given blocks.
pub fn is_inherited(&self) -> bool
[src]
Returns whether the resources are of the inherited variant.
pub fn as_blocks(&self) -> Option<&IpBlocks>
[src]
Returns a reference to the blocks if there are any.
pub fn to_blocks(&self) -> Result<IpBlocks, ValidationError>
[src]
Converts the resources into blocks or returns an error.
impl IpResources
[src]
pub fn take_families_from<S: Source>(
cons: &mut Constructed<S>
) -> Result<(Option<Self>, Option<Self>), S::Err>
[src]
cons: &mut Constructed<S>
) -> Result<(Option<Self>, Option<Self>), S::Err>
Takes all IP resources from the beginning of a constructed value.
On success, the function returns a pair of optional IP resources, the first for IPv4, the second for IPv6.
pub fn take_from<S: Source>(cons: &mut Constructed<S>) -> Result<Self, S::Err>
[src]
Takes a single set of IP resources from a constructed value.
pub fn encode_families(
v4: Option<Self>,
v6: Option<Self>
) -> Option<impl Values>
[src]
v4: Option<Self>,
v6: Option<Self>
) -> Option<impl Values>
pub fn encode(self) -> impl Values
[src]
pub fn encode_ref<'a>(&'a self) -> impl Values + 'a
[src]
Trait Implementations
impl Clone for IpResources
[src]
fn clone(&self) -> IpResources
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Eq for IpResources
[src]
impl PartialEq<IpResources> for IpResources
[src]
fn eq(&self, other: &IpResources) -> bool
[src]
fn ne(&self, other: &IpResources) -> bool
[src]
impl Debug for IpResources
[src]
Auto Trait Implementations
impl Send for IpResources
impl Sync for IpResources
impl Unpin for IpResources
impl UnwindSafe for IpResources
impl RefUnwindSafe for IpResources
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,