> ## Documentation Index
> Fetch the complete documentation index at: https://developer.synopsys.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ansys::dpf::CustomContainerBase Class Reference

Allows you to define your own containers by deriving from this class.

`#include <dpf_api.h>`

## Public Member Functions

| Type | Name |
| - | - |
| | [CustomContainerBase](#ab2649202d9da1730e164634a4d864f3e) (std::string const \&class\_name) |
| | [CustomContainerBase](#a0dbdad77df7b779da34e8fa283a6597f) (std::string const \&class\_name, [Client](https://developer.synopsys.com/docs/dpf/dpf-cpp-client-library/2025-r1/classansys_1_1dpf_1_1Client.md) const \*const client) |
| | [CustomContainerBase](#ae7229c52821828cec4fca9dce836ee55) (std::string const \&class\_name, GenericDataContainer const &[container](#a595ca7a2057dd128a01676b24e622c08)) |
| GenericDataContainer & | [container](#a595ca7a2057dd128a01676b24e622c08) () |
| GenericDataContainer const & | [container](#a92893ff58ddca6339079f1a7299d2a9c) () const |
| std::string | [describe](#a65a8a6f6585ddf80c7e0dfdf9b9c50f5) () const |
|  std::vector\< std::string > | **getAttributeNames** () const |
| bool | [getClient](#ae048111b288fdbddfd3a5ab07438bc85) ([Client](https://developer.synopsys.com/docs/dpf/dpf-cpp-client-library/2025-r1/classansys_1_1dpf_1_1Client.md) \&client) const |

## Detailed Description

Allows you to define your own containers by deriving from this class.

For the custom class deriving from [CustomContainerBase](https://developer.synopsys.com/docs/dpf/dpf-cpp-client-library/2025-r1/classansys_1_1dpf_1_1CustomContainerBase.md) to be fully supported by DPF features (connection to Operator, remote access, multi languages API), all private attributes should registered into the GenericDataContainer held.

## Constructor & Destructor Documentation

### CustomContainerBase() \[1/3]

```cpp theme={null}
ansys::dpf::CustomContainerBase::CustomContainerBase(std::string const & class_name)
```

**Parameters**

| Direction | Name | Description |
| - | - | - |
| \[in] | class\_name | Name of the custom class in camel case format. Will be used to print the instance. |

### CustomContainerBase() \[2/3]

```cpp theme={null}
ansys::dpf::CustomContainerBase::CustomContainerBase(
    std::string const & class_name,
    Client const *const client
)
```

**Parameters**

| Direction | Name | Description |
| - | - | - |
| \[in] | class\_name | Name of the custom class in camel case format. Will be used to print the instance. |
| \[in] | client | [Client](https://developer.synopsys.com/docs/dpf/dpf-cpp-client-library/2025-r1/classansys_1_1dpf_1_1Client.md) instance designating the IP, port and protocol to use. |

### CustomContainerBase() \[3/3]

```cpp theme={null}
ansys::dpf::CustomContainerBase::CustomContainerBase(
    std::string const & class_name,
    GenericDataContainer const & container
)
```

**Parameters**

| Direction | Name | Description |
| - | - | - |
| \[in] | class\_name | Name of the custom class in camel case format. Will be used to print the instance. |
| \[in] | container | Internal container holding all the attributes as properties. |

## Member Function Documentation

### container() \[1/2]

```cpp theme={null}
GenericDataContainer & ansys::dpf::CustomContainerBase::container()
```

**Returns**

The internal container.

### container() \[2/2]

```cpp theme={null}
GenericDataContainer const & ansys::dpf::CustomContainerBase::container() const
```

**Returns**

The internal container.

### describe()

```cpp theme={null}
std::string ansys::dpf::CustomContainerBase::describe() const
```

**Returns**

Description of object.

### getClient()

```cpp theme={null}
bool ansys::dpf::CustomContainerBase::getClient(Client & client) const
```

**Returns**

Get the [Client](https://developer.synopsys.com/docs/dpf/dpf-cpp-client-library/2025-r1/classansys_1_1dpf_1_1Client.md) the object is on, if it has one. Must not be used without using remote API.
