private DbOOAdt toAdt(Type type) throws DbException {
    DbOOAdt adt = null;

    if (type instanceof BasicType) {
      BasicType basicType = (BasicType) type;
      adt = toBasicAdt(basicType);
    } else if (type instanceof ObjectType) {
      ObjectType ot = (ObjectType) type;
      String classname = ot.getClassName();
      adt = toAdt(classname, ot);
    } else if (type instanceof ArrayType) {
      ArrayType at = (ArrayType) type;
      adt = toAdt(at.getBasicType());
    } else {
      // other cases?
    } // end if

    return adt;
  }
 /** Creates a new instance. */
 public UninitializedObjectType(ObjectType t) {
   super(T_UNKNOWN, "<UNINITIALIZED OBJECT OF TYPE '" + t.getClassName() + "'>");
   initialized = t;
 }
예제 #3
0
 /**
  * Add a new Class reference to the ConstantPool for a given type.
  *
  * @param type Class to add
  * @return index of entry
  */
 public int addClass(ObjectType type) {
   return addClass(type.getClassName());
 }