    

 ## On this page

  

 

 # OutputVectorData

 Last update: 17.07.2025 

<a id="l00001" name="l00001"></a> 1/\*

<a id="l00002" name="l00002"></a> 2\* Copyright 2023 ANSYS, Inc. Unauthorized use, distribution, or duplication is prohibited.

<a id="l00003" name="l00003"></a> 3\*/

<a id="l00004" name="l00004"></a> 4 

<a id="l00005" name="l00005"></a> 5\#pragma once

<a id="l00006" name="l00006"></a> 6 

<a id="l00007" name="l00007"></a> 7\#include "SystemCouplingParticipant/LibraryType.hpp"

<a id="l00008" name="l00008"></a> 8 

<a id="l00009" name="l00009"></a> 9\#include "SystemCouplingParticipant/CommonTypes.hpp"

<a id="l00010" name="l00010"></a> 10 

<a id="l00011" name="l00011"></a> 11\#include &lt;cstddef&gt;

<a id="l00012" name="l00012"></a> 12\#include &lt;vector&gt;

<a id="l00013" name="l00013"></a> 13 

<a id="l00014" name="l00014"></a> 14namespace sysc {

<a id="l00015" name="l00015"></a> 15 

<a id="l00027" name="l00027"></a>[ 27](classsysc_1_1OutputVectorData.xhtml)class SYSTEM_COUPLING_PARTICIPANT_DLL [OutputVectorData](classsysc_1_1OutputVectorData.xhtml) {

<a id="l00028" name="l00028"></a> 28public:

<a id="l00035" name="l00035"></a>[ 35](classsysc_1_1OutputVectorData.xhtml#a5baa242c692e4c981534a3c4e3492ea4) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a5baa242c692e4c981534a3c4e3492ea4)(const double* data, std::size_t size);

<a id="l00036" name="l00036"></a> 36 

<a id="l00043" name="l00043"></a>[ 43](classsysc_1_1OutputVectorData.xhtml#aef88547a7694874f7fbf7956130e0066) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#aef88547a7694874f7fbf7956130e0066)(const float* data, std::size_t size);

<a id="l00044" name="l00044"></a> 44 

<a id="l00050" name="l00050"></a>[ 50](classsysc_1_1OutputVectorData.xhtml#a3f50f1e64c99ce81d0c0f3ba1df8461e) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a3f50f1e64c99ce81d0c0f3ba1df8461e)(const std::vector&lt;double&gt;&amp; data);

<a id="l00051" name="l00051"></a> 51 

<a id="l00057" name="l00057"></a>[ 57](classsysc_1_1OutputVectorData.xhtml#a030b346cb0d19cb872edc91e2e9c15e5) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a030b346cb0d19cb872edc91e2e9c15e5)(const std::vector&lt;float&gt;&amp; data);

<a id="l00058" name="l00058"></a> 58 

<a id="l00068" name="l00068"></a>[ 68](classsysc_1_1OutputVectorData.xhtml#aebefd421a4e0e4b13715ab2cb140bc9b) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#aebefd421a4e0e4b13715ab2cb140bc9b)(

<a id="l00069" name="l00069"></a> 69 const double* data0,

<a id="l00070" name="l00070"></a> 70 const double* data1,

<a id="l00071" name="l00071"></a> 71 const double* data2,

<a id="l00072" name="l00072"></a> 72 std::size_t size);

<a id="l00073" name="l00073"></a> 73 

<a id="l00083" name="l00083"></a>[ 83](classsysc_1_1OutputVectorData.xhtml#a5d46caaf7a323c14dec7eef78370eef2) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a5d46caaf7a323c14dec7eef78370eef2)(

<a id="l00084" name="l00084"></a> 84 const float* data0,

<a id="l00085" name="l00085"></a> 85 const float* data1,

<a id="l00086" name="l00086"></a> 86 const float* data2,

<a id="l00087" name="l00087"></a> 87 std::size_t size);

<a id="l00088" name="l00088"></a> 88 

<a id="l00097" name="l00097"></a>[ 97](classsysc_1_1OutputVectorData.xhtml#ae242e3a4ecaf21e98161eeb9b76ddd96) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#ae242e3a4ecaf21e98161eeb9b76ddd96)(

<a id="l00098" name="l00098"></a> 98 const std::vector&lt;double&gt;&amp; data0,

<a id="l00099" name="l00099"></a> 99 const std::vector&lt;double&gt;&amp; data1,

<a id="l00100" name="l00100"></a> 100 const std::vector&lt;double&gt;&amp; data2);

<a id="l00101" name="l00101"></a> 101 

<a id="l00110" name="l00110"></a>[ 110](classsysc_1_1OutputVectorData.xhtml#aca273abdb13cb319c0a62fd1e1a3a6de) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#aca273abdb13cb319c0a62fd1e1a3a6de)(

<a id="l00111" name="l00111"></a> 111 const std::vector&lt;float&gt;&amp; data0,

<a id="l00112" name="l00112"></a> 112 const std::vector&lt;float&gt;&amp; data1,

<a id="l00113" name="l00113"></a> 113 const std::vector&lt;float&gt;&amp; data2);

<a id="l00114" name="l00114"></a> 114 

<a id="l00116" name="l00116"></a>[ 116](classsysc_1_1OutputVectorData.xhtml#a9ec5428be66a6df185dd3ed80b0eb64e) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a9ec5428be66a6df185dd3ed80b0eb64e)() = default;

<a id="l00117" name="l00117"></a> 117 

<a id="l00119" name="l00119"></a>[ 119](classsysc_1_1OutputVectorData.xhtml#a25c63d3cb6b341e0f60e4b952340eaf8) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a25c63d3cb6b341e0f60e4b952340eaf8)(const [OutputVectorData](classsysc_1_1OutputVectorData.xhtml)&amp;) = default;

<a id="l00120" name="l00120"></a> 120 

<a id="l00122" name="l00122"></a>[ 122](classsysc_1_1OutputVectorData.xhtml#acd5db0cd2504d1bc6c933d0108982287) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml#acd5db0cd2504d1bc6c933d0108982287)([OutputVectorData](classsysc_1_1OutputVectorData.xhtml)&amp;&amp;) = default;

<a id="l00123" name="l00123"></a> 123 

<a id="l00125" name="l00125"></a>[ 125](classsysc_1_1OutputVectorData.xhtml#a61b2ae2e8bc599f9f474004bf604f7fb) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml)&amp; [operator=](classsysc_1_1OutputVectorData.xhtml#a61b2ae2e8bc599f9f474004bf604f7fb)(const [OutputVectorData](classsysc_1_1OutputVectorData.xhtml)&amp;) = default;

<a id="l00126" name="l00126"></a> 126 

<a id="l00128" name="l00128"></a>[ 128](classsysc_1_1OutputVectorData.xhtml#aad1840875a905047a6c63450d20c38c6) [OutputVectorData](classsysc_1_1OutputVectorData.xhtml)&amp; [operator=](classsysc_1_1OutputVectorData.xhtml#aad1840875a905047a6c63450d20c38c6)([OutputVectorData](classsysc_1_1OutputVectorData.xhtml)&amp;&amp;) = default;

<a id="l00129" name="l00129"></a> 129 

<a id="l00131" name="l00131"></a>[ 131](classsysc_1_1OutputVectorData.xhtml#ad20f55bcbeb46bdd900ba98de9591262) std::size_t [size](classsysc_1_1OutputVectorData.xhtml#ad20f55bcbeb46bdd900ba98de9591262)() const;

<a id="l00132" name="l00132"></a> 132 

<a id="l00137" name="l00137"></a>[ 137](classsysc_1_1OutputVectorData.xhtml#a11982457f374e0f625cda4e479a329f8) [sysc::PrimitiveType](group__SystemCouplingParticipantAPIs.xhtml#gad3b1c73e4a63f4d292d65f3db875e844) [getDataType](classsysc_1_1OutputVectorData.xhtml#a11982457f374e0f625cda4e479a329f8)() const;

<a id="l00138" name="l00138"></a> 138 

<a id="l00144" name="l00144"></a>[ 144](classsysc_1_1OutputVectorData.xhtml#a6a97f7bbca0250cb567eb15d41cad8a9) bool [isSplitVector](classsysc_1_1OutputVectorData.xhtml#a6a97f7bbca0250cb567eb15d41cad8a9)() const;

<a id="l00145" name="l00145"></a> 145 

<a id="l00151" name="l00151"></a>[ 151](classsysc_1_1OutputVectorData.xhtml#a6b242fd82783001d3feca7361715e0f4) const void* [getData0](classsysc_1_1OutputVectorData.xhtml#a6b242fd82783001d3feca7361715e0f4)() const;

<a id="l00152" name="l00152"></a> 152 

<a id="l00158" name="l00158"></a>[ 158](classsysc_1_1OutputVectorData.xhtml#a925a9bc512a97b2dfb67b4199f464156) const void* [getData1](classsysc_1_1OutputVectorData.xhtml#a925a9bc512a97b2dfb67b4199f464156)() const;

<a id="l00159" name="l00159"></a> 159 

<a id="l00165" name="l00165"></a>[ 165](classsysc_1_1OutputVectorData.xhtml#a6bce788a2b74e22de5b0e789c119c865) const void* [getData2](classsysc_1_1OutputVectorData.xhtml#a6bce788a2b74e22de5b0e789c119c865)() const;

<a id="l00166" name="l00166"></a> 166 

<a id="l00167" name="l00167"></a> 167private:

<a id="l00168" name="l00168"></a> 168 [sysc::PrimitiveType](group__SystemCouplingParticipantAPIs.xhtml#gad3b1c73e4a63f4d292d65f3db875e844) m_dataType{[sysc::Double](group__SystemCouplingParticipantAPIs.xhtml#ggad3b1c73e4a63f4d292d65f3db875e844a29843d2c1bb5760f768dcc066dac1ac1)};

<a id="l00169" name="l00169"></a> 169 bool m_isSplitVector{false};

<a id="l00170" name="l00170"></a> 170 const void* m_data0{nullptr};

<a id="l00171" name="l00171"></a> 171 const void* m_data1{nullptr};

<a id="l00172" name="l00172"></a> 172 const void* m_data2{nullptr};

<a id="l00173" name="l00173"></a> 173 std::size_t m_size{0};

<a id="l00174" name="l00174"></a> 174};

<a id="l00175" name="l00175"></a> 175 

<a id="l00176" name="l00176"></a> 176} // namespace sysc

[sysc::OutputVectorData](classsysc_1_1OutputVectorData.xhtml)

Provide a class for output vector data.

**Definition:** [OutputVectorData.hpp:27](OutputVectorData_8hpp_source.xhtml#l00027)



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a030b346cb0d19cb872edc91e2e9c15e5)

OutputVectorData(const std::vector&lt; float &gt; &amp;data)

Provide a constructor for output vector data with compact storage.



[sysc::OutputVectorData::getDataType](classsysc_1_1OutputVectorData.xhtml#a11982457f374e0f625cda4e479a329f8)

sysc::PrimitiveType getDataType() const

Get the primitive type of data.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a25c63d3cb6b341e0f60e4b952340eaf8)

OutputVectorData(const OutputVectorData &amp;)=default

Provide a copy-constructor.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a3f50f1e64c99ce81d0c0f3ba1df8461e)

OutputVectorData(const std::vector&lt; double &gt; &amp;data)

Provide a constructor for output vector data with compact storage.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a5baa242c692e4c981534a3c4e3492ea4)

OutputVectorData(const double *data, std::size_t size)

Provide a constructor for output vector data with compact storage.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a5d46caaf7a323c14dec7eef78370eef2)

OutputVectorData(const float *data0, const float *data1, const float *data2, std::size_t size)

Create an output vector data access object with split storage.



[sysc::OutputVectorData::operator=](classsysc_1_1OutputVectorData.xhtml#a61b2ae2e8bc599f9f474004bf604f7fb)

OutputVectorData &amp; operator=(const OutputVectorData &amp;)=default

Provide a copy-assign operator.



[sysc::OutputVectorData::isSplitVector](classsysc_1_1OutputVectorData.xhtml#a6a97f7bbca0250cb567eb15d41cad8a9)

bool isSplitVector() const

Query whether it's a split or compact vector layout.



[sysc::OutputVectorData::getData0](classsysc_1_1OutputVectorData.xhtml#a6b242fd82783001d3feca7361715e0f4)

const void * getData0() const

Get pointer to data0.



[sysc::OutputVectorData::getData2](classsysc_1_1OutputVectorData.xhtml#a6bce788a2b74e22de5b0e789c119c865)

const void * getData2() const

Get pointer to data2.



[sysc::OutputVectorData::getData1](classsysc_1_1OutputVectorData.xhtml#a925a9bc512a97b2dfb67b4199f464156)

const void * getData1() const

Get pointer to data1.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#a9ec5428be66a6df185dd3ed80b0eb64e)

OutputVectorData()=default

Provide a default constructor.



[sysc::OutputVectorData::operator=](classsysc_1_1OutputVectorData.xhtml#aad1840875a905047a6c63450d20c38c6)

OutputVectorData &amp; operator=(OutputVectorData &amp;&amp;)=default

Provide a move-assign operator.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#aca273abdb13cb319c0a62fd1e1a3a6de)

OutputVectorData(const std::vector&lt; float &gt; &amp;data0, const std::vector&lt; float &gt; &amp;data1, const std::vector&lt; float &gt; &amp;data2)

Create an output vector data access object with split storage.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#acd5db0cd2504d1bc6c933d0108982287)

OutputVectorData(OutputVectorData &amp;&amp;)=default

Provide a move-constructor.



[sysc::OutputVectorData::size](classsysc_1_1OutputVectorData.xhtml#ad20f55bcbeb46bdd900ba98de9591262)

std::size_t size() const

Get the size of data.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#ae242e3a4ecaf21e98161eeb9b76ddd96)

OutputVectorData(const std::vector&lt; double &gt; &amp;data0, const std::vector&lt; double &gt; &amp;data1, const std::vector&lt; double &gt; &amp;data2)

Create an output vector data access object with split storage.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#aebefd421a4e0e4b13715ab2cb140bc9b)

OutputVectorData(const double *data0, const double *data1, const double *data2, std::size_t size)

Create an output vector data access object with split storage.



[sysc::OutputVectorData::OutputVectorData](classsysc_1_1OutputVectorData.xhtml#aef88547a7694874f7fbf7956130e0066)

OutputVectorData(const float *data, std::size_t size)

Provide a constructor for output vector data with compact storage.



[sysc::PrimitiveType](group__SystemCouplingParticipantAPIs.xhtml#gad3b1c73e4a63f4d292d65f3db875e844)

PrimitiveType

Provide enum for supported primitive types.

**Definition:** [CommonTypes.hpp:211](CommonTypes_8hpp_source.xhtml#l00211)



[sysc::Double](group__SystemCouplingParticipantAPIs.xhtml#ggad3b1c73e4a63f4d292d65f3db875e844a29843d2c1bb5760f768dcc066dac1ac1)

@ Double

**Definition:** [CommonTypes.hpp:213](CommonTypes_8hpp_source.xhtml#l00213)