Struct polar_core::kb::KnowledgeBase[][src]

pub struct KnowledgeBase {
    pub sources: Sources,
    pub inline_queries: Vec<Term>,
    pub resource_blocks: ResourceBlocks,
    // some fields omitted
}

Fields

sources: Sourcesinline_queries: Vec<Term>resource_blocks: ResourceBlocks

Resource block bookkeeping.

Implementations

Return a monotonically increasing integer ID.

Wraps around at 52 bits of precision so that it can be safely coerced to an IEEE-754 double-float (f64).

Generate a temporary variable prefix from a variable name.

Generate a new symbol.

Define a constant variable.

Error on attempts to register the “union” types (Actor & Resource) since those types have special meaning in policies that use resource blocks.

Return true if a constant with the given name has been defined.

Getter for constants map without exposing it for mutation.

Add the Method Resolution Order (MRO) list for a registered class. The mro argument is a list of the instance_id associated with a registered class.

Trait Implementations

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.