pub struct File {
pub type: Option<String>,
pub name: Option<String>,
pub package: Option<PackageClause>,
pub imports: Vec<ImportDeclaration>,
pub body: Vec<Statement>,
}
Expand description
Represents a source from a single file
Fields
type: Option<String>
Type of AST node
name: Option<String>
The name of the file.
package: Option<PackageClause>
PackageClause
imports: Vec<ImportDeclaration>
A list of package imports
body: Vec<Statement>
List of Flux statements
Implementations
Trait Implementations
sourceimpl<'de> Deserialize<'de> for File
impl<'de> Deserialize<'de> for File
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for File
Auto Trait Implementations
impl RefUnwindSafe for File
impl Send for File
impl Sync for File
impl Unpin for File
impl UnwindSafe for File
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> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more