VR-Forces 4.10 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Classes | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
makVrv::DtPagePath Class Reference

A page path is the location of a page based upon its parents. More...

Inheritance diagram for makVrv::DtPagePath:
Inheritance graph
[legend]

Classes

struct  PagePathBuilder
 Internal class used to ensure that it is not possible to incorrectly build a menu path. More...
 

Public Member Functions

 DtPagePath ()
 Default CTOR. More...
 
 DtPagePath (const PagePathBuilder &builder)
 CTOR. More...
 
 DtPagePath (const DtPagePath &copy)
 Copy CTOR. More...
 
const std::string & path () const
 Get the current path. More...
 
DtPagePath collectionPart () const
 Get the path to the parent of this path. More...
 
std::string name () const
 Calculate the name of the this menu path. More...
 
bool isEmpty () const
 Is the path empty? More...
 
bool isCollection () const
 Is this item a main menu path? More...
 
bool isPage () const
 Is the path a menu (not an item)? More...
 
bool isChildOf (const DtPagePath &parent) const
 Is this path its direct parent? More...
 
bool isSiblingOf (const DtPagePath &sibling) const
 Does this path have the same parent as the given path? More...
 
bool operator== (const DtPagePath &other) const
 Equal comparison operator. More...
 
bool operator< (const DtPagePath &other) const
 Less than comparison operator. More...
 
bool operator!= (const DtPagePath &other) const
 Not equal comparison operator. More...
 

Static Public Member Functions

static DtPagePath empty ()
 Create an empty menu path. More...
 
static DtPagePath root ()
 Create an empty root menu path. More...
 
static PagePathBuilder collection (const std::string &name)
 Start a main menu. More...
 

Protected Member Functions

template<class Archive >
void _serialize (Archive &ar, const unsigned int version)
 Serialize this class. More...
 
 DtPagePath (const std::string &path)
 Protected CTOR. More...
 

Protected Attributes

std::string myPath
 Internal path. More...
 

Detailed Description

A page path is the location of a page based upon its parents.

A page path usually only consists of a Collection class name and a Page class name.

Constructor & Destructor Documentation

makVrv::DtPagePath::DtPagePath ( )

Default CTOR.

Needed for serialization.

makVrv::DtPagePath::DtPagePath ( const PagePathBuilder builder)

CTOR.

makVrv::DtPagePath::DtPagePath ( const DtPagePath copy)

Copy CTOR.

makVrv::DtPagePath::DtPagePath ( const std::string &  path)
protected

Protected CTOR.

Use the static PagePage function to start a path.

Member Function Documentation

static DtPagePath makVrv::DtPagePath::empty ( )
static

Create an empty menu path.

static DtPagePath makVrv::DtPagePath::root ( )
static

Create an empty root menu path.

static PagePathBuilder makVrv::DtPagePath::collection ( const std::string &  name)
static

Start a main menu.

const std::string& makVrv::DtPagePath::path ( ) const
inline

Get the current path.

DtPagePath makVrv::DtPagePath::collectionPart ( ) const

Get the path to the parent of this path.

If this path is the top level an empty path is returned.

std::string makVrv::DtPagePath::name ( ) const

Calculate the name of the this menu path.

This is either the item name or the menu name.

bool makVrv::DtPagePath::isEmpty ( ) const

Is the path empty?

bool makVrv::DtPagePath::isCollection ( ) const

Is this item a main menu path?

bool makVrv::DtPagePath::isPage ( ) const

Is the path a menu (not an item)?

bool makVrv::DtPagePath::isChildOf ( const DtPagePath parent) const

Is this path its direct parent?

bool makVrv::DtPagePath::isSiblingOf ( const DtPagePath sibling) const

Does this path have the same parent as the given path?

bool makVrv::DtPagePath::operator== ( const DtPagePath other) const

Equal comparison operator.

bool makVrv::DtPagePath::operator< ( const DtPagePath other) const

Less than comparison operator.

bool makVrv::DtPagePath::operator!= ( const DtPagePath other) const

Not equal comparison operator.

template<class Archive >
void makVrv::DtPagePath::_serialize ( Archive &  ar,
const unsigned int  version 
)
inlineprotected

Serialize this class.

References DT_SERIALIZE_MEMBER.

Member Data Documentation

std::string makVrv::DtPagePath::myPath
protected

Internal path.


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

Document ID: Generated on Tue Sep 21 17:42:52 EDT 2021 from SVN revision 234861
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)