Panda3D
 All Classes Functions Variables Enumerations
xFileNode.I
00001 // Filename: xFileNode.I
00002 // Created by:  drose (03Oct04)
00003 //
00004 ////////////////////////////////////////////////////////////////////
00005 //
00006 // PANDA 3D SOFTWARE
00007 // Copyright (c) Carnegie Mellon University.  All rights reserved.
00008 //
00009 // All use of this software is subject to the terms of the revised BSD
00010 // license.  You should have received a copy of this license along
00011 // with this source code in a file named "LICENSE."
00012 //
00013 ////////////////////////////////////////////////////////////////////
00014 
00015 
00016 ////////////////////////////////////////////////////////////////////
00017 //     Function: XFileNode::get_num_children
00018 //       Access: Public
00019 //  Description: 
00020 ////////////////////////////////////////////////////////////////////
00021 INLINE XFile *XFileNode::
00022 get_x_file() const {
00023   return _x_file;
00024 }
00025 
00026 ////////////////////////////////////////////////////////////////////
00027 //     Function: XFileNode::get_num_children
00028 //       Access: Public
00029 //  Description: Returns the list of children of this node.  This
00030 //               list includes templates as well as data objects.
00031 ////////////////////////////////////////////////////////////////////
00032 INLINE int XFileNode::
00033 get_num_children() const {
00034   return _children.size();
00035 }
00036 
00037 ////////////////////////////////////////////////////////////////////
00038 //     Function: XFileNode::get_child
00039 //       Access: Public
00040 //  Description: Returns the nth child of this node.  This list
00041 //               includes templates as well as data objects.
00042 ////////////////////////////////////////////////////////////////////
00043 INLINE XFileNode *XFileNode::
00044 get_child(int n) const {
00045   nassertr(n >= 0 && n < (int)_children.size(), NULL);
00046   return _children[n];
00047 }
00048 
00049 ////////////////////////////////////////////////////////////////////
00050 //     Function: XFileNode::get_num_objects
00051 //       Access: Public
00052 //  Description: Returns the list of child objects of this node.  This
00053 //               list does not include template definitions; it is
00054 //               strictly the list of children that are also data
00055 //               objects (instances of templates).
00056 ////////////////////////////////////////////////////////////////////
00057 INLINE int XFileNode::
00058 get_num_objects() const {
00059   return _objects.size();
00060 }
00061 
00062 ////////////////////////////////////////////////////////////////////
00063 //     Function: XFileNode::get_object
00064 //       Access: Public
00065 //  Description: Returns the nth child object of this node.  This
00066 //               list does not include template definitions; it is
00067 //               strictly the list of children that are also data
00068 //               objects (instances of templates).
00069 ////////////////////////////////////////////////////////////////////
00070 INLINE XFileDataNode *XFileNode::
00071 get_object(int n) const {
00072   nassertr(n >= 0 && n < (int)_objects.size(), NULL);
00073   return _objects[n];
00074 }
 All Classes Functions Variables Enumerations