pub trait ScalarFnPlugin:
'static
+ Send
+ Sync {
// Required methods
fn id(&self) -> ScalarFnId;
fn deserialize(
&self,
metadata: &[u8],
session: &VortexSession,
) -> VortexResult<ScalarFnRef>;
}Expand description
Registry trait for ID-based deserialization of scalar functions.
Plugins are registered in the session by their ScalarFnId. When a serialized scalar
function is encountered, the session resolves the ID to the plugin and calls deserialize
to reconstruct the value as a ScalarFnRef.
Required Methods§
Sourcefn id(&self) -> ScalarFnId
fn id(&self) -> ScalarFnId
Returns the ID for this scalar function.
Sourcefn deserialize(
&self,
metadata: &[u8],
session: &VortexSession,
) -> VortexResult<ScalarFnRef>
fn deserialize( &self, metadata: &[u8], session: &VortexSession, ) -> VortexResult<ScalarFnRef>
Deserialize a scalar function from serialized metadata.