Skip to main content

DPF Cpp Client Library 2026 R1

Class ansys::dpf::Client

Last update: 25.03.2026

Client for remote DPF connection. A Client instance is always associated to a DPF server process. The corresponding server needs to run so that the client instance can then be correctly used. This client allows to create DPF objects on a remote server.

Inherits from:

Members

Friends

Public functions

Function Client

ansys::dpf::Client::Client(std::string const &ip, std::string const &port)

Create Client object from known ip and port.

Parameters:

  • std::string const & ip: [in] server ip
  • std::string const & port: [in] server port

Return type:

Function Client

ansys::dpf::Client::Client(std::string const &ip, std::string const &port, LibraryHandle const &library_handle)

Create Client from known ip, port and library handle.

Parameters:

  • std::string const & ip: [in] server ip
  • std::string const & port: [in] server port
  • LibraryHandle const & library_handle: [in] the library_handle API will be used

Return type:

Function Client

ansys::dpf::Client::Client(std::string const &address)

Create Client from known address.

Parameters:

  • std::string const & address: [in] string with 'ip::port' format.

Return type:

Function Client

ansys::dpf::Client::Client(std::string const &address, LibraryHandle const &library_handle)

Create Client from known address and library handle.

Parameters:

  • std::string const & address: [in] string with 'ip::port' format.
  • LibraryHandle const & library_handle: [in] the library_handle API will be used

Return type:

Function Client

ansys::dpf::Client::Client(Client const &)

Parameters:

  • Client const &

Return type:

Function Client

ansys::dpf::Client::Client(Client &&) noexcept

Parameters:

  • Client &&

Return type:

Function operator=

Client & ansys::dpf::Client::operator=(Client const &)

Parameters:

  • Client const &

Return type: Client &

Function operator=

Client & ansys::dpf::Client::operator=(Client &&) noexcept

Parameters:

  • Client &&

Return type: Client &

Function ~Client

virtual ansys::dpf::Client::~Client()=default

Return type:

Function internalObj

opaque::DpfObject *const ansys::dpf::Client::internalObj() const

Return type: opaque::DpfObject *const

Function getChannelAddress

std::string ansys::dpf::Client::getChannelAddress() const

Returns:

Address string with 'ip::port' format.

Return type: std::string

Function getProtocolName

std::string ansys::dpf::Client::getProtocolName() const

Returns:

Protocol's name.

Return type: std::string

Function getOrStartLocalServer

bool ansys::dpf::Client::getOrStartLocalServer(ansys::dpf::Streams &streams, ansys::dpf::Operator &stream_provider, int output_pin=0) const

If it doesn't exist yet, a local server is started. This local server can then be connected to by another server (usually used for bidirectional gRPC connections).

Parameters:

Return type: bool

Function callAPI

so::API const  * ansys::dpf::Client::callAPI() const

Return type: so::API const *

Public static functions

Function emptyClient

static Client ansys::dpf::Client::emptyClient()

Create an empty client. Returns:

Empty Client

Return type: Client

Connect with Ansys