pygplates.Property

class pygplates.Property(property_name, property_value)

Bases: Boost.Python.instance

Associates a property name with a property value.

Properties are equality (==, !=) comparable (but not hashable - cannot be used as a key in a dict). This includes comparing the property value in the two properties being compared (see PropertyValue) as well as the property name.

__init__(property_name, property_value)

Create a property given a property name and a property value.

Parameters:
property = pygplates.Property(property_name, property_value)

Methods

__init__(property_name, property_value) Create a property given a property name and a property value.
clone() Create a duplicate of this property instance.
get_name() Returns the name of the property.
get_time_dependent_container() Returns the time-dependent property value container.
get_value([time=0]) Extracts the value, of our possibly time-dependent property, at the reconstruction time.
clone()

Create a duplicate of this property instance.

Return type:Property

This clones the PropertyName and the PropertyValue.

get_name()

Returns the name of the property.

Return type:PropertyName
get_time_dependent_container()

Returns the time-dependent property value container.

Return type:PropertyValue or None

Returns a time-dependent property value (GpmlConstantValue, GpmlIrregularSampling or GpmlPiecewiseAggregation), or None if the property value is not actually time-dependent. Alternatively you can use get_value() for extracting a contained property value at a reconstruction time.

This method is useful if you want to access the time-dependent property value container directly. An example is inspecting or modifying the time samples in a GpmlIrregularSampling. Otherwise get_value() is generally more useful since it extracts a value from the container.

get_value([time=0])

Extracts the value, of our possibly time-dependent property, at the reconstruction time.

Parameters:time (float or GeoTimeInstant) – the time to extract value (defaults to present day)
Return type:PropertyValue or None

If this property has a time-dependent property value (GpmlConstantValue, GpmlIrregularSampling or GpmlPiecewiseAggregation) then a nested property value is extracted at the reconstruction time and returned. Otherwise our property value instance is simply returned as is (since it’s not a time-dependent property value). See PropertyValue.get_value() for more details.

Note

This method never returns a time-dependent property value (GpmlConstantValue, GpmlIrregularSampling or GpmlPiecewiseAggregation). You can use get_time_dependent_container() for that.

Previous topic

pygplates.FeatureCollection

Next topic

pygplates.PropertyName

This Page