Class Requires


  • public class Requires
    extends Object
    Represents a requires entry in the Module attribute.
    • Constructor Detail

      • Requires

        public Requires​(ConstPool constPool,
                        int requiresIndex,
                        int requiresFlags,
                        int requiresVersionIndex)
        Creates a requires entry from its raw constant pool indexes.
        Parameters:
        constPool - the pool the indexes refer into
        requiresIndex - the module entry index of the required module
        requiresFlags - the requires access flags
        requiresVersionIndex - the UTF-8 index of the required version, or 0 if absent
    • Method Detail

      • getRequiresIndex

        public int getRequiresIndex()
        Returns:
        the requires index
      • getRequiresFlags

        public int getRequiresFlags()
        Returns:
        the requires flags
      • getRequiresVersionIndex

        public int getRequiresVersionIndex()
        Returns:
        the requires version index