Pin
Functions
Utilities for tokenizing strings

Functions

INT32 LEVEL_BASE::Int32FromString (const std::string &s)
 
UINT32 LEVEL_BASE::Uint32FromString (const std::string &s)
 
INT64 LEVEL_BASE::Int64FromString (const std::string &s)
 
UINT64 LEVEL_BASE::Uint64FromString (const std::string &s)
 
FLT64 LEVEL_BASE::FLT64FromString (const std::string &s)
 
INT LEVEL_BASE::CharToHexDigit (CHAR c)
 
ADDRINT LEVEL_BASE::AddrintFromString (const std::string &str)
 
std::string LEVEL_BASE::ReadLine (std::istream &inputFile, UINT32 *lineNum)
 
UINT32 LEVEL_BASE::Tokenize (const std::string &line, std::string *array, UINT32 n)
 

Detailed Description

Availability:
Mode: JIT & Probe
O/S: Linux & Windows
CPU: All

Function Documentation

◆ AddrintFromString()

ADDRINT LEVEL_BASE::AddrintFromString ( const std::string &  str)

Convert a string to an ADDRINT.

◆ CharToHexDigit()

INT LEVEL_BASE::CharToHexDigit ( CHAR  c)

Convert specified character to the corresponding hexadecimal digit.

Returns
integer in the interval [0, 15] or -1 upon failure

◆ FLT64FromString()

FLT64 LEVEL_BASE::FLT64FromString ( const std::string &  s)

Convert a string to a FLT64.

◆ Int32FromString()

INT32 LEVEL_BASE::Int32FromString ( const std::string &  s)

Convert a string to an INT32.

◆ Int64FromString()

INT64 LEVEL_BASE::Int64FromString ( const std::string &  s)

Convert a string to an INT64.

◆ ReadLine()

std::string LEVEL_BASE::ReadLine ( std::istream &  inputFile,
UINT32 *  lineNum 
)

Read a line from file while maintaining a current line count skipping over blank and comment lines.

◆ Tokenize()

UINT32 LEVEL_BASE::Tokenize ( const std::string &  line,
std::string *  array,
UINT32  n 
)

Break a line into tokens separated by whitespace.

Returns
'array' contains the tokens

◆ Uint32FromString()

UINT32 LEVEL_BASE::Uint32FromString ( const std::string &  s)

Convert a string to a UINT32.

◆ Uint64FromString()

UINT64 LEVEL_BASE::Uint64FromString ( const std::string &  s)

Convert a string to a UINT64.