Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

panda/src/egg/eggExternalReference.cxx

Go to the documentation of this file.
00001 // Filename: eggExternalReference.cxx
00002 // Created by:  drose (11Feb99)
00003 //
00004 ////////////////////////////////////////////////////////////////////
00005 //
00006 // PANDA 3D SOFTWARE
00007 // Copyright (c) 2001, Disney Enterprises, Inc.  All rights reserved
00008 //
00009 // All use of this software is subject to the terms of the Panda 3d
00010 // Software license.  You should have received a copy of this license
00011 // along with this source code; you will also find a current copy of
00012 // the license at http://www.panda3d.org/license.txt .
00013 //
00014 // To contact the maintainers of this program write to
00015 // panda3d@yahoogroups.com .
00016 //
00017 ////////////////////////////////////////////////////////////////////
00018 
00019 #include "eggExternalReference.h"
00020 #include "eggMiscFuncs.h"
00021 
00022 #include <indent.h>
00023 #include <string_utils.h>
00024 
00025 TypeHandle EggExternalReference::_type_handle;
00026 
00027 
00028 ////////////////////////////////////////////////////////////////////
00029 //     Function: EggExternalReference::Constructor
00030 //       Access: Public
00031 //  Description:
00032 ////////////////////////////////////////////////////////////////////
00033 EggExternalReference::
00034 EggExternalReference(const string &node_name, const string &filename)
00035   : EggFilenameNode(node_name, filename) {
00036 }
00037 
00038 ////////////////////////////////////////////////////////////////////
00039 //     Function: EggExternalReference::Copy constructor
00040 //       Access: Public
00041 //  Description:
00042 ////////////////////////////////////////////////////////////////////
00043 EggExternalReference::
00044 EggExternalReference(const EggExternalReference &copy)
00045   : EggFilenameNode(copy) {
00046 }
00047 
00048 ////////////////////////////////////////////////////////////////////
00049 //     Function: EggExternalReference::Copy assignment operator
00050 //       Access: Public
00051 //  Description:
00052 ////////////////////////////////////////////////////////////////////
00053 EggExternalReference &EggExternalReference::
00054 operator = (const EggExternalReference &copy) {
00055   EggFilenameNode::operator = (copy);
00056   return *this;
00057 }
00058 
00059 ////////////////////////////////////////////////////////////////////
00060 //     Function: EggExternalReference::write
00061 //       Access: Public, Virtual
00062 //  Description: Writes the reference to the indicated output
00063 //               stream in Egg format.
00064 ////////////////////////////////////////////////////////////////////
00065 void EggExternalReference::
00066 write(ostream &out, int indent_level) const {
00067   write_header(out, indent_level, "<File>");
00068   enquote_string(out, get_filename(), indent_level + 2) << "\n";
00069   indent(out, indent_level) << "}\n";
00070 }
00071 
00072 ////////////////////////////////////////////////////////////////////
00073 //     Function: EggExternalReference::get_default_extension
00074 //       Access: Public, Virtual
00075 //  Description: Returns the default extension for this filename type.
00076 ////////////////////////////////////////////////////////////////////
00077 string EggExternalReference::
00078 get_default_extension() const {
00079   return string("egg");
00080 }

Generated on Fri May 2 00:37:33 2003 for Panda by doxygen1.3