Service Models

class registry.models.service.CatalogueService(xml_backup_file, access_constraints, fees, use_limitation, license_source_note, licence, id, date_stamp, file_identifier, origin, origin_url, title, abstract, is_broken, is_customized, insufficient_quality, is_searchable, hits, service_contact, metadata_contact, is_active, version, service_url)
exception DoesNotExist
exception MultipleObjectsReturned
save_without_historical_record(*args, **kwargs)

Save model without saving a historical record

Make sure you know what you’re doing before you use this method.

class registry.models.service.CatalogueServiceOperationUrl(id, method, url, operation, service)
exception DoesNotExist
exception MultipleObjectsReturned
class registry.models.service.FeatureType(*args, **kwargs)

Concrete model class to store parsed FeatureType.

Attr objects

custom models manager registry.managers.service.FeatureTypeManager

exception DoesNotExist
exception MultipleObjectsReturned
create_element_instances()

Return the created FeatureTypeElement record(s)

fetch_describe_feature_type_document(save=True)

Return the fetched described feature type document and update the content if save is True

parse()

Return the parsed self.remote_content

Raises:

ValueError: if self.remote_content is null

save(*args, **kwargs)

Custom save function to handle activate process for the feature type and his related service. If the given feature type shall be active, the feature type it self and the related registry.models.service.Service will be updated with is_active=True. If the given feature type shall be inactive only the feature type it self will be updated with is_active=False.

save_without_historical_record(*args, **kwargs)

Save model without saving a historical record

Make sure you know what you’re doing before you use this method.

class registry.models.service.FeatureTypeProperty(id, max_occurs, min_occurs, name, data_type, required, feature_type)
exception DoesNotExist
exception MultipleObjectsReturned
class registry.models.service.Layer(*args, **kwargs)

Concrete model class to store parsed layers.

Attr objects

custom models manager registry.managers.service.LayerManager

exception DoesNotExist
exception MultipleObjectsReturned
get_map_url(bbox: Optional[django.contrib.gis.geos.polygon.Polygon] = None, format: Optional[str] = None, style: Optional[registry.models.metadata.Style] = None, width: int = 1, height: int = 1, transparent: bool = False, bgcolor='=0xFFFFFF', exceptions='XML') str

Returns the url for the GetMap operation, to use with http get method to request this specific layer.

save(*args, **kwargs)

Custom save function to handle activate process for the layer, all his descendants and his related service. If the given layer shall be active, the complete family (mptt.models.MPTTModel.get_family()) of this layer and the related registry.models.service.Service will be updated with ìs_active=True. If the given layer shall be inactive, all descendants (mptt.models.MPTTModel.get_descendants()) of this layer will be updated with is_active=False.

save_without_historical_record(*args, **kwargs)

Save model without saving a historical record

Make sure you know what you’re doing before you use this method.

class registry.models.service.OgcService(*args, **kwargs)

Abstract Service model to store OGC service.

save(*args, **kwargs)

Save the current instance. Override this in a subclass if you want to control the saving process.

The ‘force_insert’ and ‘force_update’ parameters can be used to insist that the “save” must be an SQL insert or update (or equivalent for non-SQL backends), respectively. Normally, they should not be set.

class registry.models.service.OperationUrl(*args, **kwargs)

Concrete model class to store operation urls for registered services

With that urls we can perform all needed request to a given service.

class registry.models.service.ServiceElement(*args, **kwargs)

Abstract model class to generalize some fields and functions for layers and feature types

class registry.models.service.WebFeatureService(xml_backup_file, access_constraints, fees, use_limitation, license_source_note, licence, id, date_stamp, file_identifier, origin, origin_url, title, abstract, is_broken, is_customized, insufficient_quality, is_searchable, hits, service_contact, metadata_contact, is_active, version, service_url)
exception DoesNotExist
exception MultipleObjectsReturned
save_without_historical_record(*args, **kwargs)

Save model without saving a historical record

Make sure you know what you’re doing before you use this method.

class registry.models.service.WebFeatureServiceOperationUrl(id, method, url, operation, service)
exception DoesNotExist
exception MultipleObjectsReturned
class registry.models.service.WebMapService(xml_backup_file, access_constraints, fees, use_limitation, license_source_note, licence, id, date_stamp, file_identifier, origin, origin_url, title, abstract, is_broken, is_customized, insufficient_quality, is_searchable, hits, service_contact, metadata_contact, is_active, version, service_url)
exception DoesNotExist
exception MultipleObjectsReturned
save_without_historical_record(*args, **kwargs)

Save model without saving a historical record

Make sure you know what you’re doing before you use this method.

class registry.models.service.WebMapServiceOperationUrl(id, method, url, operation, service)
exception DoesNotExist
exception MultipleObjectsReturned