|
/////////////////////////////////////////////////////////////////////////////////////////
// Project: SP Data Formatting Library 1.5
//
// File: UInt8Formatter.cpp
//
// Developer(s): Sergei Pavlovsky
// sergei_vp@hotmail.com
// Copyright (c) 2004-2005
//
// Description: Implementation of the formatter for unsigned char values.
//
// Platforms: Win32, ATL
//
// This code may be used in compiled form in any way you desire. This file may be
// redistributed unmodified by any means PROVIDING it is not sold for profit without
// the authors written consent, and providing that this notice and the authors name
// is included. If the source code in this file is used in any commercial application
// then acknowledgement must be made to the author of this file (in whatever form
// you wish).
//
// This file is provided "as is" with no expressed or implied warranty. The author
// accepts no liability for any damage/loss of business that this product may cause.
/////////////////////////////////////////////////////////////////////////////////////////
#include "StdAfx.h"
#include "UInt8Formatter.h"
namespace SP
{
/////////////////////////////////////////////////////////////////////////////////////////
// CUInt8Formatter class implementation
/////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////
// Accessors
CDataFormatter::EnumDataType CUInt8Formatter::GetDataType() const throw()
{
return DT_UI8;
}
SIZE_T CUInt8Formatter::GetDataSize() const throw()
{
return sizeof(unsigned char);
}
/////////////////////////////////////////////////////////////////////////////////////////
// CDataFormatter class implementation
/////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////
// Class factories
CFormatter* CFormatter::CreateRawForUInt8(WORD fTraits, LCID lcid)
{
// Create formater object
return new CUInt8Formatter(lcid, fTraits);
}
}; // namespace SP
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.
A list of licenses authors might use can be found here
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.