Source for gnu.gcj.runtime.Reflect

   1: /* Copyright (C) 2006  Free Software Foundation
   2: 
   3:    This file is part of libgcj.
   4: 
   5: This software is copyrighted work licensed under the terms of the
   6: Libgcj License.  Please consult the file "LIBGCJ_LICENSE" for
   7: details.  */
   8: 
   9: 
  10: package gnu.gcj.runtime;
  11: 
  12: import java.lang.reflect.Constructor;
  13: 
  14: public class Reflect
  15: {
  16:   /**
  17:    * Allocate an object whose class is the indicated class, using the
  18:    * given constructor.  Unlike {@link Constructor.newInstance}, the
  19:    * constructor need not be declared in the indicated class -- it
  20:    * can be a constructor from any superclass.  Only a no-argument
  21:    * constructor is allowed.
  22:    */
  23:   public static native Object allocateObject(Class klass,
  24:                          Constructor constructor);
  25: }