Struct attck::Ref[][src]

pub struct Ref<'id, 'collection: 'id, D> { /* fields omitted */ }

An ID for a resource that may be in the backing collection.

Ref is used to allow exploration of STIX collections when not every object referenced is present in-memory.

Implementations

impl<'id, 'collection: 'id, D> Ref<'id, 'collection, D>[src]

pub fn id(&self) -> &'id Id[src]

The ID the Ref will look up in the collection.

impl<'id, 'collection: 'id> Ref<'id, 'collection, Declaration>[src]

The ID of a STIX object of some type which may be present in the collection.

pub fn downcast<D: TypedObject>(self) -> Option<Ref<'id, 'collection, D>>[src]

Narrow the type of the reference so that it can be resolved to a Node. This requires knowing the concrete type of the data associated with the ID.

impl<'id, 'collection: 'id> Ref<'id, 'collection, AttackPattern>[src]

pub fn resolve(self) -> Option<Node<'collection, AttackPattern>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, CourseOfAction>[src]

pub fn resolve(self) -> Option<Node<'collection, CourseOfAction>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Malware>[src]

pub fn resolve(self) -> Option<Node<'collection, Malware>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Matrix>[src]

pub fn resolve(self) -> Option<Node<'collection, Matrix>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Tactic>[src]

pub fn resolve(self) -> Option<Node<'collection, Tactic>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Tool>[src]

pub fn resolve(self) -> Option<Node<'collection, Tool>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Campaign>[src]

pub fn resolve(self) -> Option<Node<'collection, Campaign>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Identity>[src]

pub fn resolve(self) -> Option<Node<'collection, Identity>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, IntrusionSet>[src]

pub fn resolve(self) -> Option<Node<'collection, IntrusionSet>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Infrastructure>[src]

pub fn resolve(self) -> Option<Node<'collection, Infrastructure>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Location>[src]

pub fn resolve(self) -> Option<Node<'collection, Location>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, MarkingDefinition>[src]

pub fn resolve(self) -> Option<Node<'collection, MarkingDefinition>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Relationship>[src]

pub fn resolve(self) -> Option<Node<'collection, Relationship>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, ThreatActor>[src]

pub fn resolve(self) -> Option<Node<'collection, ThreatActor>>[src]

impl<'id, 'collection: 'id> Ref<'id, 'collection, Vulnerability>[src]

pub fn resolve(self) -> Option<Node<'collection, Vulnerability>>[src]

Trait Implementations

impl<'id, 'collection: 'id, D> Clone for Ref<'id, 'collection, D>[src]

impl<D> Display for Ref<'_, '_, D>[src]

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, AttackPattern>[src]

type Output = Node<'collection, AttackPattern>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, CourseOfAction>[src]

type Output = Node<'collection, CourseOfAction>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Location>[src]

type Output = Node<'collection, Location>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, MarkingDefinition>[src]

type Output = Node<'collection, MarkingDefinition>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Relationship>[src]

type Output = Node<'collection, Relationship>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, ThreatActor>[src]

type Output = Node<'collection, ThreatActor>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Vulnerability>[src]

type Output = Node<'collection, Vulnerability>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Malware>[src]

type Output = Node<'collection, Malware>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Matrix>[src]

type Output = Node<'collection, Matrix>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Tactic>[src]

type Output = Node<'collection, Tactic>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Tool>[src]

type Output = Node<'collection, Tool>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Campaign>[src]

type Output = Node<'collection, Campaign>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Identity>[src]

type Output = Node<'collection, Identity>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, IntrusionSet>[src]

type Output = Node<'collection, IntrusionSet>

The node type, containing a reference to the data and the backing collection.

impl<'id, 'collection: 'id> Resolve for Ref<'id, 'collection, Infrastructure>[src]

type Output = Node<'collection, Infrastructure>

The node type, containing a reference to the data and the backing collection.

Auto Trait Implementations

impl<'id, 'collection, D> RefUnwindSafe for Ref<'id, 'collection, D> where
    D: RefUnwindSafe

impl<'id, 'collection, D> Send for Ref<'id, 'collection, D> where
    D: Send

impl<'id, 'collection, D> Sync for Ref<'id, 'collection, D> where
    D: Sync

impl<'id, 'collection, D> Unpin for Ref<'id, 'collection, D> where
    D: Unpin

impl<'id, 'collection, D> UnwindSafe for Ref<'id, 'collection, D> where
    D: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.