pub fn to_bytes(&self) -> Vec<u8> {
        let mut res = Vec::<u8>::new();
        let mut cur_seq = &self.sequences;
        for _i in 0..self.number_sequences {
            match cur_seq {
                Nil => (),
                Cons(seq, box_list) => {
                    let mut buffer = res;
                    res = (*seq).to_bytes();
                    res.push(255);
                    res.append(&mut buffer);
                    cur_seq = &**box_list;
                }
            }
        }
        res
    }
/// Convert a table to a sequence of bytes
///
/// Sequences of cards are separated by 255.
///
/// # Example 
/// ```
/// use machiavelli::table::*;
/// use machiavelli::sequence_cards::*;
///
/// let mut table = Table::new();
/// table.add(Sequence::from_cards(&[
///     RegularCard(Club, 4), 
///     RegularCard(Club, 5), 
///     RegularCard(Club, 6), 
/// ]));
/// table.add(Sequence::from_cards(&[
///     RegularCard(Heart, 11), 
///     RegularCard(Heart, 12), 
///     RegularCard(Heart, 13), 
/// ]));
///
/// let seq_bytes = table.to_bytes();
///
/// assert_eq!(
///     vec![17,18,19,255,11,12,13,255], 
///     seq_bytes);
/// ```
Convert a table to a sequence of bytes
Sequences of cards are separated by 255.
Convert a table to a sequence of bytes Sequences of cards are separated by 255 .
pub fn to_bytes(&self) -> Vec<u8> {
        let mut res = Vec::<u8>::new();
        let mut cur_seq = &self.sequences;
        for _i in 0..self.number_sequences {
            match cur_seq {
                Nil => (),
                Cons(seq, box_list) => {
                    let mut buffer = res;
                    res = (*seq).to_bytes();
                    res.push(255);
                    res.append(&mut buffer);
                    cur_seq = &**box_list;
                }
            }
        }
        res
    }
pub fn to_bytes ( & self ) -> Vec < u8 > { let mut res = Vec :: < u8 > :: new ( ) ; let mut cur_seq = & self . sequences ; for _i in 0 .. self . number_sequences { match cur_seq { Nil => ( ) , Cons ( seq , box_list ) => { let mut buffer = res ; res = ( * seq ) . to_bytes ( ) ; res . push ( 255 ) ; res . append ( & mut buffer ) ; cur_seq = & * * box_list ; } } } res }
Convert a table to a sequence of bytes
Sequences of cards are separated by 255.
Convert a table to a sequence of bytes Sequences of cards are separated by 255 .
&self
&self
example 
```
use machiavelli::table::*;
use machiavelli::sequence_cards::*.

let mut table = Table::new();
table.add(Sequence::from_cards(&[
RegularCard(Club, 4),
RegularCard(Club, 5),
RegularCard(Club, 6),
]));
table.add(Sequence::from_cards(&[
RegularCard(Heart, 11),
RegularCard(Heart, 12),
RegularCard(Heart, 13),
])).

let seq_bytes = table.to_bytes().


` ` ` use machiavelli :: table :: * ; use machiavelli :: sequence_cards :: * . let mut table = Table :: new () ; table . add ( Sequence :: from_cards ( & [ RegularCard ( Club 4 ) RegularCard ( Club 5 ) RegularCard ( Club 6 ) ] )) ; table . add ( Sequence :: from_cards ( & [ RegularCard ( Heart 11 ) RegularCard ( Heart 12 ) RegularCard ( Heart 13 ) ] )) . let seq_bytes = table . to_bytes () .