Skip to main content

DPF Cpp Client Library 2026 R1

Class ansys::dpf::FieldDefinition

Last update: 25.03.2026

Provide all the information about the content of a Field (Unit, location, dimension, a.s.o.).

See also: Field

Inherits from:

Members

Friends

Public functions

Function FieldDefinition

ansys::dpf::FieldDefinition::FieldDefinition()

Create FieldDefinition.

Return type:

Function FieldDefinition

ansys::dpf::FieldDefinition::FieldDefinition(Client const *const client)

Create FieldDefinition on a server.

Parameters:

  • Client const *const client: [in] Remote client.

Return type:

Function ~FieldDefinition

virtual ansys::dpf::FieldDefinition::~FieldDefinition()

Return type:

Function FieldDefinition

ansys::dpf::FieldDefinition::FieldDefinition(FieldDefinition const &)

Parameters:

  • FieldDefinition const &

Return type:

Function FieldDefinition

ansys::dpf::FieldDefinition::FieldDefinition(FieldDefinition &&) noexcept

Parameters:

  • FieldDefinition &&

Return type:

Function FieldDefinition

ansys::dpf::FieldDefinition::FieldDefinition(const ansys::dpf::Location &loc, const std::vector< dp_int > &dimensions)

Create FieldDefinition.

Parameters:

Return type:

Function FieldDefinition

ansys::dpf::FieldDefinition::FieldDefinition(const ansys::dpf::Location &loc, const std::vector< dp_int > &dimensions, const Unit &unit)

Create FieldDefinition.

Parameters:

Return type:

Function FieldDefinition

ansys::dpf::FieldDefinition::FieldDefinition(Client const *const client, const ansys::dpf::Location &loc, const std::vector< dp_int > &dimensions)

Create FieldDefinition.

Parameters:

Return type:

Function FieldDefinition

ansys::dpf::FieldDefinition::FieldDefinition(Client const *const client, const ansys::dpf::Location &loc, const std::vector< dp_int > &dimensions, const Unit &unit)

Create FieldDefinition.

Parameters:

Return type:

Function operator=

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

Parameters:

  • FieldDefinition const &

Return type: FieldDefinition &

Function operator=

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

Parameters:

  • FieldDefinition &&

Return type: FieldDefinition &

Function unit

ansys::dpf::Unit ansys::dpf::FieldDefinition::unit() const

Returns:

Unit of FieldDefinition.

Return type: ansys::dpf::Unit

Function dimensions

std::vector< dp_int > ansys::dpf::FieldDefinition::dimensions() const

Returns:

Vector defining size of each dimension. See Dimensionality.

Return type: std::vector< dp_int >

Function location

ansys::dpf::Location ansys::dpf::FieldDefinition::location() const

Returns:

Location on which field defined.

Return type: ansys::dpf::Location

Function name

std::string ansys::dpf::FieldDefinition::name() const

Returns:

Name of the field.

Return type: std::string

Function shellLayers

eshellLayers ansys::dpf::FieldDefinition::shellLayers() const

Returns:

Layers over which field defined.

Return type: eshellLayers

Function setName

void ansys::dpf::FieldDefinition::setName(std::string const &rhs)

Set field name.

Parameters:

  • std::string const & rhs

Return type: void

Function setLocation

void ansys::dpf::FieldDefinition::setLocation(ansys::dpf::Location const &rhs)

Set field location.

Parameters:

Return type: void

Function setUnit

void ansys::dpf::FieldDefinition::setUnit(ansys::dpf::Unit const &rhs)

Set field unit.

Parameters:

Return type: void

Function setDimensions

void ansys::dpf::FieldDefinition::setDimensions(std::vector< dp_int > const &rhs, int effective_size)

Set dimensions of field.

Parameters:

  • std::vector< dp_int > const & rhs: [in] Vector defining size of each dimension. See Dimensionality.
  • int effective_size: [in] Effective size of data per field entry. (scalar is 1, xyz vector is 3, 2 Dimensional 3x3 Matrix is 9, ...)

Return type: void

Function setDimensions

void ansys::dpf::FieldDefinition::setDimensions(std::vector< dp_int > const &rhs)

Set dimensions of field.

Parameters:

  • std::vector< dp_int > const & rhs: [in] Vector defining size of each dimension. See Dimensionality.

Return type: void

Function setShellLayers

void ansys::dpf::FieldDefinition::setShellLayers(ansys::dpf::eshellLayers layers)

Set layers of field.

Parameters:

Return type: void

Function deep_copy

FieldDefinition ansys::dpf::FieldDefinition::deep_copy(ansys::dpf::Client const *const client=nullptr) const

Make a deep copy on a given client.

Parameters:

Return type: FieldDefinition

Function isOfQuantityType

bool ansys::dpf::FieldDefinition::isOfQuantityType(QuantityType const &quantitytype) const

checks is the field data is of the given quantity type.

Parameters:

Return type: bool

Function setQuantityType

void ansys::dpf::FieldDefinition::setQuantityType(QuantityType const &quantitytype)

Set field data quantity type.

Parameters:

Return type: void

Function numberOfQuantityTypes

int ansys::dpf::FieldDefinition::numberOfQuantityTypes() const

Get the number of quantity types.

Return type: int

Function quantity_type

std::string ansys::dpf::FieldDefinition::quantity_type(int i) const

Get i'th quantity types.

Parameters:

  • int i

Return type: std::string

Public static functions

Function emptyFieldDefinition

static FieldDefinition ansys::dpf::FieldDefinition::emptyFieldDefinition()

Create an empty FieldDefinition. Returns:

Empty FieldDefinition.

Return type: FieldDefinition

Connect with Ansys