GDAL
|
Interface used to get a single GDALAttribute or a set of GDALAttribute. More...
#include <gdal_priv.h>
Public Member Functions | |
virtual std::shared_ptr< GDALAttribute > | GetAttribute (const std::string &osName) const |
Return an attribute by its name. More... | |
virtual std::vector< std::shared_ptr< GDALAttribute > > | GetAttributes (CSLConstList papszOptions=nullptr) const |
Return the list of attributes contained in a GDALMDArray or GDALGroup. More... | |
virtual std::shared_ptr< GDALAttribute > | CreateAttribute (const std::string &osName, const std::vector< GUInt64 > &anDimensions, const GDALExtendedDataType &oDataType, CSLConstList papszOptions=nullptr) |
Create an attribute within a GDALMDArray or GDALGroup. More... | |
Protected Member Functions | |
std::shared_ptr< GDALAttribute > | GetAttributeFromAttributes (const std::string &osName) const |
Possible fallback implementation for GetAttribute() using GetAttributes(). | |
Interface used to get a single GDALAttribute or a set of GDALAttribute.
|
virtual |
Create an attribute within a GDALMDArray or GDALGroup.
The attribute might not be "physically" created until a value is written into it.
Optionally implemented.
Drivers known to implement it: MEM, netCDF
This is the same as the C function GDALGroupCreateAttribute() or GDALMDArrayCreateAttribute()
osName | Attribute name. |
anDimensions | List of dimension sizes, ordered from the slowest varying dimension first to the fastest varying dimension last. Empty for a scalar attribute (common case) |
oDataType | Attribute data type. |
papszOptions | Driver specific options determining how the attribute. should be created. |
|
virtual |
Return an attribute by its name.
If the attribute does not exist, nullptr should be silently returned.
Drivers known to implement it for groups and arrays: MEM, netCDF.
This is the same as the C function GDALGroupGetAttribute() or GDALMDArrayGetAttribute().
osName | Attribute name |
|
virtual |
Return the list of attributes contained in a GDALMDArray or GDALGroup.
If the attribute does not exist, nullptr should be silently returned.
Drivers known to implement it for groups and arrays: MEM, netCDF.
This is the same as the C function GDALGroupGetAttributes() or GDALMDArrayGetAttributes().
papszOptions | Driver specific options determining how attributes should be retrieved. Pass nullptr for default behavior. |