uuid-linux.cpp revision 49d36b55bcf206ced156a303dab448a75fac001b
/* $Id$ */
/** @file
* InnoTek Portable Runtime - UUID, LINUX.
*/
/*
* Copyright (C) 2006 InnoTek Systemberatung GmbH
*
* This file is part of VirtualBox Open Source Edition (OSE), as
* available from http://www.virtualbox.org. This file is free software;
* General Public License as published by the Free Software Foundation,
* in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
* distribution. VirtualBox OSE is distributed in the hope that it will
* be useful, but WITHOUT ANY WARRANTY of any kind.
*
* If you received this file as part of a commercial VirtualBox
* distribution, then only the terms of your commercial VirtualBox
* license agreement apply instead of the previous paragraph.
*/
/*******************************************************************************
* Header Files *
*******************************************************************************/
/**
* Converts the byte order of the first 32 bit UUID component and next two 16
* bit components from BIG_ENDIAN to LITTLE_ENDIAN and vice versa.
*
* @returns iprt status code.
* @param pUuid Uuid to convert.
*/
{
// 32 bit component
// two 16 bit components
}
#if BYTE_ORDER == LITTLE_ENDIAN
#else
#define RTUUID_CONVERT_BYTEORDER(pUuid) do {} while (0)
#endif
/**
* Generates a new UUID value.
*
* @returns iprt status code.
* @param pUuid Where to store generated uuid.
*/
{
/* check params */
{
AssertMsgFailed(("pUuid=NULL\n"));
return VERR_INVALID_PARAMETER;
}
return VINF_SUCCESS;
}
/**
* Makes a null UUID value.
*
* @returns iprt status code.
* @param pUuid Where to store generated null uuid.
*/
{
/* check params */
{
AssertMsgFailed(("pUuid=NULL\n"));
return VERR_INVALID_PARAMETER;
}
return VINF_SUCCESS;
}
/**
* Checks if UUID is null.
*
* @returns true if UUID is null.
* @param pUuid uuid to check.
*/
{
/* check params */
{
AssertMsgFailed(("pUuid=NULL\n"));
return true;
}
}
/**
* Compares two UUID values.
*
* @returns 0 if eq, < 0 or > 0.
* @param pUuid1 First value to compare.
* @param pUuid2 Second value to compare.
*/
{
/* check params */
{
AssertMsgFailed(("Invalid parameters\n"));
return 1;
}
}
/**
* Converts binary UUID to its string representation.
*
* @returns iprt status code.
* @param pUuid Uuid to convert.
* @param pszString Where to store result string.
* @param cchString pszString buffer length, must be >= RTUUID_STR_LENGTH.
*/
{
/* check params */
{
AssertMsgFailed(("Invalid parameters\n"));
return VERR_INVALID_PARAMETER;
}
return VINF_SUCCESS;
}
/**
* Converts UUID from its string representation to binary format.
*
* @returns iprt status code.
* @param pUuid Where to store result Uuid.
* @param pszString String with UUID text data.
*/
{
/* check params */
{
AssertMsgFailed(("Invalid parameters\n"));
return VERR_INVALID_PARAMETER;
}
{
return VINF_SUCCESS;
}
return VERR_INVALID_UUID_FORMAT;
}