cppNamespace.h 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. // Filename: cppNamespace.h
  2. // Created by: drose (16Nov99)
  3. //
  4. ////////////////////////////////////////////////////////////////////
  5. //
  6. // PANDA 3D SOFTWARE
  7. // Copyright (c) 2001, Disney Enterprises, Inc. All rights reserved
  8. //
  9. // All use of this software is subject to the terms of the Panda 3d
  10. // Software license. You should have received a copy of this license
  11. // along with this source code; you will also find a current copy of
  12. // the license at http://www.panda3d.org/license.txt .
  13. //
  14. // To contact the maintainers of this program write to
  15. // [email protected] .
  16. //
  17. ////////////////////////////////////////////////////////////////////
  18. #ifndef CPPNAMESPACE_H
  19. #define CPPNAMESPACE_H
  20. #include <dtoolbase.h>
  21. #include "cppDeclaration.h"
  22. class CPPIdentifier;
  23. class CPPScope;
  24. ///////////////////////////////////////////////////////////////////
  25. // Class : CPPNamespace
  26. // Description :
  27. ////////////////////////////////////////////////////////////////////
  28. class CPPNamespace : public CPPDeclaration {
  29. public:
  30. CPPNamespace(CPPIdentifier *ident, CPPScope *scope,
  31. const CPPFile &file);
  32. string get_simple_name() const;
  33. string get_local_name(CPPScope *scope = NULL) const;
  34. string get_fully_scoped_name() const;
  35. CPPScope *get_scope() const;
  36. virtual void output(ostream &out, int indent_level, CPPScope *scope,
  37. bool complete) const;
  38. virtual SubType get_subtype() const;
  39. virtual CPPNamespace *as_namespace();
  40. private:
  41. CPPIdentifier *_ident;
  42. CPPScope *_scope;
  43. };
  44. #endif