# C1.PivotEngine.C1PivotEngine.GetMetadata

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_PivotEngine_C1PivotEngine_GetMetadata_" data-uid="C1.PivotEngine.C1PivotEngine.GetMetadata*">GetMetadata Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_PivotEngine_C1PivotEngine_GetMetadata_" data-uid="C1.PivotEngine.C1PivotEngine.GetMetadata*"></a>
<h4 id="C1_PivotEngine_C1PivotEngine_GetMetadata_System_String_System_String_System_Threading_CancellationToken_" data-uid="C1.PivotEngine.C1PivotEngine.GetMetadata(System.String,System.String,System.Threading.CancellationToken)">GetMetadata(string, string, CancellationToken)</h4>
<div class="markdown level1 summary"><p>Lists fields with their types and provides other metadata for a DataEngine table.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static Task&lt;Dictionary&lt;string, object&gt;&gt; GetMetadata(string workspace, string table, CancellationToken cancelToken)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function GetMetadata(workspace As String, table As String, cancelToken As CancellationToken) As Task(Of Dictionary(Of String, Object))</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">workspace</span></td>
      <td><p>Path in the server's file system where DataEngine data is saved in files.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">table</span></td>
      <td><p>The name of a DataEngine table.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken">CancellationToken</a></td>
      <td><span class="parametername">cancelToken</span></td>
      <td><p>Enables task cancellation.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1">Task</a>&lt;<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.generic.dictionary-2">Dictionary</a>&lt;<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a>, <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a>&gt;&gt;</td>
      <td><p>Dictionary containing key/value pairs for metadata parts, where key is the name of the part.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_PivotEngine_C1PivotEngine_GetMetadata_System_String_System_String_System_Threading_CancellationToken__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Currently supported metadata parts are:</p>
            <p>"fields": IList collection containing field information, objects with properties Name (string) and Type (System.Type)</p>
            <p>"rowCount": Number of rows in the DataEngine table</p>
</div>


<a id="C1_PivotEngine_C1PivotEngine_GetMetadata_" data-uid="C1.PivotEngine.C1PivotEngine.GetMetadata*"></a>
<h4 id="C1_PivotEngine_C1PivotEngine_GetMetadata_System_Collections_IEnumerable_System_Threading_CancellationToken_" data-uid="C1.PivotEngine.C1PivotEngine.GetMetadata(System.Collections.IEnumerable,System.Threading.CancellationToken)">GetMetadata(IEnumerable, CancellationToken)</h4>
<div class="markdown level1 summary"><p>Lists fields with their types and provides other metadata for a data source.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static Task&lt;Dictionary&lt;string, object&gt;&gt; GetMetadata(IEnumerable dataSource, CancellationToken cancelToken)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function GetMetadata(dataSource As IEnumerable, cancelToken As CancellationToken) As Task(Of Dictionary(Of String, Object))</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.ienumerable">IEnumerable</a></td>
      <td><span class="parametername">dataSource</span></td>
      <td><p>Data source collection.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken">CancellationToken</a></td>
      <td><span class="parametername">cancelToken</span></td>
      <td><p>Enables task cancellation.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1">Task</a>&lt;<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.generic.dictionary-2">Dictionary</a>&lt;<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a>, <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a>&gt;&gt;</td>
      <td><p>Dictionary containing key/value pairs for metadata parts, where key is the name of the part.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_PivotEngine_C1PivotEngine_GetMetadata_System_Collections_IEnumerable_System_Threading_CancellationToken__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Currently supported metadata parts are:</p>
            <p>"fields": IList collection containing field information, objects with properties Name (string) and Type (System.Type)</p>
            <p>"rowCount": Number of rows in the data source</p>
</div>
</div>
