1 /* Copyright (C) 2003 Vladimir Roubtsov. All rights reserved. 2 * 3 * This program and the accompanying materials are made available under 4 * the terms of the Common Public License v1.0 which accompanies this distribution, 5 * and is available at http://www.eclipse.org/legal/cpl-v10.html 6 * 7 * $Id: AbstractClassDefVisitor.java,v 1.1.1.1 2004/05/09 16:57:44 vlad_r Exp $ 8 */ 9 package com.vladium.jcd.cls; 10 11 // ---------------------------------------------------------------------------- 12 /** 13 * @author (C) 2001, Vlad Roubtsov 14 */ 15 public 16 abstract class AbstractClassDefVisitor implements IClassDefVisitor 17 { 18 // public: ................................................................ 19 20 // IClassDefVisitor: 21 visit(final ClassDef cls, final Object ctx)22 public Object visit (final ClassDef cls, final Object ctx) 23 { 24 visit (cls.getConstants (), ctx); 25 visit (cls.getInterfaces (), ctx); 26 visit (cls.getFields (), ctx); 27 visit (cls.getMethods (), ctx); 28 visit (cls.getAttributes (), ctx); 29 30 return ctx; 31 } 32 visit(final IAttributeCollection attributes, final Object ctx)33 public Object visit (final IAttributeCollection attributes, final Object ctx) 34 { 35 return ctx; 36 } 37 visit(final IConstantCollection constants, final Object ctx)38 public Object visit (final IConstantCollection constants, final Object ctx) 39 { 40 return ctx; 41 } 42 visit(final IFieldCollection fields, final Object ctx)43 public Object visit (final IFieldCollection fields, final Object ctx) 44 { 45 return ctx; 46 } 47 visit(final IInterfaceCollection interfaces, final Object ctx)48 public Object visit (final IInterfaceCollection interfaces, final Object ctx) 49 { 50 return ctx; 51 } 52 visit(final IMethodCollection methods, final Object ctx)53 public Object visit (final IMethodCollection methods, final Object ctx) 54 { 55 return ctx; 56 } 57 58 // protected: ............................................................. 59 60 // package: ............................................................... 61 62 // private: ............................................................... 63 64 } // end of class 65 // ---------------------------------------------------------------------------- 66