Next: Class Attributes, Previous: Combined Constant Pool, Up: Encoding of BML in Class File Format
BML modifiers (see Modifiers) are encoded in suitable attributes
using binary JVM access_flags and BML_flags fields. The
bit values of BML_flags and their summary meaning is given in the
following table:
BML_SPEC_PUBLIC = 0x00000001ACC_PUBLIC JVM flag
BML_SPEC_PROTECTED = 0x00000004ACC_PROTECTED JVM flag
BML_NON_NULL = 0x00000020null
BML_NULLABLE = 0x00000040null
BML_PURE = 0x00000080BML_HELPER = 0x00000100BML_PEER = 0x00000400BML_REP = 0x00000800BML_READONLY = 0x00001000BML_ELEM_PEER = 0x00002000BML_ELEM_READONLY = 0x00002000Note that for a given feature (field, method result, method's
parameter, local variable etc.)
at most one of SPEC_PUBLIC, SPEC_PROTECTED can be set
(when applicable),
at most
one of BML_NON_NULL and BML_NULLABLE (when applicable),
at most
one of BML_PEER, BML_REP, BML_READONLY (when applicable),
and at most one of BML_ELEM_PEER and BML_ELEM_READONLY
(when applicable). Further, BML_ELEM_PEER and
BML_ELEM_READONLY can only be set when one of BML_PEER,
BML_REP or BML_READONLY is set, and the feature is of
type array.