version 1.7.4.1, 2004/08/20 17:48:55
|
version 1.15, 2005/04/08 14:23:05
|
|
|
//%2003//////////////////////////////////////////////////////////////////////// |
//%2005//////////////////////////////////////////////////////////////////////// |
// | // |
// Copyright (c) 2000, 2001, 2002 BMC Software, Hewlett-Packard Development |
// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development |
// Company, L. P., IBM Corp., The Open Group, Tivoli Systems. |
// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems. |
// Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L. P.; | // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L. P.; |
// IBM Corp.; EMC Corporation, The Open Group. | // IBM Corp.; EMC Corporation, The Open Group. |
|
// Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.; |
|
// IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group. |
|
// Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.; |
|
// EMC Corporation; VERITAS Software Corporation; The Open Group. |
// | // |
// Permission is hereby granted, free of charge, to any person obtaining a copy | // Permission is hereby granted, free of charge, to any person obtaining a copy |
// of this software and associated documentation files (the "Software"), to | // of this software and associated documentation files (the "Software"), to |
|
|
// | // |
// Author: Dave Rosckes (rosckes@us.ibm.com) | // Author: Dave Rosckes (rosckes@us.ibm.com) |
// | // |
|
// Modified By: David Dillard, VERITAS Software Corp. |
|
// (david.dillard@veritas.com) |
// | // |
//%///////////////////////////////////////////////////////////////////////////// | //%///////////////////////////////////////////////////////////////////////////// |
| |
#include <Pegasus/Common/Config.h> | #include <Pegasus/Common/Config.h> |
#include <Pegasus/Common/Array.h> | #include <Pegasus/Common/Array.h> |
#include "CommonUTF.h" | #include "CommonUTF.h" |
#include <cctype> |
|
#include <cstdio> | #include <cstdio> |
#include <cstring> | #include <cstring> |
|
#include <cctype> |
| |
PEGASUS_NAMESPACE_BEGIN | PEGASUS_NAMESPACE_BEGIN |
| |
| |
inline Uint8 _hexCharToNumeric(const Uint16 c) |
inline Uint8 _hexCharToNumeric(Char16 c) |
{ | { |
Uint8 n; | Uint8 n; |
| |
|
|
} | } |
| |
// Note: Caller must ensure that "src" contains "size" bytes. | // Note: Caller must ensure that "src" contains "size" bytes. |
int isValid_U8(const Uint8 *src, int size) |
Boolean isValid_U8(const Uint8 *src, int size) |
{ | { |
Uint8 U8_char; | Uint8 U8_char; |
const Uint8 *srcptr = src+size; | const Uint8 *srcptr = src+size; |
|
|
0x00};*/ | 0x00};*/ |
// char tmp_[] = "class"; | // char tmp_[] = "class"; |
// char * tmp = legal; | // char * tmp = legal; |
Uint32 count = 0; |
size_t count = 0; |
Uint32 size = strlen(legal); |
const size_t size = strlen(legal); |
// printf("size = %d\n",size); | // printf("size = %d\n",size); |
while(count<size) | while(count<size) |
{ | { |