リソース
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
<info>
オブジェクトに関連する補足情報を定義するには、<resource>
エンティティを使用します。
resource
エンティティのサブ要素
要素名 |
選択性 |
タイプ |
CAP と Google に関する注意事項と要件 |
<resourceDesc> |
REQUIRED |
string |
<resourceDesc> 要素の値は、リソース ファイルのタイプとコンテンツを記述するテキストです。例: map 、photo 。
|
<mimeType> |
REQUIRED |
string |
<mimeType> 要素の値は、RFC 2046 で説明されている MIME メディアタイプとサブタイプの識別子です。
|
<size> |
任意 |
float |
<size> 要素の値は、リソース ファイルのサイズをバイト単位で示す整数です。
|
<uri> |
任意 |
string |
<uri> 要素の値は、リソース ファイルへの完全な絶対 URI か、<defeUri> 要素のコンテンツの名前を指定する相対 URI です。
|
<defeUri> |
条件付き |
string |
<defeUri> 要素の値は、リソース ファイルの Base64 でエンコードされたデータ コンテンツです。URI を使用してリソースを取得できない場合は、一方向のデータリンクを介して送信されるブロードキャストなどのメッセージで、<uri> 要素とともに、またはその代わりに <defeUri> 要素を使用できます。
|
<digest> |
任意 |
string |
<digest> 要素の値は、リソース ファイルから計算されたデジタル ダイジェストを表すコードです。<digest> 要素の値を計算するには、FIPS 180-2 で説明されているセキュア ハッシュ アルゴリズム(SHA-1)を使用します。
|
例
<resource>
<resourceDesc>Image file (GIF)</resourceDesc>
<mimeType>image/gif</mimeType>
<uri>http://www.dhs.gov/dhspublic/getAdvisoryImage</uri>
</resource>
<resource>
<resourceDesc>Peta Intensitas Guncangan</resourceDesc>
<mimeType>image/jpeg</mimeType>
<uri>https://bmkg-content-inatews.storage.googleapis.com/20230410074420.mmi.jpg</uri>
</resource>
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2025-08-29 UTC。
[[["わかりやすい","easyToUnderstand","thumb-up"],["問題の解決に役立った","solvedMyProblem","thumb-up"],["その他","otherUp","thumb-up"]],[["必要な情報がない","missingTheInformationINeed","thumb-down"],["複雑すぎる / 手順が多すぎる","tooComplicatedTooManySteps","thumb-down"],["最新ではない","outOfDate","thumb-down"],["翻訳に関する問題","translationIssue","thumb-down"],["サンプル / コードに問題がある","samplesCodeIssue","thumb-down"],["その他","otherDown","thumb-down"]],["最終更新日 2025-08-29 UTC。"],[],["The `\u003cresource\u003e` entity defines supplemental information for an `\u003cinfo\u003e` object. It utilizes sub-elements: `\u003cresourceDesc\u003e` (required) describes the resource's content, `\u003cmimeType\u003e` (required) specifies the MIME type, `\u003csize\u003e` (optional) indicates file size in bytes, `\u003curi\u003e` (optional) provides a file location URI. `\u003cdefeUri\u003e` (conditional) offers Base64 encoded data and `\u003cdigest\u003e` (optional) is a SHA-1 hash. The example shows usage for image files with descriptions, types, and URI locations.\n"]]