GL Studio C++ Runtime API
VPFUtil::FilePath Class Reference

#include <vpf_util.h>

Public Member Functions

 FilePath (void)
 
 FilePath (const FilePath &src)
 
 FilePath (const char *const path, const bool isDirectory)
 
const char * Append (const char *const name, const bool isDirectory, const bool forceUpperCase=true, const bool killTrailingWS=true)
 
bool IsValid (void) const
 
const char * GetFilePath (void) const
 

Static Public Attributes

static const char DIR_SEPARATOR
 

Protected Types

enum  
 

Protected Attributes

WarningBool _isValid
 
char _pathStr [MAX_PATH_LENGTH+1u]
 

Detailed Description

encapsulates full path / full filename to a directory / file

Member Enumeration Documentation

anonymous enum
protected

longest possible path

Constructor & Destructor Documentation

FilePath ( void  )

Ctor

FilePath ( const FilePath src)

copy Ctor

FilePath ( const char *const  path,
const bool  isDirectory 
)

Construct from a path

Parameters
pathpath
isDirectorytrue if path is a directory path else false

Member Function Documentation

const char* Append ( const char *const  name,
const bool  isDirectory,
const bool  forceUpperCase = true,
const bool  killTrailingWS = true 
)

Append a filename or directory name. Check IsValid()

Parameters
namename of file or directory (should not end in DIR_SEPARATOR)
isDirectorytrue if appending a directory name else false
forceUpperCase[optional, defaults to true] true to force appended string to all uppercase
killTrailingWS[optional, defaults to true] true to kill any traling whitespace in appended string
Returns
updated path string
const char* GetFilePath ( void  ) const
inline

Get the file path string

Returns
the file path string
bool IsValid ( void  ) const
inline

Determine if the path is valid

Returns
true if valid else false

Member Data Documentation

WarningBool _isValid
protected

true if path is valid else false

char _pathStr[MAX_PATH_LENGTH+1u]
protected

full path plus terminator

const char DIR_SEPARATOR
static

directory separator char


The documentation for this class was generated from the following file: