001 /* 002 Copyright (C) 2001-2003 Renaud Pawlak, Lionel Seinturier. 003 004 This program is free software; you can redistribute it and/or modify 005 it under the terms of the GNU Lesser General Public License as 006 published by the Free Software Foundation; either version 2 of the 007 License, or (at your option) any later version. 008 009 This program is distributed in the hope that it will be useful, but 010 WITHOUT ANY WARRANTY; without even the implied warranty of 011 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 012 Lesser General Public License for more details. 013 014 You should have received a copy of the GNU Lesser General Public 015 License along with this program; if not, write to the Free Software 016 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 017 USA */ 018 019 package org.objectweb.jac.core; 020 021 /** 022 * <code>WrappeeTranslator</code> translates a regular java class into 023 * a wrappable one. 024 * 025 * <p>This translation is usually done at <i>load time</i>. After the 026 * translation, the class subclasses the <code>JacObject</code> class. 027 * 028 * @author Renaud Pawlak 029 * @author Lionel Seinturier 030 * @author Fabrice Legond-Aubry 031 */ 032 033 public interface WrappeeTranslator { 034 /** 035 * Translate a class 036 * @param name the name of the class to translate 037 * @return the byte code or null i the class was not translated 038 */ 039 byte[] translateClass (String name) throws Exception; 040 041 042 /** 043 * Computes RTTI info for a class and gets its bytecode 044 * @param aClass name of the class analyze 045 * @return bytecode of the class 046 */ 047 byte[] fillClassRTTI(String aClass) throws Exception; 048 }