pygplates.FeatureType
- class pygplates.FeatureType
Bases:
instanceThe namespace-qualified type of a feature.
All comparison operators (==, !=, <, <=, >, >=) are supported. FeatureType is hashable (can be used as a key in a
dict).The default feature type for
Feature()ispygplates.FeatureType.gpml_unclassified_feature(which is the same aspygplates.FeatureType.create_gpml('UnclassifiedFeature')).As a convenience the following common feature types are available as class attributes:
A FeatureType can also be pickled.
Changed in version 0.42: Added pickle support.
- __init__()
You cannot directly instantiate this class from Python.
Note
This constructor is only provided for pickle support.
Methods
You cannot directly instantiate this class from Python.
[staticmethod] Creates a
FeatureTypeinstance from a fully qualified name string.create_gpml(name)[staticmethod] Create a feature type qualified with the
gpml:prefix (gpml:+name).Returns the default geometry property name associated with this feature type.
get_name()Returns the unqualified name.
Returns the namespace URI.
Returns the namespace alias.
Returns the fully qualified name.
Attributes
gpml_aseismic_ridgegpml_basic_rock_unitgpml_basingpml_closed_continental_boundarygpml_closed_plate_boundarygpml_coastlinegpml_continental_crustgpml_continental_fragmentgpml_continental_riftgpml_cratongpml_extended_continental_crustgpml_faultgpml_flowlinegpml_fold_planegpml_fracture_zonegpml_fracture_zone_identificationgpml_geological_lineationgpml_geological_planegpml_hot_spotgpml_hot_spot_trailgpml_inferred_paleo_boundarygpml_island_arcgpml_isochrongpml_large_igneous_provincegpml_magnetic_anomaly_identificationgpml_magnetic_anomaly_lineationgpml_magnetic_anomaly_ship_trackgpml_mid_ocean_ridgegpml_motion_pathgpml_oceanic_crustgpml_ophiolitegpml_orogenic_beltgpml_passive_continental_boundarygpml_plutongpml_pseudo_faultgpml_seamountgpml_slab_edgegpml_subduction_zonegpml_suturegpml_terrane_boundarygpml_topological_closed_plate_boundarygpml_topological_networkgpml_topological_slab_boundarygpml_total_reconstruction_sequencegpml_transformgpml_transitional_crustgpml_unclassified_featuregpml_unconformitygpml_unknown_contactgpml_virtual_geomagnetic_polegpml_volcano- static create_from_qualified_string(name)
[staticmethod] Creates a
FeatureTypeinstance from a fully qualified name string.- Parameters:
name (string) – qualified name
- Return type:
FeatureTypeor None
The name string should have a
:character separating the namespace alias from the unqualified name, for examplegpml:Coastline. If the namespace alias is not recognised (asgpml,gmlorxsi) thengpmlis assumed.An over-qualified name string (eg, containing two or more
:characters) will result inNonebeing returned.feature_type = pygplates.FeatureType.create_from_qualified_string('gpml:Coastline')
- static create_gpml(name)
[staticmethod] Create a feature type qualified with the
gpml:prefix (gpml:+name).- Parameters:
name (string) – unqualified name
- Return type:
gpml_coastline_feature_type = pygplates.FeatureType.create_gpml('Coastline')
- get_default_geometry_property_name()
Returns the default geometry property name associated with this feature type.
Usually a feature type supports geometry properties with more than one property name. For example, a coastline feature supports both a pygplates.PropertyName.gpml_center_line_of geometry and a pygplates.PropertyName.gpml_unclassified_geometry) geometry. But only one of them is the default (the default property that geometry data is imported into the feature). You can see which is the default by reading the
Default Geometry Propertylabel in the coastline feature model.- Return type:
PropertyNameor None
Note
This can return None if this feature type represents an abstract feature class (ie, those feature classes tagged “Class Type: abstract” in the GPGIM).
Added in version 0.43.
- get_name()
Returns the unqualified name.
- Return type:
string
This is the fully qualified name minus the
gpml:prefix (if created with create_gpml()).For example,
Coastline.
- get_namespace()
Returns the namespace URI.
- Return type:
string
For example, the
gpmlnamespace alias has the namespacehttp://www.gplates.org/gplates.
- get_namespace_alias()
Returns the namespace alias.
- Return type:
string
For example,
gpml(if created with create_gpml()).
- to_qualified_string()
Returns the fully qualified name.
- Return type:
string
For example,
gpml:Coastline.