Struct wdl_analysis::DocumentScope
source · pub struct DocumentScope { /* private fields */ }Expand description
Represents the scope of a document.
Implementations§
source§impl DocumentScope
impl DocumentScope
sourcepub fn namespaces(&self) -> impl Iterator<Item = (&String, &Namespace)>
pub fn namespaces(&self) -> impl Iterator<Item = (&String, &Namespace)>
Gets the namespaces in the document scope.
sourcepub fn get_namespace(&self, name: &str) -> Option<&Namespace>
pub fn get_namespace(&self, name: &str) -> Option<&Namespace>
Gets a namespace in the document scope by name.
sourcepub fn task_scopes(&self) -> impl Iterator<Item = (&String, &Scope)>
pub fn task_scopes(&self) -> impl Iterator<Item = (&String, &Scope)>
Gets the task scopes in the document scope.
sourcepub fn get_task_scope(&self, name: &str) -> Option<&Scope>
pub fn get_task_scope(&self, name: &str) -> Option<&Scope>
Gets a task scope in the document scope by name.
sourcepub fn get_workflow_scope(&self) -> Option<&Scope>
pub fn get_workflow_scope(&self) -> Option<&Scope>
Gets the workflow scope in the document scope.
sourcepub fn structs(&self) -> impl Iterator<Item = (&String, &Struct)>
pub fn structs(&self) -> impl Iterator<Item = (&String, &Struct)>
Gets the structs in the document scope.
sourcepub fn get_struct(&self, name: &str) -> Option<&Struct>
pub fn get_struct(&self, name: &str) -> Option<&Struct>
Gets a struct in the document scope by name.
sourcepub fn find_scope_by_position(&self, position: usize) -> Option<&Scope>
pub fn find_scope_by_position(&self, position: usize) -> Option<&Scope>
Finds the deepest scope based on a position within the document.
Trait Implementations§
source§impl Debug for DocumentScope
impl Debug for DocumentScope
source§impl Default for DocumentScope
impl Default for DocumentScope
source§fn default() -> DocumentScope
fn default() -> DocumentScope
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for DocumentScope
impl RefUnwindSafe for DocumentScope
impl Send for DocumentScope
impl Sync for DocumentScope
impl Unpin for DocumentScope
impl UnwindSafe for DocumentScope
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more