モジュール java.base

インタフェースModuleResolutionAttribute

すべてのスーパー・インタフェース:
AttributePREVIEW<ModuleResolutionAttributePREVIEW>, ClassElementPREVIEW, ClassFileElementPREVIEW, WritableElementPREVIEW<ModuleResolutionAttributePREVIEW>

public sealed interface ModuleResolutionAttribute extends AttributePREVIEW<ModuleResolutionAttributePREVIEW>, ClassElementPREVIEW
ModuleResolutionAttributeは、JavaプラットフォームのプレビューAPIです。
プレビュー機能が有効な場合のみ、プログラムでModuleResolutionAttributeを使用できます。
プレビュー機能は、今後のリリースで削除するか、Javaプラットフォームの永続機能にアップグレードすることができます。
モジュール記述子を表すクラスに指定できるModuleResolution属性をモデル化します。 これは、モジュールの解決メタデータを取得するJDK固有の*属性です。 ClassModelPREVIEWの要素をトラバースするときに、ClassElementPREVIEWとして提供されます。

ModuleResolution属性の指定は次のとおりです。

 
  ModuleResolution_attribute {
    u2 attribute_name_index;    // "ModuleResolution"
    u4 attribute_length;        // 2
    u2 resolution_flags;

  The value of the resolution_flags item is a mask of flags used to denote
  properties of module resolution. The flags are as follows:

   // Optional
   0x0001 (DO_NOT_RESOLVE_BY_DEFAULT)

   // At most one of:
   0x0002 (WARN_DEPRECATED)
   0x0004 (WARN_DEPRECATED_FOR_REMOVAL)
   0x0008 (WARN_INCUBATING)
  }
  

この属性は、特定のロケーションにある複数のインスタンスを許可しません。 属性の後続の出現は、属性要素の作成時または変換時に優先されます。

導入されたバージョン:
22