Struct lua_protobuf_rs::codec::LuaProtoCodec
source · pub struct LuaProtoCodec;
Implementations§
source§impl LuaProtoCodec
impl LuaProtoCodec
pub fn encode_message( &self, lua_message: Table<'_>, descriptor: &MessageDescriptor ) -> Result<Box<dyn MessageDyn>>
pub fn decode_message<'a>( &self, message: &dyn MessageDyn, lua: &'a Lua ) -> Result<Table<'a>>
pub fn box_value( &self, name: &str, field: &str, ty: &RuntimeType, value: Value<'_> ) -> Result<ReflectValueBox>
pub fn unbox_value<'a>( &self, message_name: &str, field_name: &str, value: ReflectValueRef<'_>, lua: &'a Lua ) -> Result<LuaValue<'a>>
Trait Implementations§
source§impl Clone for LuaProtoCodec
impl Clone for LuaProtoCodec
source§fn clone(&self) -> LuaProtoCodec
fn clone(&self) -> LuaProtoCodec
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Default for LuaProtoCodec
impl Default for LuaProtoCodec
source§fn default() -> LuaProtoCodec
fn default() -> LuaProtoCodec
Returns the “default value” for a type. Read more
impl Copy for LuaProtoCodec
Auto Trait Implementations§
impl RefUnwindSafe for LuaProtoCodec
impl Send for LuaProtoCodec
impl Sync for LuaProtoCodec
impl Unpin for LuaProtoCodec
impl UnwindSafe for LuaProtoCodec
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