XnNode.h
Go to the documentation of this file.
/****************************************************************************
* *
* OpenNI 1.x Alpha *
* Copyright (C) 2011 PrimeSense Ltd. *
* *
* This file is part of OpenNI. *
* *
* OpenNI is free software: you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License as published *
* by the Free Software Foundation, either version 3 of the License, or *
* (at your option) any later version. *
* *
* OpenNI is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public License *
* along with OpenNI. If not, see <http://www.gnu.org/licenses/>. *
* *
****************************************************************************/
#ifndef _XN_NODE_H_
#define _XN_NODE_H_
//---------------------------------------------------------------------------
// Includes
//---------------------------------------------------------------------------
#include <XnDataTypes.h>
#include <XnBaseNode.h>
//---------------------------------------------------------------------------
// Types
//---------------------------------------------------------------------------
class XnNode : protected XnBaseNode
{
public:
static XnNode *Allocate() { return (XnNode*)xnAllocateBaseNode(); }
static void Deallocate(XnNode *pNode) { xnDeallocateBaseNode((XnBaseNode*)pNode); }
XnNode() { m_pNext = NULL; m_pPrevious = NULL; m_Data = NULL; }
XnNode*& Next() {return (XnNode*&)m_pNext;}
const XnNode* const Next() const {return (const XnNode*)m_pNext;}
XnNode*& Previous() {return (XnNode*&)m_pPrevious;}
const XnNode* const Previous() const {return (const XnNode*)m_pPrevious;}
XnValue& Data() {return m_Data;}
const XnValue& Data() const {return m_Data;}
};
#endif // _XN_NODE_H_
XnBaseNode.h
xnDeallocateBaseNode
XN_C_API void XN_C_DECL xnDeallocateBaseNode(XnBaseNode *pNode)
xnAllocateBaseNode
XN_C_API XnBaseNode *XN_C_DECL xnAllocateBaseNode()
XnDataTypes.h
XnValue
void * XnValue
Definition XnDataTypes.h:36
XnNode::Next
const XnNode *const Next() const
Definition XnNode.h:55
XnNode::XnNode
XnNode()
Definition XnNode.h:46
XnNode::Deallocate
static void Deallocate(XnNode *pNode)
Definition XnNode.h:41
XnNode::Previous
XnNode *& Previous()
Definition XnNode.h:60
XnNode::Allocate
static XnNode * Allocate()
Definition XnNode.h:40
XnNode::Previous
const XnNode *const Previous() const
Definition XnNode.h:64
XnNode::Data
XnValue & Data()
Definition XnNode.h:69
XnNode::Data
const XnValue & Data() const
Definition XnNode.h:73
XnNode::Next
XnNode *& Next()
Definition XnNode.h:51
XnBaseNode
Definition XnBaseNode.h:36
XnBaseNode::m_pNext
XnBaseNode * m_pNext
Definition XnBaseNode.h:38
XnBaseNode::m_pPrevious
XnBaseNode * m_pPrevious
Definition XnBaseNode.h:40
XnBaseNode::m_Data
XnValue m_Data
Definition XnBaseNode.h:42