ansys::dpf::Streams Class Reference
Last update: 10.07.2023
ansys::dpf::Streams Class Reference
Defines an open, ready-to-use, data sources. More...
#include <dpf_api.h>
Inheritance diagram for ansys::dpf::Streams:
Public Member Functions | |
Streams (DataSources const &dataSources) | |
Streams (Streams const &) | |
Streams (Streams &&) | |
Streams (int id, Client const *const client) | |
Streams & | operator= (Streams const &) |
Streams & | operator= (Streams &&) |
void | releaseFiles () |
void | addStream (ExternalStream *stream) |
void | addStream (ExternalStream *stream, LabelSpace const &identifier) |
template<typename ExternalStreamType > | |
ExternalStreamType *const | getExternalStream (std::string const &key) const |
template<typename ExternalStreamType > | |
ExternalStreamType *const | getExternalStream (LabelSpace const &identifier) const |
DataSources | dataSources () const |
Public Member Functions inherited from ansys::dpf::DpfTypes | |
virtual bool | empty () const |
virtual std::string | describe () const |
so::API const * | callAPI () const |
bool | isOnCommonAPI () const |
bool | getClient (Client &client) const |
bool | hasBeenMovedLocally () const |
bool | isSameObject (DpfTypes const &rhs) const |
Static Public Member Functions | |
static Streams | emptyStreams () |
Detailed Description
Defines an open, ready-to-use, data sources.
Streams is an entity containing the data sources. Once the files in the streams are opened, they stay opened and they keep some data in cache to make the next evaluations faster. To close the files, release the streams.
Constructor & Destructor Documentation
◆ Streams() [1/2]
ansys::dpf::Streams::Streams | ( | DataSources const & | dataSources | ) |
Create a stream from given data sources.
- Parameters
-
[in] dataSources Data source from which to create stream.
◆ Streams() [2/2]
ansys::dpf::Streams::Streams | ( | int | id, |
Client const *const | client | ||
) |
Member Function Documentation
◆ addStream() [1/2]
void ansys::dpf::Streams::addStream | ( | ExternalStream * | stream | ) |
Add external stream.
- Parameters
-
[in] stream External stream to add.
◆ addStream() [2/2]
void ansys::dpf::Streams::addStream | ( | ExternalStream * | stream, |
LabelSpace const & | identifier | ||
) |
Add external stream.
- Parameters
-
[in] stream External stream to add. [in] identifier Identifier returned by the data sources.
◆ emptyStreams()
|
static |
Create an empty streams.
- Returns
- Empty Streams.
◆ getExternalStream()
template<typename ExternalStreamType >
ExternalStreamType *const ansys::dpf::Streams::getExternalStream | ( | LabelSpace const & | identifier | ) | const |
- Parameters
-
[in] identifier Identifier returned by the data sources.
◆ releaseFiles()
void ansys::dpf::Streams::releaseFiles | ( | ) |
Closes all files and releases file resources.