00001 /*---------------------------------------------------------------------------*\ 00002 * OpenSG * 00003 * * 00004 * * 00005 * Copyright (C) 2000-2002 by the OpenSG Forum * 00006 * * 00007 * www.opensg.org * 00008 * * 00009 * contact: dirk@opensg.org, gerrit.voss@vossg.org, jbehr@zgdv.de * 00010 * * 00011 \*---------------------------------------------------------------------------*/ 00012 /*---------------------------------------------------------------------------*\ 00013 * License * 00014 * * 00015 * This library is free software; you can redistribute it and/or modify it * 00016 * under the terms of the GNU Library General Public License as published * 00017 * by the Free Software Foundation, version 2. * 00018 * * 00019 * This library is distributed in the hope that it will be useful, but * 00020 * WITHOUT ANY WARRANTY; without even the implied warranty of * 00021 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * 00022 * Library General Public License for more details. * 00023 * * 00024 * You should have received a copy of the GNU Library General Public * 00025 * License along with this library; if not, write to the Free Software * 00026 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * 00027 * * 00028 \*---------------------------------------------------------------------------*/ 00029 /*---------------------------------------------------------------------------*\ 00030 * Changes * 00031 * * 00032 * * 00033 * * 00034 * * 00035 * * 00036 * * 00037 \*---------------------------------------------------------------------------*/ 00038 00039 #ifndef _OSGCNODEPTRIMPL_H_ 00040 #define _OSGCNODEPTRIMPL_H_ 00041 #ifdef __sgi 00042 #pragma once 00043 #endif 00044 00045 #ifdef OSG_DOC_FILES_IN_MODULE 00046 00049 #endif 00050 00051 #include <OSGBaseTypes.h> 00052 #include <OSGSystemDef.h> 00053 #include <OSGAttachmentContainerPtr.h> 00054 00055 OSG_BEGIN_NAMESPACE 00056 00057 class Node; 00058 class NodeCore; 00059 00060 //--------------------------------------------------------------------------- 00061 // Class 00062 //--------------------------------------------------------------------------- 00063 00064 #ifdef __sgi 00065 #pragma set woff 1375,1424 00066 #endif 00067 00068 #ifdef OSG_LINUX_ICC 00069 #pragma warning( disable : 444 ) 00070 #endif 00071 00075 class OSG_SYSTEMLIB_DLLMAPPING CNodePtr : public AttachmentContainerPtr 00076 { 00077 /*========================== PUBLIC =================================*/ 00078 00079 public: 00080 00081 typedef NodeCore StoredObjectType; 00082 typedef CNodePtr ObjectType; 00083 00084 typedef AttachmentContainerPtr Inherited; 00085 00086 /*---------------------------------------------------------------------*/ 00090 CNodePtr( void ); 00091 CNodePtr(const CNodePtr &source); 00092 CNodePtr(const NullFieldContainerPtr &source); 00093 explicit CNodePtr(const NodePtr &source); 00094 00096 /*---------------------------------------------------------------------*/ 00100 ~CNodePtr(void); 00101 00103 /*---------------------------------------------------------------------*/ 00107 Node *getNode(void); 00108 Node *getNode(void) const; 00109 00111 /*---------------------------------------------------------------------*/ 00115 NodeCore *operator->(void); 00116 NodeCore *operator->(void) const; 00117 00118 NodeCore &operator *(void); 00119 NodeCore &operator *(void) const; 00120 00121 NodeCore *getCPtr (void); 00122 NodeCore *getCPtr (void) const; 00123 00125 /*---------------------------------------------------------------------*/ 00129 void operator =(const NodePtr &source); 00130 void operator =(const CNodePtr &source); 00131 void operator =(const NullFieldContainerPtr &source); 00132 00134 /*---------------------------------------------------------------------*/ 00140 explicit CNodePtr(const Node &source); 00141 explicit CNodePtr(const Node *source); 00142 00144 /*========================= PROTECTED ===============================*/ 00145 00146 protected: 00147 00148 /*---------------------------------------------------------------------*/ 00152 CNodePtr(const Node *source, 00153 const UInt16 uiSize, 00154 const UInt16 uiParentPos); 00155 00157 /*========================== PRIVATE ================================*/ 00158 00159 private: 00160 00161 friend class FieldContainer; 00162 }; 00163 00164 #ifdef OSG_LINUX_ICC 00165 #pragma warning( default : 444 ) 00166 #endif 00167 00168 #ifdef __sgi 00169 #pragma reset woff 1375,1424 00170 #endif 00171 00175 OSG_SYSTEMLIB_DLLMAPPING 00176 std::ostream &operator <<( std::ostream &os, 00177 const CNodePtr &fc); 00178 00179 OSG_END_NAMESPACE 00180 00181 #define OSGCNODEPTR_HEADER_CVSID "@(#)$Id: $" 00182 00183 #endif /* _OSGCNODEPTRIMPL_H_ */
1.5.5