- すべてのスーパー・インタフェース:
AttributePREVIEW<ModuleHashesAttributePREVIEW>
,ClassElementPREVIEW
,ClassFileElementPREVIEW
,WritableElementPREVIEW<ModuleHashesAttributePREVIEW>
public sealed interface ModuleHashesAttribute extends AttributePREVIEW<ModuleHashesAttributePREVIEW>, ClassElementPREVIEW
ModuleHashesAttribute
は、JavaプラットフォームのプレビューAPIです。
プレビュー機能は、今後のリリースで削除するか、Javaプラットフォームの永続機能にアップグレードすることができます。
モジュール記述子を表すクラスに指定できる
ModuleHashes
属性をモデル化します。 これはJDK固有の属性で、一連の共通提供モジュールのハッシュを取得します。 ClassModel
PREVIEWの要素をトラバースするときに、ClassElement
PREVIEWとして提供されます。
ModuleHashes
属性の指定は次のとおりです。
ModuleHashes_attribute {
// index to CONSTANT_utf8_info structure in constant pool representing
// the string "ModuleHashes"
u2 attribute_name_index;
u4 attribute_length;
// index to CONSTANT_utf8_info structure with algorithm name
u2 algorithm_index;
// the number of entries in the hashes table
u2 hashes_count;
{ u2 module_name_index (index to CONSTANT_Module_info structure)
u2 hash_length;
u1 hash[hash_length];
} hashes[hashes_count];
}
この属性は、特定のロケーションにある複数のインスタンスを許可しません。 属性の後続の出現は、属性要素の作成時または変換時に優先されます。
- 導入されたバージョン:
- 22
-
メソッドのサマリー
修飾子と型メソッド説明ハッシュのコンピュートに使用されるアルゴリズム名を返します。hashes()
関連モジュールに関するハッシュ情報を返します。static ModuleHashesAttributePREVIEW
of
(Utf8EntryPREVIEW algorithm, ModuleHashInfoPREVIEW... hashes) ModuleHashes
属性を返します。static ModuleHashesAttributePREVIEW
ModuleHashes
属性を返します。static ModuleHashesAttributePREVIEW
of
(String algorithm, ModuleHashInfoPREVIEW... hashes) ModuleHashes
属性を返します。static ModuleHashesAttributePREVIEW
of
(String algorithm, List<ModuleHashInfoPREVIEW> hashes) ModuleHashes
属性を返します。インタフェースjava.lang.classfile.AttributePREVIEWで宣言されたメソッド
attributeMapper, attributeName
インタフェースjava.lang.classfile.WritableElementPREVIEWで宣言されたメソッド
writeTo
-
メソッドの詳細
-
algorithm
-
hashes
-
of
static ModuleHashesAttributePREVIEW of(String algorithm, List<ModuleHashInfoPREVIEW> hashes) ModuleHashes
属性を返します。- パラメータ:
algorithm
- ハッシュ・アルゴリズムhashes
- ハッシュの説明- 戻り値:
ModuleHashes
属性
-
of
static ModuleHashesAttributePREVIEW of(String algorithm, ModuleHashInfoPREVIEW... hashes) ModuleHashes
属性を返します。- パラメータ:
algorithm
- ハッシュ・アルゴリズムhashes
- ハッシュの説明- 戻り値:
ModuleHashes
属性
-
of
static ModuleHashesAttributePREVIEW of(Utf8EntryPREVIEW algorithm, List<ModuleHashInfoPREVIEW> hashes) ModuleHashes
属性を返します。- パラメータ:
algorithm
- ハッシュ・アルゴリズムhashes
- ハッシュの説明- 戻り値:
ModuleHashes
属性
-
of
static ModuleHashesAttributePREVIEW of(Utf8EntryPREVIEW algorithm, ModuleHashInfoPREVIEW... hashes) ModuleHashes
属性を返します。- パラメータ:
algorithm
- ハッシュ・アルゴリズムhashes
- ハッシュの説明- 戻り値:
ModuleHashes
属性
-
ModuleHashesAttribute
を使用できます。