pub trait Serialize {
type Input: ?Sized;
// Required method
fn serialize<S: Serializer>(
value: &Self::Input,
ser: &mut S,
) -> SerializeResult;
}
Required Associated Types§
Required Methods§
fn serialize<S: Serializer>(value: &Self::Input, ser: &mut S) -> SerializeResult
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementations on Foreign Types§
Source§impl<T: Serialize> Serialize for Option<T>
Option is used for optional values at the end of a structure.
Once Option is used, all following must be Option as well.
impl<T: Serialize> Serialize for Option<T>
Option is used for optional values at the end of a structure. Once Option is used, all following must be Option as well.
Implementors§
Source§impl Serialize for ToClientCommand
impl Serialize for ToClientCommand
type Input = ToClientCommand
Source§impl Serialize for ToServerCommand
impl Serialize for ToServerCommand
type Input = ToServerCommand
Source§impl Serialize for ControlBody
impl Serialize for ControlBody
type Input = ControlBody
Source§impl Serialize for PacketBody
impl Serialize for PacketBody
type Input = PacketBody
Source§impl Serialize for AccessDeniedCode
impl Serialize for AccessDeniedCode
type Input = AccessDeniedCode
Source§impl Serialize for ActiveObjectCommand
impl Serialize for ActiveObjectCommand
type Input = ActiveObjectCommand
Source§impl Serialize for AlignStyle
impl Serialize for AlignStyle
type Input = AlignStyle
Source§impl Serialize for HudSetParam
impl Serialize for HudSetParam
type Input = HudSetParam
Source§impl Serialize for InteractAction
impl Serialize for InteractAction
type Input = InteractAction
Source§impl Serialize for InventoryAction
impl Serialize for InventoryAction
type Input = InventoryAction
Source§impl Serialize for InventoryLocation
impl Serialize for InventoryLocation
type Input = InventoryLocation
Source§impl Serialize for PointedThing
impl Serialize for PointedThing
type Input = PointedThing
Source§impl Serialize for TileAnimationParams
impl Serialize for TileAnimationParams
type Input = TileAnimationParams
Source§impl Serialize for TweenStyle
impl Serialize for TweenStyle
type Input = TweenStyle
Source§impl Serialize for AcceptSudoModeSpec
impl Serialize for AcceptSudoModeSpec
type Input = AcceptSudoModeSpec
Source§impl Serialize for AccessDeniedLegacySpec
impl Serialize for AccessDeniedLegacySpec
Source§impl Serialize for AccessDeniedSpec
impl Serialize for AccessDeniedSpec
type Input = AccessDeniedSpec
Source§impl Serialize for AddParticlespawnerSpec
impl Serialize for AddParticlespawnerSpec
Source§impl Serialize for AddnodeSpec
impl Serialize for AddnodeSpec
type Input = AddnodeSpec
Source§impl Serialize for AnnounceMediaSpec
impl Serialize for AnnounceMediaSpec
type Input = AnnounceMediaSpec
Source§impl Serialize for AuthAcceptSpec
impl Serialize for AuthAcceptSpec
type Input = AuthAcceptSpec
Source§impl Serialize for BlockdataSpec
impl Serialize for BlockdataSpec
type Input = BlockdataSpec
Source§impl Serialize for BreathSpec
impl Serialize for BreathSpec
type Input = BreathSpec
Source§impl Serialize for ClientReadySpec
impl Serialize for ClientReadySpec
type Input = ClientReadySpec
Source§impl Serialize for CloudParamsSpec
impl Serialize for CloudParamsSpec
type Input = CloudParamsSpec
Source§impl Serialize for DamageSpec
impl Serialize for DamageSpec
type Input = DamageSpec
Source§impl Serialize for DeathscreenSpec
impl Serialize for DeathscreenSpec
type Input = DeathscreenSpec
Source§impl Serialize for DeletedblocksSpec
impl Serialize for DeletedblocksSpec
type Input = DeletedblocksSpec
Source§impl Serialize for DenySudoModeSpec
impl Serialize for DenySudoModeSpec
type Input = DenySudoModeSpec
Source§impl Serialize for DetachedInventorySpec
impl Serialize for DetachedInventorySpec
Source§impl Serialize for EyeOffsetSpec
impl Serialize for EyeOffsetSpec
type Input = EyeOffsetSpec
Source§impl Serialize for FadeSoundSpec
impl Serialize for FadeSoundSpec
type Input = FadeSoundSpec
Source§impl Serialize for FirstSrpSpec
impl Serialize for FirstSrpSpec
type Input = FirstSrpSpec
Source§impl Serialize for FormspecPrependSpec
impl Serialize for FormspecPrependSpec
type Input = FormspecPrependSpec
Source§impl Serialize for GotblocksSpec
impl Serialize for GotblocksSpec
type Input = GotblocksSpec
Source§impl Serialize for HaveMediaSpec
impl Serialize for HaveMediaSpec
type Input = HaveMediaSpec
Source§impl Serialize for HudSetFlagsSpec
impl Serialize for HudSetFlagsSpec
type Input = HudSetFlagsSpec
Source§impl Serialize for HudSetParamSpec
impl Serialize for HudSetParamSpec
type Input = HudSetParamSpec
Source§impl Serialize for HudaddSpec
impl Serialize for HudaddSpec
type Input = HudaddSpec
Source§impl Serialize for HudchangeSpec
impl Serialize for HudchangeSpec
type Input = HudchangeSpec
Source§impl Serialize for InteractSpec
impl Serialize for InteractSpec
type Input = InteractSpec
Source§impl Serialize for InventoryActionSpec
impl Serialize for InventoryActionSpec
type Input = InventoryActionSpec
Source§impl Serialize for InventoryFieldsSpec
impl Serialize for InventoryFieldsSpec
type Input = InventoryFieldsSpec
Source§impl Serialize for InventoryFormspecSpec
impl Serialize for InventoryFormspecSpec
Source§impl Serialize for InventorySpec
impl Serialize for InventorySpec
type Input = InventorySpec
Source§impl Serialize for ItemdefSpec
impl Serialize for ItemdefSpec
type Input = ItemdefSpec
Source§impl Serialize for MediaPushSpec
impl Serialize for MediaPushSpec
type Input = MediaPushSpec
Source§impl Serialize for MinimapModesSpec
impl Serialize for MinimapModesSpec
type Input = MinimapModesSpec
Source§impl Serialize for ModchannelJoinSpec
impl Serialize for ModchannelJoinSpec
type Input = ModchannelJoinSpec
Source§impl Serialize for ModchannelLeaveSpec
impl Serialize for ModchannelLeaveSpec
type Input = ModchannelLeaveSpec
Source§impl Serialize for ModchannelSignalSpec
impl Serialize for ModchannelSignalSpec
type Input = ModchannelSignalSpec
Source§impl Serialize for MovePlayerSpec
impl Serialize for MovePlayerSpec
type Input = MovePlayerSpec
Source§impl Serialize for MovementSpec
impl Serialize for MovementSpec
type Input = MovementSpec
Source§impl Serialize for NodedefSpec
impl Serialize for NodedefSpec
type Input = NodedefSpec
Source§impl Serialize for NodemetaChangedSpec
impl Serialize for NodemetaChangedSpec
type Input = NodemetaChangedSpec
Source§impl Serialize for NodemetaFieldsSpec
impl Serialize for NodemetaFieldsSpec
type Input = NodemetaFieldsSpec
Source§impl Serialize for PlaySoundSpec
impl Serialize for PlaySoundSpec
type Input = PlaySoundSpec
Source§impl Serialize for PlayerSpeedSpec
impl Serialize for PlayerSpeedSpec
type Input = PlayerSpeedSpec
Source§impl Serialize for PlayeritemSpec
impl Serialize for PlayeritemSpec
type Input = PlayeritemSpec
Source§impl Serialize for PlayerposSpec
impl Serialize for PlayerposSpec
type Input = PlayerposSpec
Source§impl Serialize for PrivilegesSpec
impl Serialize for PrivilegesSpec
type Input = PrivilegesSpec
Source§impl Serialize for RemovedSoundsSpec
impl Serialize for RemovedSoundsSpec
type Input = RemovedSoundsSpec
Source§impl Serialize for RemovenodeSpec
impl Serialize for RemovenodeSpec
type Input = RemovenodeSpec
Source§impl Serialize for RequestMediaSpec
impl Serialize for RequestMediaSpec
type Input = RequestMediaSpec
Source§impl Serialize for RespawnSpec
impl Serialize for RespawnSpec
type Input = RespawnSpec
Source§impl Serialize for SetLightingSpec
impl Serialize for SetLightingSpec
type Input = SetLightingSpec
Source§impl Serialize for SetMoonSpec
impl Serialize for SetMoonSpec
type Input = SetMoonSpec
Source§impl Serialize for SetSkySpec
impl Serialize for SetSkySpec
type Input = SetSkySpec
Source§impl Serialize for SetStarsSpec
impl Serialize for SetStarsSpec
type Input = SetStarsSpec
Source§impl Serialize for SetSunSpec
impl Serialize for SetSunSpec
type Input = SetSunSpec
Source§impl Serialize for ShowFormspecSpec
impl Serialize for ShowFormspecSpec
type Input = ShowFormspecSpec
Source§impl Serialize for SpawnParticleSpec
impl Serialize for SpawnParticleSpec
type Input = SpawnParticleSpec
Source§impl Serialize for SrpBytesASpec
impl Serialize for SrpBytesASpec
type Input = SrpBytesASpec
Source§impl Serialize for SrpBytesMSpec
impl Serialize for SrpBytesMSpec
type Input = SrpBytesMSpec
Source§impl Serialize for SrpBytesSBSpec
impl Serialize for SrpBytesSBSpec
type Input = SrpBytesSBSpec
Source§impl Serialize for StopSoundSpec
impl Serialize for StopSoundSpec
type Input = StopSoundSpec
Source§impl Serialize for TCChatMessageSpec
impl Serialize for TCChatMessageSpec
type Input = TCChatMessageSpec
Source§impl Serialize for TCModchannelMsgSpec
impl Serialize for TCModchannelMsgSpec
type Input = TCModchannelMsgSpec
Source§impl Serialize for TSChatMessageSpec
impl Serialize for TSChatMessageSpec
type Input = TSChatMessageSpec
Source§impl Serialize for TSModchannelMsgSpec
impl Serialize for TSModchannelMsgSpec
type Input = TSModchannelMsgSpec
Source§impl Serialize for TimeOfDaySpec
impl Serialize for TimeOfDaySpec
type Input = TimeOfDaySpec
Source§impl Serialize for UpdateClientInfoSpec
impl Serialize for UpdateClientInfoSpec
type Input = UpdateClientInfoSpec
Source§impl Serialize for UpdatePlayerListSpec
impl Serialize for UpdatePlayerListSpec
type Input = UpdatePlayerListSpec
Source§impl Serialize for OriginalBody
impl Serialize for OriginalBody
type Input = OriginalBody
Source§impl Serialize for ReliableBody
impl Serialize for ReliableBody
type Input = ReliableBody
Source§impl Serialize for SetPeerIdBody
impl Serialize for SetPeerIdBody
type Input = SetPeerIdBody
Source§impl Serialize for AOCAttachTo
impl Serialize for AOCAttachTo
type Input = AOCAttachTo
Source§impl Serialize for AOCObsolete1
impl Serialize for AOCObsolete1
type Input = AOCObsolete1
Source§impl Serialize for AOCPunched
impl Serialize for AOCPunched
type Input = AOCPunched
Source§impl Serialize for AOCSetAnimation
impl Serialize for AOCSetAnimation
type Input = AOCSetAnimation
Source§impl Serialize for AOCSetAnimationSpeed
impl Serialize for AOCSetAnimationSpeed
type Input = AOCSetAnimationSpeed
Source§impl Serialize for AOCSetBonePosition
impl Serialize for AOCSetBonePosition
type Input = AOCSetBonePosition
Source§impl Serialize for AOCSetPhysicsOverride
impl Serialize for AOCSetPhysicsOverride
Source§impl Serialize for AOCSetProperties
impl Serialize for AOCSetProperties
type Input = AOCSetProperties
Source§impl Serialize for AOCSetSprite
impl Serialize for AOCSetSprite
type Input = AOCSetSprite
Source§impl Serialize for AOCSetTextureMod
impl Serialize for AOCSetTextureMod
type Input = AOCSetTextureMod
Source§impl Serialize for AOCSpawnInfant
impl Serialize for AOCSpawnInfant
type Input = AOCSpawnInfant
Source§impl Serialize for AOCUpdateArmorGroups
impl Serialize for AOCUpdateArmorGroups
type Input = AOCUpdateArmorGroups
Source§impl Serialize for AOCUpdatePosition
impl Serialize for AOCUpdatePosition
type Input = AOCUpdatePosition
Source§impl Serialize for AbsBlockPos
impl Serialize for AbsBlockPos
type Input = AbsBlockPos
Source§impl Serialize for AbsNodeMetadataList
impl Serialize for AbsNodeMetadataList
type Input = AbsNodeMetadataList
Source§impl Serialize for ActiveObjectMessage
impl Serialize for ActiveObjectMessage
type Input = ActiveObjectMessage
Source§impl Serialize for AddedObject
impl Serialize for AddedObject
type Input = AddedObject
Source§impl Serialize for AuthMechsBitset
impl Serialize for AuthMechsBitset
type Input = AuthMechsBitset
Source§impl Serialize for AutoExposure
impl Serialize for AutoExposure
type Input = AutoExposure
Source§impl Serialize for ContentFeatures
impl Serialize for ContentFeatures
type Input = ContentFeatures
Source§impl Serialize for GenericInitData
impl Serialize for GenericInitData
type Input = GenericInitData
Source§impl Serialize for Inventory
Inventory is sent as a “almost” line-based text format.
Unfortutely there’s no way to simplify this code, it has to mirror
the way Minetest does it exactly, because it is so arbitrary.
impl Serialize for Inventory
Inventory is sent as a “almost” line-based text format. Unfortutely there’s no way to simplify this code, it has to mirror the way Minetest does it exactly, because it is so arbitrary.
Source§impl Serialize for InventoryList
impl Serialize for InventoryList
type Input = InventoryList
Source§impl Serialize for ItemStackMetadata
impl Serialize for ItemStackMetadata
type Input = ItemStackMetadata
Source§impl Serialize for ItemdefList
impl Serialize for ItemdefList
type Input = ItemdefList
Source§impl Serialize for LineAttractor
impl Serialize for LineAttractor
type Input = LineAttractor
Source§impl Serialize for MapNodesBulk
impl Serialize for MapNodesBulk
type Input = MapNodesBulk
Source§impl Serialize for MediaAnnouncement
impl Serialize for MediaAnnouncement
type Input = MediaAnnouncement
Source§impl Serialize for MediaFileData
impl Serialize for MediaFileData
type Input = MediaFileData
Source§impl Serialize for MinimapMode
impl Serialize for MinimapMode
type Input = MinimapMode
Source§impl Serialize for MinimapModeList
impl Serialize for MinimapModeList
type Input = MinimapModeList
Source§impl Serialize for MoonParams
impl Serialize for MoonParams
type Input = MoonParams
Source§impl Serialize for NodeBoxConnected
impl Serialize for NodeBoxConnected
type Input = NodeBoxConnected
Source§impl Serialize for NodeBoxFixed
impl Serialize for NodeBoxFixed
type Input = NodeBoxFixed
Source§impl Serialize for NodeBoxLeveled
impl Serialize for NodeBoxLeveled
type Input = NodeBoxLeveled
Source§impl Serialize for NodeBoxWallmounted
impl Serialize for NodeBoxWallmounted
type Input = NodeBoxWallmounted
Source§impl Serialize for NodeDefManager
The way this structure is encoded is really unusual, in order to
allow the ContentFeatures to be extended in the future without
changing the encoding.
impl Serialize for NodeDefManager
The way this structure is encoded is really unusual, in order to allow the ContentFeatures to be extended in the future without changing the encoding.