pub fn serialize_data_into<W, T: ?Sized, S, E>(writer: W, value: &T, size_limit: S) -> Result<()>
where
    W: Write,
    T: ser::Serialize,
    S: SizeLimit,
    E: ByteOrder,
{
    if let Some(limit) = size_limit.limit() {
        calc_serialized_data_size_bounded(value, limit)?;
    }

    let mut serializer = Serializer::<_, E>::new(writer);
    ser::Serialize::serialize(value, &mut serializer)
}
/// Serializes an object directly into a `Write`.
Serializes an object directly into a `Write`.
Serializes an object directly into a ` Write ` .
pub fn serialize_data_into<W, T: ?Sized, S, E>(writer: W, value: &T, size_limit: S) -> Result<()>
where
    W: Write,
    T: ser::Serialize,
    S: SizeLimit,
    E: ByteOrder,
{
    if let Some(limit) = size_limit.limit() {
        calc_serialized_data_size_bounded(value, limit)?;
    }
    let mut serializer = Serializer::<_, E>::new(writer);
    ser::Serialize::serialize(value, &mut serializer)
}
pub fn serialize_data_into < W , T : ? Sized , S , E > ( writer : W , value : & T , size_limit : S ) -> Result < ( ) > where W : Write , T : ser :: Serialize , S : SizeLimit , E : ByteOrder , { if let Some ( limit ) = size_limit . limit ( ) { calc_serialized_data_size_bounded ( value , limit ) ? ; } let mut serializer = Serializer :: < _ , E > :: new ( writer ) ; ser :: Serialize :: serialize ( value , & mut serializer ) }
Serializes an object directly into a `Write`.
Serializes an object directly into a ` Write ` .
writer
W
value
&T
size_limit
S