ccgl Namespace Reference

Common Cross-platform Geographic Library (CCGL) More...

Namespaces

namespace  data_raster
 Raster class to handle various raster data.
 
namespace  db_mongoc
 Simple wrappers of the API of MongoDB C driver mongo-c-driver, see MongoDB C Driver for more information.
 
namespace  utils_array
 Array related functions include vector and pointer array.
 
namespace  utils_filesystem
 File Input and output related functions.
 
namespace  utils_math
 Basic mathematics related functions.
 
namespace  utils_string
 String related functions.
 
namespace  utils_time
 Time related functions.
 

Classes

class  Interface
 Base type of all interfaces. More...
 
class  ModelException
 Print the exception message. More...
 
class  NotCopyable
 Base class for classes that cannot be copied. More...
 
class  Object
 Base of all classes. More...
 

Typedefs

typedef int8_t vint8_t
 
typedef uint8_t vuint8_t
 
typedef int16_t vint16_t
 
typedef uint16_t vuint16_t
 
typedef int32_t vint32_t
 
typedef uint32_t vuint32_t
 
typedef int64_t vint64_t
 
typedef uint64_t vuint64_t
 
typedef vint32_t vint
 
typedef vint32_t vsint
 
typedef vuint32_t vuint
 
typedef vint64_t pos_t
 Signed integer representing position.
 
typedef std::map< string, string > STRING_MAP
 Map of string key and string value.
 
typedef std::map< string, double > STRDBL_MAP
 Map of string key and double value.
 

Functions

bool IsIpAddress (const char *ip)
 Check if the IP address is valid. More...
 
void Log (const string &msg, const string &logpath="debugInfo.log")
 Writes an entry to the log file. More...
 
int GetAvailableThreadNum ()
 Detect the available threads number. More...
 
void SetDefaultOpenMPThread ()
 Set the default omp thread number if necessary. More...
 
void SetOpenMPThread (int n)
 Set the omp thread number by given thread number. More...
 
void StatusMessage (const char *msg)
 Print status messages for Debug. More...
 
void StatusMessage (const string &msg)
 Print status messages for Debug. More...
 
void SleepMs (const int millisecs)
 Sleep milliseconds. More...
 

Detailed Description

Common Cross-platform Geographic Library (CCGL)

Function Documentation

◆ GetAvailableThreadNum()

◆ IsIpAddress()

bool ccgl::IsIpAddress ( const char *  ip)

Check if the IP address is valid.

Parameters
[in]ipchar* IP address.

◆ Log()

void ccgl::Log ( const string &  msg,
const string &  logpath = "debugInfo.log" 
)

Writes an entry to the log file.

Normally only used for debug

Parameters
[in]msgstring log message
[in]logpathstring Optional

◆ SetDefaultOpenMPThread()

void ccgl::SetDefaultOpenMPThread ( )

Set the default omp thread number if necessary.

do nothing if OMP is not supported

◆ SetOpenMPThread()

void ccgl::SetOpenMPThread ( int  n)

Set the omp thread number by given thread number.

Parameters
[in]nThread number greater than 1.

do nothing if OMP is not supported

◆ SleepMs()

void ccgl::SleepMs ( const int  millisecs)
inline

Sleep milliseconds.

Parameters
[in]millisecsSleep timespan.

◆ StatusMessage() [1/2]

void ccgl::StatusMessage ( const char *  msg)

Print status messages for Debug.

Parameters
[in]msgchar* Message

Just for debugging

◆ StatusMessage() [2/2]

void ccgl::StatusMessage ( const string &  msg)

Print status messages for Debug.

Parameters
[in]msgchar* Message