Package components

Examples of components.ClassInfo


  // first the entry for ourselves.
  ivec[ 0 ] = new InterfaceVector( me, c, null );
  // now all the others (if any)
  for( int i = 0; i< ntotal; i++){
      ClassInfo intf = (ClassInfo)c.allInterfaces.elementAt( i );
      ivec[ i+1 ] = new InterfaceVector( me, intf, null );
  }
  return imf.newInterfaceMethodTable( me, imtName, ivec );
    }
View Full Code Here


  return imf.newInterfaceMethodTable( me, imtName, ivec );
    }

    public static InterfaceMethodTable
    generateInterfaceTable( ClassClass cc, InterfaceMethodFactory imf ){
  ClassInfo c = cc.ci;
  if ( c.allInterfaces == null )
      c.findAllInterfaces();
  String imtName = c.getGenericNativeName() + "_intfMethodtable";
  ClassInfo sup = c.superClassInfo;
  int ntotal = c.allInterfaces.size();
  int nsuper = 0;

  if ( (c.access&Const.ACC_INTERFACE) != 0 ){
      return generateTablesForInterface( c, imtName, imf );
  }
  if ( sup != null ){
      nsuper = sup.allInterfaces.size();
      if ( nsuper == ntotal ){
    // use other class's tables entirely.
    // we have nothing further to add.
    return sup.vmClass.inf;
      }
  }
  //
  // generate the offset tables, or symbolic references
  // to them.
  InterfaceVector vec[] = new InterfaceVector[ ntotal ];
  if ( nsuper != 0 ){
      // borrow some from superclass. They are the same.
      System.arraycopy( sup.vmClass.inf.iv, 0, vec, 0, nsuper );
  }

  // compute the rest of the thing ourselves.
  for( int i = nsuper; i < ntotal; i++ ){
      ClassInfo intf = (ClassInfo)c.allInterfaces.elementAt( i );
      MethodConstant mtab[] = intf.refMethodtable;
      int nmethods = mtab.length;
      short ivec[] = new short[ nmethods ];
      for( int j = 0; j < nmethods; j++ ){
    MethodInfo target = mtab[j].find();
View Full Code Here

  return new EVMClass( c );
    }

    private static boolean
    setType( String name, int value ){
  ClassInfo ci = ClassInfo.lookupClass( name );
  ClassClass cc;
  if ( (ci == null) || ( ( cc = ci.vmClass ) == null) ){
      return false;
  }
  ((EVMClass)cc).typeCode = value;
View Full Code Here

TOP

Related Classes of components.ClassInfo

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.