Struct rtlola_frontend::ParserConfig
source · [−]pub struct ParserConfig { /* private fields */ }
Expand description
The configuration of the parser.
Implementations
sourceimpl ParserConfig
impl ParserConfig
sourcepub fn from_path(path_to_spec: PathBuf) -> Result<ParserConfig, Error>
pub fn from_path(path_to_spec: PathBuf) -> Result<ParserConfig, Error>
Reads the specification from the given path and creates a new parser configuration for it.
sourcepub fn for_string(spec: String) -> ParserConfig
pub fn for_string(spec: String) -> ParserConfig
Creates a new parser configuration for the given specification.
sourcepub fn for_named_spec(name: String, spec: String) -> ParserConfig
pub fn for_named_spec(name: String, spec: String) -> ParserConfig
Creates a new parser configuration for the given specification using the name as file name.
sourcepub fn parse(self) -> Result<RtLolaAst, RtLolaError>
pub fn parse(self) -> Result<RtLolaAst, RtLolaError>
Invokes the parser on the specification given in the configuration.
Trait Implementations
sourceimpl Clone for ParserConfig
impl Clone for ParserConfig
sourcefn clone(&self) -> ParserConfig
fn clone(&self) -> ParserConfig
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for ParserConfig
impl Debug for ParserConfig
sourceimpl From<ParserConfig> for Handler
impl From<ParserConfig> for Handler
sourcefn from(cfg: ParserConfig) -> Handler
fn from(cfg: ParserConfig) -> Handler
Converts to this type from the input type.
Auto Trait Implementations
impl RefUnwindSafe for ParserConfig
impl Send for ParserConfig
impl Sync for ParserConfig
impl Unpin for ParserConfig
impl UnwindSafe for ParserConfig
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more