pub struct CompileContext<'a> {
pub schema_set: &'a SchemaSet,
pub target_namespace: Option<NameId>,
/* private fields */
}Expand description
Context for NFA compilation
Provides access to the schema set for resolving references during compilation.
Fields§
§schema_set: &'a SchemaSetReference to the schema set for resolving references
target_namespace: Option<NameId>Target namespace for the content model being compiled
Implementations§
Source§impl<'a> CompileContext<'a>
impl<'a> CompileContext<'a>
Sourcepub fn new(schema_set: &'a SchemaSet, target_namespace: Option<NameId>) -> Self
pub fn new(schema_set: &'a SchemaSet, target_namespace: Option<NameId>) -> Self
Create a new compilation context
Sourcepub fn new_for_upa(
schema_set: &'a SchemaSet,
target_namespace: Option<NameId>,
) -> Self
pub fn new_for_upa( schema_set: &'a SchemaSet, target_namespace: Option<NameId>, ) -> Self
Create a compilation context with UPA occurrence-bound capping enabled.
Sourcepub fn compile_particle(
&mut self,
particle: &ParticleResult,
) -> NfaCompileResult<NfaTable>
pub fn compile_particle( &mut self, particle: &ParticleResult, ) -> NfaCompileResult<NfaTable>
Compile a particle to an NFA table
This is the main entry point for compiling a content model particle.
Sourcepub fn compile_model_group(
&mut self,
group: &ModelGroupDefResult,
) -> NfaCompileResult<NfaTable>
pub fn compile_model_group( &mut self, group: &ModelGroupDefResult, ) -> NfaCompileResult<NfaTable>
Compile a model group to an NFA table
Used for compiling named groups (xs:group).
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for CompileContext<'a>
impl<'a> !Send for CompileContext<'a>
impl<'a> !Sync for CompileContext<'a>
impl<'a> !UnwindSafe for CompileContext<'a>
impl<'a> Freeze for CompileContext<'a>
impl<'a> Unpin for CompileContext<'a>
impl<'a> UnsafeUnpin for CompileContext<'a>
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