Convenience functions for serializing a single object

#include <x/serialize.H>

std::vector<std::string> strarray;
	
// ...
	
std::vector<char> buffer;
	
buffer.resize(x::serialize::object(strarray));
	
char *ptr=&buffer[0];

x::serialize::object(strarray, ptr);

The single argument version of x::serialize's object() public member function constructs an instance of sizeof_iterator, serialized the given object, and returns the resulting byte count.

The two argument version of object() constructs an instance of iterator and serializes the given object.