Struct rune::Sources[][src]

pub struct Sources { /* fields omitted */ }

A collection of source files, and a queue of things to compile.

Implementations

impl Sources[src]

pub fn new() -> Self[src]

Construct a new collection of sources.

pub fn source_at(&self, source_id: SourceId) -> Option<&Arc<Source>>[src]

Get the source at the given source id.

pub fn insert_default(&mut self, source: Source) -> SourceId[src]

👎 Deprecated:

use insert instead

Insert a source to be built and return its id.

pub fn insert(&mut self, source: Source) -> SourceId[src]

Insert a source to be built and return its id.

pub fn get(&self, source_id: usize) -> Option<&Arc<Source>>[src]

Get the source matching the given source id.

Trait Implementations

impl Debug for Sources[src]

impl Default for Sources[src]

Auto Trait Implementations

impl RefUnwindSafe for Sources

impl Send for Sources

impl Sync for Sources

impl Unpin for Sources

impl UnwindSafe for Sources

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, 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.