	public:
		int roleid;
		unsigned int localsid;
		unsigned char mail_id;
		unsigned char blPreserve;
		enum { PROTOCOL_TYPE = PROTOCOL_PRESERVEMAIL };
	public:
		PreserveMail() { type = PROTOCOL_PRESERVEMAIL; }
		PreserveMail(void*) : Protocol(PROTOCOL_PRESERVEMAIL) { }
		PreserveMail (int l_roleid,unsigned int l_localsid,unsigned char l_mail_id,
			unsigned char l_blPreserve)
			 : roleid(l_roleid),localsid(l_localsid),mail_id(l_mail_id)
			,blPreserve(l_blPreserve)
		{
			type = PROTOCOL_PRESERVEMAIL;
		}

		PreserveMail(const PreserveMail &rhs)
			: Protocol(rhs),roleid(rhs.roleid),localsid(rhs.localsid),mail_id(rhs.mail_id)
			,blPreserve(rhs.blPreserve) { }

		GNET::Protocol *Clone() const { return new PreserveMail(*this); }

		OctetsStream& marshal(OctetsStream & os) const
		{
			os << roleid;
			os << localsid;
			os << mail_id;
			os << blPreserve;
			return os;
		}

		const OctetsStream& unmarshal(const OctetsStream &os)
		{
			os >> roleid;
			os >> localsid;
			os >> mail_id;
			os >> blPreserve;
			return os;
		}

		int PriorPolicy( ) const { return 1; }

		bool SizePolicy(size_t size) const { return size <= 64; }
