Synopsis - Cross-Reference
File: /Synopsis/Parsers/IDL/idlvisitor.h1// -*- c++ -*- 2// Package : omniidl 3// idlvisitor.h Created on: 1999/10/11 4// Author : Duncan Grisby (dpg1) 5// 6// Copyright (C) 1999 AT&T Laboratories Cambridge 7// 8// This file is part of omniidl. 9// 10// omniidl is free software; you can redistribute it and/or modify it 11// under the terms of the GNU General Public License as published by 12// the Free Software Foundation; either version 2 of the License, or 13// (at your option) any later version. 14// 15// This program is distributed in the hope that it will be useful, 16// but WITHOUT ANY WARRANTY; without even the implied warranty of 17// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 18// General Public License for more details. 19// 20// You should have received a copy of the GNU General Public License 21// along with this program; if not, write to the Free Software 22// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 23// 02111-1307, USA. 24// 25// Description: 26// 27// Visitor base class 28 29// $Id: idlvisitor.h,v 1.6.2.1 2003/03/23 21:01:43 dgrisby Exp $ 30// $Log: idlvisitor.h,v $ 31// Revision 1.6.2.1 2003/03/23 21:01:43 dgrisby 32// Start of omniORB 4.1.x development branch. 33// 34// Revision 1.3.2.2 2000/11/01 12:45:57 dpg1 35// Update to CORBA 2.4 specification. 36// 37// Revision 1.3.2.1 2000/07/17 10:36:06 sll 38// Merged from omni3_develop the diff between omni3_0_0_pre3 and omni3_0_0. 39// 40// Revision 1.4 2000/07/13 15:25:52 dpg1 41// Merge from omni3_develop for 3.0 release. 42// 43// Revision 1.1 1999/10/27 14:05:52 dpg1 44// *** empty log message *** 45// 46 47#ifndef _idlvisitor_h_ 48#define _idlvisitor_h_ 49 50// 51// Visitor for AST 52// 53 54class AST; 55class Module; 56class Interface; 57class Forward; 58class Const; 59class ArraySize; 60class TypedefDeclarator; 61class Typedef; 62class Declarator; 63class Member; 64class Struct; 65class StructForward; 66class Exception; 67class CaseLabel; 68class UnionCase; 69class Union; 70class UnionForward; 71class Enumerator; 72class Enum; 73class Attribute; 74class Parameter; 75class Operation; 76class Native; 77class StateMember; 78class Factory; 79class ValueForward; 80class ValueBox; 81class ValueInheritSpec; 82class ValueAbs; 83class Value; 84 85 86class AstVisitor { 87public: 88 AstVisitor() {} 89 virtual ~AstVisitor() {} 90 91 virtual void visitAST (AST*) { } 92 virtual void visitModule (Module*) { } 93 virtual void visitInterface (Interface*) { } 94 virtual void visitForward (Forward*) { } 95 virtual void visitConst (Const*) { } 96 virtual void visitDeclarator (Declarator*) { } 97 virtual void visitTypedef (Typedef*) { } 98 virtual void visitMember (Member*) { } 99 virtual void visitStruct (Struct*) { } 100 virtual void visitStructForward (StructForward*) { } 101 virtual void visitException (Exception*) { } 102 virtual void visitCaseLabel (CaseLabel*) { } 103 virtual void visitUnionCase (UnionCase*) { } 104 virtual void visitUnion (Union*) { } 105 virtual void visitUnionForward (UnionForward*) { } 106 virtual void visitEnumerator (Enumerator*) { } 107 virtual void visitEnum (Enum*) { } 108 virtual void visitAttribute (Attribute*) { } 109 virtual void visitParameter (Parameter*) { } 110 virtual void visitOperation (Operation*) { } 111 virtual void visitNative (Native*) { } 112 virtual void visitStateMember (StateMember*) { } 113 virtual void visitFactory (Factory*) { } 114 virtual void visitValueForward (ValueForward*) { } 115 virtual void visitValueBox (ValueBox*) { } 116 virtual void visitValueAbs (ValueAbs*) { } 117 virtual void visitValue (Value*) { } 118}; 119 120 121// 122// Visitor for types 123// 124 125class BaseType; 126class StringType; 127class WStringType; 128class SequenceType; 129class FixedType; 130class DeclaredType; 131 132class TypeVisitor{ 133public: 134 TypeVisitor() {} 135 virtual ~TypeVisitor() {} 136 137 virtual void visitBaseType (BaseType*) { } 138 virtual void visitStringType (StringType*) { } 139 virtual void visitWStringType (WStringType*) { } 140 virtual void visitSequenceType(SequenceType*) { } 141 virtual void visitFixedType (FixedType*) { } 142 virtual void visitDeclaredType(DeclaredType*) { } 143}; 144 145 146#endif // _idlvisitor_h_