---
schema_version: "1"
id: c942aa79bd0ed676bb639da95350c941f5669cf90cf5b18fc627e632dccbc454
title: DataWeave (dw) 形式
collection: mulesoft
version: current
locale: ja-jp
portal_url: https://docs.salesforce.com/mulesoft/current/ja-jp/dataweave/2.8/dataweave-formats-dw.md
canonical_url: https://docs.mulesoft.com/jp/dataweave/2.8/dataweave-formats-dw
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 3368e726a145d41719d992301cb55a222a55320df749e0ad483742959f0acd7f
description: MuleSoft Documentation Site
release: "2.8"
latest: false
---
# DataWeave (dw) 形式

MIME タイプ: `application/dw`

ID: `dw`

DataWeave (dw) 形式はすべての変換の正規形式です。 この形式を使用すると、入力データが新しい形式に変換される前に入力データがどのように解釈されるかを容易に理解できます。

<table>
<tbody><tr>
<td class="icon">
<i class="fa icon-note" title="Note"></i>
</td>
<td class="content">
<div class="paragraph">
<p>この形式の目的は、DataWeave 変換の結果を容易にデバッグできるようにすることです。動作は他の形式よりも大幅に遅くなります。パフォーマンスに影響する可能性があるため、これを本番アプリケーションで使用することはお勧めしません。</p>
</div>
</td>
</tr>
</tbody></table>

## [](#examples)例: XML を DataWeave (dw) 形式で表す

次の例は、XML 入力を DataWeave (dw) 形式に変換する方法を示しています。

### [](#入力)入力

この例では、次の XML スニペットを入力として使用します。

```xml
<employees>
  <employee>
    <firstname>Mariano</firstname>
    <lastname>DeAchaval</lastname>
  </employee>
  <employee>
    <firstname>Leandro</firstname>
    <lastname>Shokida</lastname>
  </employee>
</employees>
```

#### [](#出力)出力

DataWeave 形式の出力

```dataweave
{
  employees: {
    employee: {
      firstname: "Mariano",
      lastname: "DeAchaval"
    },
    employee: {
      firstname: "Leandro",
      lastname: "Shokida"
    }
  }
} as Object {encoding: "UTF-8", mimeType: "text/xml"}
```

## [](#properties)Configuration のプロパティ

DataWeave では、この形式の以下の設定プロパティがサポートされています。

### [](#reader_properties)Reader のプロパティ

この形式は、入力データを読み取るための指示を提供するプロパティを受け入れます。

<table class="tableblock frame-all grid-all stretch">
<colgroup>
<col style="width: 16.6666%;">
<col style="width: 16.6666%;">
<col style="width: 16.6666%;">
<col style="width: 50.0002%;">
</colgroup>
<thead>
<tr>
<th class="tableblock halign-left valign-top">パラメーター</th>
<th class="tableblock halign-left valign-top">型</th>
<th class="tableblock halign-left valign-top">デフォルト</th>
<th class="tableblock halign-left valign-top">説明</th>
</tr>
</thead>
<tbody>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>externalResources</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Boolean</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>false</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p><code>readUrl</code>​ で外部エンティティを読み取れるようにします。</p>
</div>
<div class="paragraph">
<p>有効な値は、​<code>true</code>​ または ​<code>false</code>​ です。</p>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>javaModule</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Boolean</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>false</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p>Java Module 関数を読み込めるようにします。</p>
</div>
<div class="paragraph">
<p>有効な値は、​<code>true</code>​ または ​<code>false</code>​ です。</p>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>onlyData</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Boolean</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>false</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p><code>true</code>​ に設定すると、データのみを処理し、関数などの他の型のコンテンツは処理しません。​<code>onlyData</code>​ モードでは、DataWeave パーサーの実行時間が短縮されます。</p>
</div>
<div class="paragraph">
<p>有効な値は、​<code>true</code>​ または ​<code>false</code>​ です。</p>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>privileges</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>String</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>''</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p><code>'Resources,Properties'</code>​ など、形式で使用する権限のカンマ区切りリストを受け入れます。</p>
</div></div></td>
</tr>
</tbody>
</table>

### [](#writer_properties)Writer のプロパティ

この形式は、出力データを書き込むための指示を提供するプロパティを受け入れます。

<table class="tableblock frame-all grid-all stretch">
<colgroup>
<col style="width: 16.6666%;">
<col style="width: 16.6666%;">
<col style="width: 16.6666%;">
<col style="width: 50.0002%;">
</colgroup>
<thead>
<tr>
<th class="tableblock halign-left valign-top">パラメーター</th>
<th class="tableblock halign-left valign-top">型</th>
<th class="tableblock halign-left valign-top">デフォルト</th>
<th class="tableblock halign-left valign-top">説明</th>
</tr>
</thead>
<tbody>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>bufferSize</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Number</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>8192</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p>バッファライターのサイズ (バイト)。値は ​<code>8</code>​ よりも大きい必要があります。</p>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>deferred</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Boolean</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>false</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p><code>true</code>​ に設定すると、出力をデータストリームとして生成し、スクリプトの実行は生成されたコンテンツがコンシュームされるまで延期されます。</p>
</div>
<div class="paragraph">
<p>有効な値は、​<code>true</code>​ または ​<code>false</code>​ です。</p>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>ignoreSchema</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Boolean</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>false</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p><code>true</code>​ に設定すると、スキーマを無視します。</p>
</div>
<div class="paragraph">
<p>有効な値は、​<code>true</code>​ または ​<code>false</code>​ です。</p>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>indent</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>String</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>'  '</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p>インデントで使用する文字列。</p>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>maxCollectionSize</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Number</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>-1</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p>配列またはオブジェクトで許容される最大要素数。  <code>-1</code>​ は、制限がないことを示します。</p>
</div></div></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>onlyData</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>Boolean</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>true</code></p></td>
<td class="tableblock halign-left valign-top"><div class="content"><div class="paragraph">
<p><code>true</code>​ に設定すると、データのみを処理し、関数などの他の型のコンテンツは処理しません。​<code>onlyData</code>​ モードでは、DataWeave パーサーの実行時間が短縮されます。</p>
</div>
<div class="paragraph">
<p>有効な値は、​<code>true</code>​ または ​<code>false</code>​ です。</p>
</div></div></td>
</tr>
</tbody>
</table>

## [](#mime_types)サポートされる MIME タイプ

この形式では、次の MIME タイプがサポートされます。

<table class="tableblock frame-all grid-all stretch">
<colgroup>
<col style="width: 100%;">
</colgroup>
<thead>
<tr>
<th class="tableblock halign-left valign-top">MIME タイプ</th>
</tr>
</thead>
<tbody>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>*/dw</code></p></td>
</tr>
</tbody>
</table>