GeoEco.Metadata.AddPropertyMetadata
- GeoEco.Metadata.AddPropertyMetadata(prop, typeMetadata, shortDescription=None, longDescription=None, isExposedToPythonCallers=False, cls=None, module=None)
Creates a
PropertyMetadataand for a class property adds it to aClassMetadata.- Parameters:
prop (
propertyorstr) – Thepropertyobject or name of the property. If the name is given, cls must also be given.typeMetadata (
GeoEco.Types.TypeMetadata) – ATypeMetadatathat describes the data type and allowed values of the property.shortDescription (
str, optional) – One-line description of the property, ideally as plain text (but reStructuredText is OK).longDescription (
str, optional) – Detailed description of the property, formatted as reStructuredText.isExposedToPythonCallers (
bool, optional) – If True, the property should be part of GeoEco’s Public API. If False, the default, the property is considered part of GeoEco’s Internal API and not recommended for use by external callers.cls (
typeorstr, optional) – The class containing the property, either as the class itself or the unqualified name of the class (without module or package names). Only needed if prop is given as a name rather than apropertyobject.module (
ModuleTypeorstr, optional) – The module that contains the class, either as the module object itself or the fully qualified name of the module (a.k.a. dotted module name). If not provided, the caller’s module is used.
Note
Before calling this function, use
AddClassMetadata()to create theClassMetadataand add it to its module’sModuleMetadata.