use boost::optional to hold the encoding for now