MCPcopy Create free account
hub / github.com/apache/datafusion / deserialize

Function deserialize

datafusion/substrait/src/serializer.rs:67–74  ·  view source on GitHub ↗

Reads the file at `path` and deserializes a plan from the bytes.

(path: impl AsRef<Path>)

Source from the content-addressed store, hash-verified

65
66/// Reads the file at `path` and deserializes a plan from the bytes.
67pub async fn deserialize(path: impl AsRef<Path>) -> Result<Box<Plan>> {
68 let mut protobuf_in = Vec::<u8>::new();
69
70 let mut file = OpenOptions::new().read(true).open(path).await?;
71 file.read_to_end(&mut protobuf_in).await?;
72
73 deserialize_bytes(protobuf_in).await
74}
75
76/// Deserializes a plan from the bytes.
77pub async fn deserialize_bytes(proto_bytes: Vec<u8>) -> Result<Box<Plan>> {

Callers 4

create_session_contextFunction · 0.85
serialize_to_fileFunction · 0.85
serialize_simple_selectFunction · 0.85

Calls 4

newFunction · 0.85
deserialize_bytesFunction · 0.85
readMethod · 0.80
openMethod · 0.45

Tested by 3

serialize_to_fileFunction · 0.68
serialize_simple_selectFunction · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…