pub struct Spec {
pub bytecode: MultiEntityBytecode,
pub program_ids: Vec<String>,
pub parser_setup: Option<ParserSetupFn>,
pub program_runtime_definitions: Vec<ProgramRuntimeDefinition>,
pub entity_specs: Vec<SerializableStreamSpec>,
pub views: Vec<ViewDef>,
}Expand description
Specification for a Arete server Contains bytecode, parsers, and program information
Fields§
§bytecode: MultiEntityBytecode§program_ids: Vec<String>§parser_setup: Option<ParserSetupFn>§program_runtime_definitions: Vec<ProgramRuntimeDefinition>§entity_specs: Vec<SerializableStreamSpec>§views: Vec<ViewDef>Implementations§
Source§impl Spec
impl Spec
pub fn new(bytecode: MultiEntityBytecode, program_id: impl Into<String>) -> Self
pub fn with_parser_setup(self, setup_fn: ParserSetupFn) -> Self
pub fn with_program_runtime_definitions( self, definitions: Vec<ProgramRuntimeDefinition>, ) -> Self
pub fn with_entity_specs( self, entity_specs: Vec<SerializableStreamSpec>, ) -> Self
pub fn with_views(self, views: Vec<ViewDef>) -> Self
Auto Trait Implementations§
impl !RefUnwindSafe for Spec
impl !UnwindSafe for Spec
impl Forget for Spec
impl Freeze for Specwhere
*const u8 is !null: Freeze,
PhantomData<(String, EntityBytecode)>: Freeze,
PhantomData<(String, Vec<String>)>: Freeze,
PhantomData<(String, ())>: Freeze,
PhantomData<(String, fn(&[u8]) -> Result<(Value, String), Box<dyn Error>>)>: Freeze,
PhantomData<String>: Freeze,
*const ArcInner<dyn Fn(Sender<MutationBatch>, Option<HealthMonitor>, ReconnectionConfig) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>> + Sync + Send> is !null: Freeze,
PhantomData<ArcInner<dyn Fn(Sender<MutationBatch>, Option<HealthMonitor>, ReconnectionConfig) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>> + Sync + Send>>: Freeze,
PhantomData<ProgramRuntimeDefinition>: Freeze,
PhantomData<SerializableStreamSpec>: Freeze,
PhantomData<ViewDef>: Freeze,
impl Move for Spec
impl Send for Specwhere
RawTable<(String, EntityBytecode)>: Send,
RawTable<(String, Vec<String>)>: Send,
RawTable<(String, ())>: Send,
RawTable<(String, fn(&[u8]) -> Result<(Value, String), Box<dyn Error>>)>: Send,
RawVecInner: Send,
Arc<dyn Fn(Sender<MutationBatch>, Option<HealthMonitor>, ReconnectionConfig) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>> + Sync + Send>: Send,
Arc<dyn Fn(&str, &[u8]) -> Result<Value, Error> + Sync + Send>: Send,
BoxRaw<IdlTypeSnapshot>: Send,
NodeRef<Owned, String, Value, LeafOrInternal>: Send,
BoxRaw<(String, Value)>: Send,
BoxRaw<MappingSource>: Send,
NodeRef<Owned, String, Transformation, LeafOrInternal>: Send,
BoxRaw<(String, Transformation)>: Send,
BoxRaw<ComputedExpr>: Send,
NodeRef<Owned, String, FieldTypeInfo, LeafOrInternal>: Send,
BoxRaw<(String, FieldTypeInfo)>: Send,
BoxRaw<Predicate>: Send,
impl Sync for Specwhere
RawTable<(String, EntityBytecode)>: Sync,
RawTable<(String, Vec<String>)>: Sync,
RawTable<(String, ())>: Sync,
RawTable<(String, fn(&[u8]) -> Result<(Value, String), Box<dyn Error>>)>: Sync,
RawVecInner: Sync,
Arc<dyn Fn(Sender<MutationBatch>, Option<HealthMonitor>, ReconnectionConfig) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>> + Sync + Send>: Sync,
Arc<dyn Fn(&str, &[u8]) -> Result<Value, Error> + Sync + Send>: Sync,
BoxRaw<IdlTypeSnapshot>: Sync,
NodeRef<Owned, String, Value, LeafOrInternal>: Sync,
BoxRaw<(String, Value)>: Sync,
BoxRaw<MappingSource>: Sync,
NodeRef<Owned, String, Transformation, LeafOrInternal>: Sync,
BoxRaw<(String, Transformation)>: Sync,
BoxRaw<ComputedExpr>: Sync,
NodeRef<Owned, String, FieldTypeInfo, LeafOrInternal>: Sync,
BoxRaw<(String, FieldTypeInfo)>: Sync,
BoxRaw<Predicate>: Sync,
impl Unpin for Specwhere
*const u8 is !null: Unpin,
Box<ComputedExpr>: Unpin,
*const LeafNode<String, Value> is !null: Unpin,
Box<(String, Value)>: Unpin,
Box<dyn Fn(&mut Value, Option<u64>, i64) -> Result<(), Box<dyn Error + Sync + Send>> + Sync + Send>: Unpin,
Arc<dyn Fn(Sender<MutationBatch>, Option<HealthMonitor>, ReconnectionConfig) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>> + Sync + Send>: Unpin,
Arc<dyn Fn(&str, &[u8]) -> Result<Value, Error> + Sync + Send>: Unpin,
Box<IdlTypeSnapshot>: Unpin,
Box<MappingSource>: Unpin,
*const LeafNode<String, Transformation> is !null: Unpin,
Box<(String, Transformation)>: Unpin,
*const LeafNode<String, FieldTypeInfo> is !null: Unpin,
Box<(String, FieldTypeInfo)>: Unpin,
Box<Predicate>: Unpin,
impl UnsafeUnpin for Specwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<(String, EntityBytecode)>: UnsafeUnpin,
PhantomData<(String, Vec<String>)>: UnsafeUnpin,
PhantomData<(String, ())>: UnsafeUnpin,
PhantomData<(String, fn(&[u8]) -> Result<(Value, String), Box<dyn Error>>)>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
*const ArcInner<dyn Fn(Sender<MutationBatch>, Option<HealthMonitor>, ReconnectionConfig) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>> + Sync + Send> is !null: UnsafeUnpin,
PhantomData<ArcInner<dyn Fn(Sender<MutationBatch>, Option<HealthMonitor>, ReconnectionConfig) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send>> + Sync + Send>>: UnsafeUnpin,
PhantomData<ProgramRuntimeDefinition>: UnsafeUnpin,
PhantomData<SerializableStreamSpec>: UnsafeUnpin,
PhantomData<ViewDef>: UnsafeUnpin,
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