< prev index next >

src/jdk.jdeps/share/classes/com/sun/tools/classfile/Module_attribute.java

Print this page




  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any
  23  * questions.
  24  */
  25 
  26 package com.sun.tools.classfile;
  27 
  28 import java.io.IOException;
  29 
  30 import com.sun.tools.classfile.ConstantPool.CONSTANT_Module_info;
  31 
  32 /**
  33  * See Jigsaw.
  34  *
  35  *  <p><b>This is NOT part of any supported API.
  36  *  If you write code that depends on this, you do so at your own risk.
  37  *  This code and its internal interfaces are subject to change or
  38  *  deletion without notice.</b>
  39  */
  40 public class Module_attribute extends Attribute {
  41     public static final int ACC_TRANSITIVE      =   0x10;
  42     public static final int ACC_STATIC_PHASE    =   0x20;
  43     public static final int ACC_OPEN            =   0x20;
  44     public static final int ACC_SYNTHETIC       = 0x1000;
  45     public static final int ACC_MANDATED        = 0x8000;
  46 
  47     Module_attribute(ClassReader cr, int name_index, int length) throws IOException {
  48         super(name_index, length);
  49 
  50         module_name = cr.readUnsignedShort();
  51         module_flags = cr.readUnsignedShort();
  52 
  53         module_version_index = cr.readUnsignedShort();
  54 
  55         requires_count = cr.readUnsignedShort();
  56         requires = new RequiresEntry[requires_count];
  57         for (int i = 0; i < requires_count; i++)
  58             requires[i] = new RequiresEntry(cr);
  59 
  60         exports_count = cr.readUnsignedShort();
  61         exports = new ExportsEntry[exports_count];
  62         for (int i = 0; i < exports_count; i++)




  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any
  23  * questions.
  24  */
  25 
  26 package com.sun.tools.classfile;
  27 
  28 import java.io.IOException;
  29 
  30 import com.sun.tools.classfile.ConstantPool.CONSTANT_Module_info;
  31 
  32 /**
  33  * See Jigsaw.
  34  *
  35  *  <p><b>This is NOT part of any supported API.
  36  *  If you write code that depends on this, you do so at your own risk.
  37  *  This code and its internal interfaces are subject to change or
  38  *  deletion without notice.</b>
  39  */
  40 public class Module_attribute extends Attribute {
  41     public static final int ACC_TRANSITIVE      =   0x20;
  42     public static final int ACC_STATIC_PHASE    =   0x40;
  43     public static final int ACC_OPEN            =   0x20;
  44     public static final int ACC_SYNTHETIC       = 0x1000;
  45     public static final int ACC_MANDATED        = 0x8000;
  46 
  47     Module_attribute(ClassReader cr, int name_index, int length) throws IOException {
  48         super(name_index, length);
  49 
  50         module_name = cr.readUnsignedShort();
  51         module_flags = cr.readUnsignedShort();
  52 
  53         module_version_index = cr.readUnsignedShort();
  54 
  55         requires_count = cr.readUnsignedShort();
  56         requires = new RequiresEntry[requires_count];
  57         for (int i = 0; i < requires_count; i++)
  58             requires[i] = new RequiresEntry(cr);
  59 
  60         exports_count = cr.readUnsignedShort();
  61         exports = new ExportsEntry[exports_count];
  62         for (int i = 0; i < exports_count; i++)


< prev index next >