/*
 * Please do not edit this file.
 * It was generated using rpcgen.
 */

#include "guestQuiesce.h"

bool_t
xdr_GuestQuiesceParamsVersion (XDR *xdrs, GuestQuiesceParamsVersion *objp)
{

	 if (!xdr_enum (xdrs, (enum_t *) objp))
		 return FALSE;
	return TRUE;
}

bool_t
xdr_GuestQuiesceParamsV1 (XDR *xdrs, GuestQuiesceParamsV1 *objp)
{

	 if (!xdr_Bool (xdrs, &objp->createManifest))
		 return FALSE;
	 if (!xdr_Bool (xdrs, &objp->quiesceApps))
		 return FALSE;
	 if (!xdr_Bool (xdrs, &objp->quiesceFS))
		 return FALSE;
	 if (!xdr_Bool (xdrs, &objp->writableSnapshot))
		 return FALSE;
	 if (!xdr_Bool (xdrs, &objp->execScripts))
		 return FALSE;
	 if (!xdr_string (xdrs, &objp->scriptArg, GUESTQUIESCE_SCRIPTARG_MAX_LEN))
		 return FALSE;
	 if (!xdr_uint32 (xdrs, &objp->timeout))
		 return FALSE;
	 if (!xdr_string (xdrs, &objp->diskUuids, GUESTQUIESCE_DISKUUID_MAX_LEN))
		 return FALSE;
	return TRUE;
}

bool_t
xdr_GuestQuiesceParamsV2 (XDR *xdrs, GuestQuiesceParamsV2 *objp)
{

	 if (!xdr_GuestQuiesceParamsV1 (xdrs, &objp->paramsV1))
		 return FALSE;
	 if (!xdr_uint32 (xdrs, &objp->vssBackupContext))
		 return FALSE;
	 if (!xdr_uint32 (xdrs, &objp->vssBackupType))
		 return FALSE;
	 if (!xdr_Bool (xdrs, &objp->vssBootableSystemState))
		 return FALSE;
	 if (!xdr_Bool (xdrs, &objp->vssPartialFileSupport))
		 return FALSE;
	return TRUE;
}

bool_t
xdr_GuestQuiesceParams (XDR *xdrs, GuestQuiesceParams *objp)
{

	 if (!xdr_GuestQuiesceParamsVersion (xdrs, &objp->ver))
		 return FALSE;
	switch (objp->ver) {
	case GUESTQUIESCEPARAMS_V1:
		 if (!xdr_pointer (xdrs, (char **)&objp->GuestQuiesceParams_u.guestQuiesceParamsV1, sizeof (GuestQuiesceParamsV1), (xdrproc_t) xdr_GuestQuiesceParamsV1))
			 return FALSE;
		break;
	case GUESTQUIESCEPARAMS_V2:
		 if (!xdr_pointer (xdrs, (char **)&objp->GuestQuiesceParams_u.guestQuiesceParamsV2, sizeof (GuestQuiesceParamsV2), (xdrproc_t) xdr_GuestQuiesceParamsV2))
			 return FALSE;
		break;
	default:
		return FALSE;
	}
	return TRUE;
}
