fn marshal_body(msg: Message, bytes: &mut Vec<u8>) {
            match msg {
                Message::Hello => (),
                Message::Error(buf) => Error::marshal(buf, bytes),
                Message::EchoReply(buf) => bytes.write_all(&buf).unwrap(),
                Message::EchoRequest(buf) => bytes.write_all(&buf).unwrap(),
                Message::FeaturesReq => (),
                Message::FlowMod(flow_mod) => FlowMod::marshal(flow_mod, bytes),
                Message::PacketIn(packet_in) => PacketIn::marshal(packet_in, bytes),
                Message::FlowRemoved(flow) => FlowRemoved::marshal(flow, bytes),
                Message::PortStatus(sts) => PortStatus::marshal(sts, bytes),
                Message::PacketOut(po) => PacketOut::marshal(po, bytes),
                Message::BarrierRequest | Message::BarrierReply => (),
                _ => (),
            }
        }
/// Marshal the OpenFlow message `msg`.
Marshal the OpenFlow message `msg`.
Marshal the OpenFlow message ` msg ` .
fn marshal_body(msg: Message, bytes: &mut Vec<u8>) {
            match msg {
                Message::Hello => (),
                Message::Error(buf) => Error::marshal(buf, bytes),
                Message::EchoReply(buf) => bytes.write_all(&buf).unwrap(),
                Message::EchoRequest(buf) => bytes.write_all(&buf).unwrap(),
                Message::FeaturesReq => (),
                Message::FlowMod(flow_mod) => FlowMod::marshal(flow_mod, bytes),
                Message::PacketIn(packet_in) => PacketIn::marshal(packet_in, bytes),
                Message::FlowRemoved(flow) => FlowRemoved::marshal(flow, bytes),
                Message::PortStatus(sts) => PortStatus::marshal(sts, bytes),
                Message::PacketOut(po) => PacketOut::marshal(po, bytes),
                Message::BarrierRequest | Message::BarrierReply => (),
                _ => (),
            }
        }
fn marshal_body ( msg : Message , bytes : & mut Vec < u8 > ) { match msg { Message :: Hello => ( ) , Message :: Error ( buf ) => Error :: marshal ( buf , bytes ) , Message :: EchoReply ( buf ) => bytes . write_all ( & buf ) . unwrap ( ) , Message :: EchoRequest ( buf ) => bytes . write_all ( & buf ) . unwrap ( ) , Message :: FeaturesReq => ( ) , Message :: FlowMod ( flow_mod ) => FlowMod :: marshal ( flow_mod , bytes ) , Message :: PacketIn ( packet_in ) => PacketIn :: marshal ( packet_in , bytes ) , Message :: FlowRemoved ( flow ) => FlowRemoved :: marshal ( flow , bytes ) , Message :: PortStatus ( sts ) => PortStatus :: marshal ( sts , bytes ) , Message :: PacketOut ( po ) => PacketOut :: marshal ( po , bytes ) , Message :: BarrierRequest | Message :: BarrierReply => ( ) , _ => ( ) , } }
Marshal the OpenFlow message `msg`.
Marshal the OpenFlow message ` msg ` .
msg
Message
bytes
&mut Vec<u8>
msg
Message
bytes
&mut Vec<u8>