void write(Environment env,DataOutputStream out,ConstantPool tab) throws IOException {
  if (num instanceof Integer) {
    out.writeByte(CONSTANT_INTEGER);
    out.writeInt(num.intValue());
  }
 else   if (num instanceof Long) {
    out.writeByte(CONSTANT_LONG);
    out.writeLong(num.longValue());
  }
 else   if (num instanceof Float) {
    out.writeByte(CONSTANT_FLOAT);
    out.writeFloat(num.floatValue());
  }
 else   if (num instanceof Double) {
    out.writeByte(CONSTANT_DOUBLE);
    out.writeDouble(num.doubleValue());
  }
}

void write ( Environment env , DataOutputStream out , ConstantPool tab ) throws IOException { if ( num instanceof Integer ) { out . writeByte ( CONSTANT_INTEGER ) ; out . writeInt ( num . intValue ( ) ) ; } else if ( num instanceof Long ) { out . writeByte ( CONSTANT_LONG ) ; out . writeLong ( num . longValue ( ) ) ; } else if ( num instanceof Float ) { out . writeByte ( CONSTANT_FLOAT ) ; out . writeFloat ( num . floatValue ( ) ) ; } else if ( num instanceof Double ) { out . writeByte ( CONSTANT_DOUBLE ) ; out . writeDouble ( num . doubleValue ( ) ) ; } }
write the constant to the output stream
