geonode-pycsw 3.0.0b2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- geonode_pycsw-3.0.0b2.dist-info/METADATA +73 -0
- geonode_pycsw-3.0.0b2.dist-info/RECORD +382 -0
- geonode_pycsw-3.0.0b2.dist-info/WHEEL +5 -0
- geonode_pycsw-3.0.0b2.dist-info/entry_points.txt +2 -0
- geonode_pycsw-3.0.0b2.dist-info/licenses/LICENSE.txt +26 -0
- geonode_pycsw-3.0.0b2.dist-info/top_level.txt +1 -0
- pycsw/__init__.py +33 -0
- pycsw/core/__init__.py +29 -0
- pycsw/core/admin.py +703 -0
- pycsw/core/config.py +621 -0
- pycsw/core/etree.py +43 -0
- pycsw/core/formats/__init__.py +29 -0
- pycsw/core/formats/fmt_json.py +69 -0
- pycsw/core/log.py +71 -0
- pycsw/core/metadata.py +1996 -0
- pycsw/core/pygeofilter_evaluate.py +83 -0
- pycsw/core/repository.py +941 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/_wrapper.xsd +14 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswAll.xsd +33 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswCommon.xsd +71 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswGetCapabilities.xsd +80 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswGetDomain.xsd +146 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswGetRecordById.xsd +58 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswGetRecords.xsd +391 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswHarvest.xsd +95 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswTransaction.xsd +187 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/cswUnHarvest.xsd +77 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/rec-dcmes.xsd +245 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/rec-dcterms.xsd +101 -0
- pycsw/core/schemas/ogc/cat/csw/3.0/record.xsd +170 -0
- pycsw/core/schemas/ogc/csw/2.0.2/CSW-discovery.xsd +494 -0
- pycsw/core/schemas/ogc/csw/2.0.2/CSW-publication.xsd +242 -0
- pycsw/core/schemas/ogc/csw/2.0.2/rec-dcmes.xsd +199 -0
- pycsw/core/schemas/ogc/csw/2.0.2/rec-dcterms.xsd +94 -0
- pycsw/core/schemas/ogc/csw/2.0.2/record.xsd +138 -0
- pycsw/core/schemas/ogc/filter/1.1.0/expr.xsd +67 -0
- pycsw/core/schemas/ogc/filter/1.1.0/filter.xsd +265 -0
- pycsw/core/schemas/ogc/filter/1.1.0/filterCapabilities.xsd +171 -0
- pycsw/core/schemas/ogc/filter/1.1.0/sort.xsd +46 -0
- pycsw/core/schemas/ogc/filter/2.0/_wrapper.xsd +5 -0
- pycsw/core/schemas/ogc/filter/2.0/expr.xsd +44 -0
- pycsw/core/schemas/ogc/filter/2.0/filter.xsd +396 -0
- pycsw/core/schemas/ogc/filter/2.0/filterAll.xsd +23 -0
- pycsw/core/schemas/ogc/filter/2.0/filterCapabilities.xsd +286 -0
- pycsw/core/schemas/ogc/filter/2.0/query.xsd +70 -0
- pycsw/core/schemas/ogc/filter/2.0/sort.xsd +49 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/basicTypes.xsd +278 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/coordinateOperations.xsd +789 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/coordinateReferenceSystems.xsd +429 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/coordinateSystems.xsd +408 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/coverage.xsd +451 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/dataQuality.xsd +129 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/datums.xsd +484 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/defaultStyle.xsd +454 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/dictionary.xsd +137 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/direction.xsd +72 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/dynamicFeature.xsd +115 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/feature.xsd +199 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/geometryAggregates.xsd +430 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/geometryBasic0d1d.xsd +602 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/geometryBasic2d.xsd +213 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/geometryComplexes.xsd +141 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/geometryPrimitives.xsd +1609 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/gml.xsd +22 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/gmlBase.xsd +294 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/grids.xsd +76 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/measures.xsd +200 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/observation.xsd +96 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/referenceSystems.xsd +211 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/temporal.xsd +332 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/temporalReferenceSystems.xsd +251 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/temporalTopology.xsd +186 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/topology.xsd +459 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/units.xsd +170 -0
- pycsw/core/schemas/ogc/gml/3.1.1/base/valueObjects.xsd +361 -0
- pycsw/core/schemas/ogc/gml/3.1.1/smil/smil20-language.xsd +117 -0
- pycsw/core/schemas/ogc/gml/3.1.1/smil/smil20.xsd +234 -0
- pycsw/core/schemas/ogc/gml/3.2.1/basicTypes.xsd +268 -0
- pycsw/core/schemas/ogc/gml/3.2.1/coordinateOperations.xsd +525 -0
- pycsw/core/schemas/ogc/gml/3.2.1/coordinateReferenceSystems.xsd +373 -0
- pycsw/core/schemas/ogc/gml/3.2.1/coordinateSystems.xsd +297 -0
- pycsw/core/schemas/ogc/gml/3.2.1/coverage.xsd +292 -0
- pycsw/core/schemas/ogc/gml/3.2.1/datums.xsd +287 -0
- pycsw/core/schemas/ogc/gml/3.2.1/defaultStyle.xsd +453 -0
- pycsw/core/schemas/ogc/gml/3.2.1/deprecatedTypes.xsd +1133 -0
- pycsw/core/schemas/ogc/gml/3.2.1/dictionary.xsd +90 -0
- pycsw/core/schemas/ogc/gml/3.2.1/direction.xsd +84 -0
- pycsw/core/schemas/ogc/gml/3.2.1/dynamicFeature.xsd +109 -0
- pycsw/core/schemas/ogc/gml/3.2.1/feature.xsd +94 -0
- pycsw/core/schemas/ogc/gml/3.2.1/geometryAggregates.xsd +197 -0
- pycsw/core/schemas/ogc/gml/3.2.1/geometryBasic0d1d.xsd +277 -0
- pycsw/core/schemas/ogc/gml/3.2.1/geometryBasic2d.xsd +124 -0
- pycsw/core/schemas/ogc/gml/3.2.1/geometryComplexes.xsd +95 -0
- pycsw/core/schemas/ogc/gml/3.2.1/geometryPrimitives.xsd +846 -0
- pycsw/core/schemas/ogc/gml/3.2.1/gml.xsd +20 -0
- pycsw/core/schemas/ogc/gml/3.2.1/gmlBase.xsd +185 -0
- pycsw/core/schemas/ogc/gml/3.2.1/grids.xsd +64 -0
- pycsw/core/schemas/ogc/gml/3.2.1/measures.xsd +68 -0
- pycsw/core/schemas/ogc/gml/3.2.1/observation.xsd +95 -0
- pycsw/core/schemas/ogc/gml/3.2.1/referenceSystems.xsd +70 -0
- pycsw/core/schemas/ogc/gml/3.2.1/temporal.xsd +269 -0
- pycsw/core/schemas/ogc/gml/3.2.1/temporalReferenceSystems.xsd +189 -0
- pycsw/core/schemas/ogc/gml/3.2.1/temporalTopology.xsd +119 -0
- pycsw/core/schemas/ogc/gml/3.2.1/topology.xsd +386 -0
- pycsw/core/schemas/ogc/gml/3.2.1/units.xsd +162 -0
- pycsw/core/schemas/ogc/gml/3.2.1/valueObjects.xsd +205 -0
- pycsw/core/schemas/ogc/ogcapi/records/part1/1.0/ogcapi-records-1.yaml +932 -0
- pycsw/core/schemas/ogc/ows/1.0.0/ows19115subset.xsd +222 -0
- pycsw/core/schemas/ogc/ows/1.0.0/owsAll.xsd +20 -0
- pycsw/core/schemas/ogc/ows/1.0.0/owsCommon.xsd +155 -0
- pycsw/core/schemas/ogc/ows/1.0.0/owsDataIdentification.xsd +112 -0
- pycsw/core/schemas/ogc/ows/1.0.0/owsExceptionReport.xsd +67 -0
- pycsw/core/schemas/ogc/ows/1.0.0/owsGetCapabilities.xsd +108 -0
- pycsw/core/schemas/ogc/ows/1.0.0/owsOperationsMetadata.xsd +161 -0
- pycsw/core/schemas/ogc/ows/1.0.0/owsServiceIdentification.xsd +55 -0
- pycsw/core/schemas/ogc/ows/1.0.0/owsServiceProvider.xsd +46 -0
- pycsw/core/schemas/ogc/ows/1.1.0/ows19115subset.xsd +236 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsAll.xsd +23 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsCommon.xsd +158 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsContents.xsd +87 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsDataIdentification.xsd +128 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsDomainType.xsd +280 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsExceptionReport.xsd +77 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsGetCapabilities.xsd +113 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsGetResourceByID.xsd +52 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsInputOutputData.xsd +60 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsManifest.xsd +125 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsOperationsMetadata.xsd +141 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsServiceIdentification.xsd +61 -0
- pycsw/core/schemas/ogc/ows/1.1.0/owsServiceProvider.xsd +48 -0
- pycsw/core/schemas/ogc/ows/2.0/ows19115subset.xsd +364 -0
- pycsw/core/schemas/ogc/ows/2.0/owsAdditionalParameters.xsd +114 -0
- pycsw/core/schemas/ogc/ows/2.0/owsAll.xsd +29 -0
- pycsw/core/schemas/ogc/ows/2.0/owsCommon.xsd +275 -0
- pycsw/core/schemas/ogc/ows/2.0/owsContents.xsd +163 -0
- pycsw/core/schemas/ogc/ows/2.0/owsDataIdentification.xsd +202 -0
- pycsw/core/schemas/ogc/ows/2.0/owsDomainType.xsd +388 -0
- pycsw/core/schemas/ogc/ows/2.0/owsExceptionReport.xsd +126 -0
- pycsw/core/schemas/ogc/ows/2.0/owsGetCapabilities.xsd +220 -0
- pycsw/core/schemas/ogc/ows/2.0/owsGetResourceByID.xsd +83 -0
- pycsw/core/schemas/ogc/ows/2.0/owsInputOutputData.xsd +98 -0
- pycsw/core/schemas/ogc/ows/2.0/owsManifest.xsd +181 -0
- pycsw/core/schemas/ogc/ows/2.0/owsOperationsMetadata.xsd +234 -0
- pycsw/core/schemas/ogc/ows/2.0/owsServiceIdentification.xsd +98 -0
- pycsw/core/schemas/ogc/ows/2.0/owsServiceProvider.xsd +64 -0
- pycsw/core/schemas/w3c/1999/xlink.xsd +271 -0
- pycsw/core/schemas/w3c/2001/xml.xsd +287 -0
- pycsw/core/util.py +552 -0
- pycsw/oaipmh.py +311 -0
- pycsw/ogc/__init__.py +29 -0
- pycsw/ogc/api/__init__.py +28 -0
- pycsw/ogc/api/oapi.py +558 -0
- pycsw/ogc/api/records.py +1414 -0
- pycsw/ogc/api/templates/_base.html +76 -0
- pycsw/ogc/api/templates/collection.html +44 -0
- pycsw/ogc/api/templates/collections.html +45 -0
- pycsw/ogc/api/templates/conformance.html +21 -0
- pycsw/ogc/api/templates/exception.html +8 -0
- pycsw/ogc/api/templates/item.html +228 -0
- pycsw/ogc/api/templates/items.html +337 -0
- pycsw/ogc/api/templates/landing_page.html +27 -0
- pycsw/ogc/api/templates/openapi.html +58 -0
- pycsw/ogc/api/templates/queryables.html +50 -0
- pycsw/ogc/api/templates/stac_items.html +173 -0
- pycsw/ogc/api/templates/static/favicon.ico +0 -0
- pycsw/ogc/api/templates/static/logo-horizontal.png +0 -0
- pycsw/ogc/api/templates/static/logo-vertical-darkbg.png +0 -0
- pycsw/ogc/api/util.py +252 -0
- pycsw/ogc/csw/__init__.py +29 -0
- pycsw/ogc/csw/cql.py +133 -0
- pycsw/ogc/csw/csw2.py +2042 -0
- pycsw/ogc/csw/csw3.py +2193 -0
- pycsw/ogc/fes/__init__.py +29 -0
- pycsw/ogc/fes/fes1.py +433 -0
- pycsw/ogc/fes/fes2.py +451 -0
- pycsw/ogc/gml/__init__.py +29 -0
- pycsw/ogc/gml/gml3.py +240 -0
- pycsw/ogc/gml/gml32.py +243 -0
- pycsw/opensearch.py +857 -0
- pycsw/plugins/__init__.py +29 -0
- pycsw/plugins/outputschemas/__init__.py +31 -0
- pycsw/plugins/outputschemas/atom.py +143 -0
- pycsw/plugins/outputschemas/datacite.py +375 -0
- pycsw/plugins/outputschemas/dif.py +213 -0
- pycsw/plugins/outputschemas/fgdc.py +180 -0
- pycsw/plugins/outputschemas/gm03.py +240 -0
- pycsw/plugins/profiles/__init__.py +29 -0
- pycsw/plugins/profiles/apiso/__init__.py +29 -0
- pycsw/plugins/profiles/apiso/apiso.py +757 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/csw/2.0.2/profiles/apiso/1.0.0/apiso.xsd +13 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gco/basicTypes.xsd +429 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gco/gco.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gco/gcoBase.xsd +61 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/applicationSchema.xsd +42 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/citation.xsd +275 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/constraints.xsd +106 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/content.xsd +188 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/dataQuality.xsd +554 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/distribution.xsd +202 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/extent.xsd +205 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/freeText.xsd +122 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/gmd.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/identification.xsd +348 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/maintenance.xsd +86 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/metadataApplication.xsd +175 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/metadataEntity.xsd +70 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/metadataExtension.xsd +99 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/portrayalCatalogue.xsd +36 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/referenceSystem.xsd +100 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmd/spatialRepresentation.xsd +237 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/basicTypes.xsd +267 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/coordinateOperations.xsd +639 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/coordinateReferenceSystems.xsd +526 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/coordinateSystems.xsd +401 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/coverage.xsd +462 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/datums.xsd +342 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/dictionary.xsd +129 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/direction.xsd +80 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/dynamicFeature.xsd +142 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/feature.xsd +215 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/geometryAggregates.xsd +216 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/geometryBasic0d1d.xsd +304 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/geometryBasic2d.xsd +123 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/geometryComplexes.xsd +89 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/geometryPrimitives.xsd +892 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/gml.xsd +14 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/gmlBase.xsd +305 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/grids.xsd +58 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/measures.xsd +167 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/observation.xsd +90 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/referenceSystems.xsd +69 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/temporal.xsd +263 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/temporalReferenceSystems.xsd +183 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/temporalTopology.xsd +124 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/topology.xsd +372 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/units.xsd +156 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gml/valueObjects.xsd +212 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmx/catalogues.xsd +112 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmx/codelistItem.xsd +168 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmx/crsItem.xsd +1030 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmx/extendedTypes.xsd +75 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmx/gmx.xsd +2 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmx/gmxUsage.xsd +127 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gmx/uomItem.xsd +162 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gsr/gsr.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gsr/spatialReferencing.xsd +24 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gss/geometry.xsd +35 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gss/gss.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gts/gts.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/gts/temporalObjects.xsd +34 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/srv/serviceMetadata.xsd +197 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/srv/serviceModel.xsd +220 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20060504/srv/srv.xsd +13 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gco/basicTypes.xsd +431 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gco/gco.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gco/gcoBase.xsd +63 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/applicationSchema.xsd +43 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/citation.xsd +276 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/constraints.xsd +107 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/content.xsd +190 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/dataQuality.xsd +556 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/distribution.xsd +203 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/extent.xsd +206 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/freeText.xsd +123 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/gmd.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/identification.xsd +349 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/maintenance.xsd +87 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/metadataApplication.xsd +176 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/metadataEntity.xsd +71 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/metadataExtension.xsd +100 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/portrayalCatalogue.xsd +37 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/referenceSystem.xsd +101 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmd/spatialRepresentation.xsd +238 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmx/catalogues.xsd +113 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmx/codelistItem.xsd +169 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmx/crsItem.xsd +1031 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmx/extendedTypes.xsd +76 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmx/gmx.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmx/gmxUsage.xsd +128 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gmx/uomItem.xsd +163 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gsr/gsr.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gsr/spatialReferencing.xsd +25 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gss/geometry.xsd +36 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gss/gss.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gts/gts.xsd +12 -0
- pycsw/plugins/profiles/apiso/schemas/ogc/iso/19139/20070417/gts/temporalObjects.xsd +35 -0
- pycsw/plugins/profiles/ebrim/__init__.py +29 -0
- pycsw/plugins/profiles/ebrim/ebrim.py +174 -0
- pycsw/plugins/profiles/ebrim/schemas/ogc/csw/2.0.2/profiles/ebrim/1.0/csw-ebrim-iri.xsd +146 -0
- pycsw/plugins/profiles/ebrim/schemas/ogc/csw/2.0.2/profiles/ebrim/1.0/csw-ebrim.xsd +104 -0
- pycsw/plugins/profiles/iso19115p3/__init__.py +29 -0
- pycsw/plugins/profiles/iso19115p3/iso19115p3.py +854 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cat/1.0/cat.xsd +13 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cat/1.0/catalogues.xsd +53 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cat/1.0/codelistItem.xsd +54 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cat/1.0/crsItem.xsd +181 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cat/1.0/uomItem.xsd +38 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cit/1.0/cit.xsd +7 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cit/1.0/citation.xsd +514 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cit/2.0/cit.xsd +10 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/cit/2.0/citation.xsd +523 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gco/1.0/baseTypes2014.xsd +530 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gco/1.0/gco.xsd +16 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gcx/1.0/extendedTypes.xsd +92 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gcx/1.0/extendedTypes_autoFromShapeChange.xsd +60 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gcx/1.0/gcx.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gex/1.0/extent.xsd +241 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gex/1.0/gex.xsd +9 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gmw/1.0/gmlWrapperTypes2014.xsd +159 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/gmw/1.0/gmw.xsd +14 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/lan/1.0/lan.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/lan/1.0/language.xsd +140 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mac/1.0/acquisitionInformationImagery.xsd +622 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mac/1.0/mac.xsd +11 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mac/2.0/acquisitionInformationImagery.xsd +590 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mac/2.0/event.xsd +108 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mac/2.0/mac.xsd +10 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mas/1.0/applicationSchema.xsd +61 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mas/1.0/mas.xsd +9 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mcc/1.0/AbstractCommonClasses.xsd +358 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mcc/1.0/commonClasses.xsd +220 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mcc/1.0/mcc.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mco/1.0/constraints.xsd +188 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mco/1.0/mco.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/md1/1.0/md1.xsd +9 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/md1/1.0/metadataWExtendedType.xsd +4 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/md2/1.0/md2.xsd +15 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/md2/1.0/metadataWithExtensions.xsd +4 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mda/1.0/mda.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mda/1.0/metadataApplication.xsd +200 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mdb/1.0/mdb.xsd +14 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mdb/1.0/metadataBase.xsd +98 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mdb/2.0/mdb.xsd +20 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mdb/2.0/metadataBase.xsd +102 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mds/1.0/mds.xsd +22 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mds/1.0/metadataDataServices.xsd +4 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mdt/1.0/mdt.xsd +13 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mdt/1.0/metadataTransfer.xsd +111 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mex/1.0/metadataExtension.xsd +156 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mex/1.0/mex.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mmi/1.0/maintenance.xsd +76 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mmi/1.0/mmi.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mpc/1.0/mpc.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mpc/1.0/portrayalCatalogue.xsd +31 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrc/1.0/content.xsd +416 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrc/1.0/contentInformationImagery.xsd +185 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrc/1.0/mrc.xsd +11 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrc/2.0/content.xsd +419 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrc/2.0/contentInformationImagery.xsd +171 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrc/2.0/mrc.xsd +11 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrd/1.0/distribution.xsd +267 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrd/1.0/mrd.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mri/1.0/identification.xsd +517 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mri/1.0/mri.xsd +9 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrl/1.0/lineage.xsd +147 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrl/1.0/lineageImagery.xsd +236 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrl/1.0/mrl.xsd +9 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrl/2.0/lineage.xsd +147 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrl/2.0/lineageImagery.xsd +312 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrl/2.0/mrl.xsd +11 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrs/1.0/mrs.xsd +8 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/mrs/1.0/referenceSystem.xsd +47 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/msr/1.0/msr.xsd +10 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/msr/1.0/spatialRepresentation.xsd +375 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/msr/1.0/spatialRepresentationImagery.xsd +119 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/msr/2.0/msr.xsd +15 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/msr/2.0/spatialRepresentation.xsd +381 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/msr/2.0/spatialRepresentationImagery.xsd +120 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/srv/2.0/serviceInformation.xsd +272 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/srv/2.0/srv.xsd +6 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/srv/2.1/serviceInformation.xsd +278 -0
- pycsw/plugins/profiles/iso19115p3/schemas/ogc/iso/iso19115-3/srv/2.1/srv.xsd +6 -0
- pycsw/plugins/profiles/profile.py +141 -0
- pycsw/plugins/repository/__init__.py +29 -0
- pycsw/plugins/repository/odc/__init__.py +29 -0
- pycsw/plugins/repository/odc/odc.py +153 -0
- pycsw/server.py +938 -0
- pycsw/sru.py +217 -0
- pycsw/stac/__init__.py +29 -0
- pycsw/stac/api.py +571 -0
- pycsw/wsgi.py +233 -0
- pycsw/wsgi_flask.py +345 -0
pycsw/core/config.py
ADDED
|
@@ -0,0 +1,621 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# =================================================================
|
|
3
|
+
#
|
|
4
|
+
# Authors: Tom Kralidis <tomkralidis@gmail.com>
|
|
5
|
+
#
|
|
6
|
+
# Copyright (c) 2016 Tom Kralidis
|
|
7
|
+
#
|
|
8
|
+
# Permission is hereby granted, free of charge, to any person
|
|
9
|
+
# obtaining a copy of this software and associated documentation
|
|
10
|
+
# files (the "Software"), to deal in the Software without
|
|
11
|
+
# restriction, including without limitation the rights to use,
|
|
12
|
+
# copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
13
|
+
# copies of the Software, and to permit persons to whom the
|
|
14
|
+
# Software is furnished to do so, subject to the following
|
|
15
|
+
# conditions:
|
|
16
|
+
#
|
|
17
|
+
# The above copyright notice and this permission notice shall be
|
|
18
|
+
# included in all copies or substantial portions of the Software.
|
|
19
|
+
#
|
|
20
|
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
21
|
+
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
22
|
+
# OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
23
|
+
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
24
|
+
# HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
25
|
+
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
26
|
+
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
27
|
+
# OTHER DEALINGS IN THE SOFTWARE.
|
|
28
|
+
#
|
|
29
|
+
# =================================================================
|
|
30
|
+
|
|
31
|
+
import logging
|
|
32
|
+
from pycsw.core.etree import PARSER
|
|
33
|
+
from pycsw import __version__
|
|
34
|
+
|
|
35
|
+
LOGGER = logging.getLogger(__name__)
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
class StaticContext(object):
|
|
39
|
+
"""core configuration"""
|
|
40
|
+
def __init__(self, prefix='csw30'):
|
|
41
|
+
"""initializer"""
|
|
42
|
+
|
|
43
|
+
LOGGER.debug('Initializing static context')
|
|
44
|
+
self.version = __version__
|
|
45
|
+
|
|
46
|
+
self.ogc_schemas_base = 'http://schemas.opengis.net'
|
|
47
|
+
|
|
48
|
+
self.parser = PARSER
|
|
49
|
+
self.server = None
|
|
50
|
+
|
|
51
|
+
self.languages = {
|
|
52
|
+
'en': 'english',
|
|
53
|
+
'fr': 'french',
|
|
54
|
+
'el': 'greek',
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
self.response_codes = {
|
|
58
|
+
'OK': '200 OK',
|
|
59
|
+
'NotFound': '404 Not Found',
|
|
60
|
+
'InvalidValue': '400 Invalid property value',
|
|
61
|
+
'OperationParsingFailed': '400 Bad Request',
|
|
62
|
+
'OperationProcessingFailed': '403 Server Processing Failed',
|
|
63
|
+
'OperationNotSupported': '400 Not Implemented',
|
|
64
|
+
'MissingParameterValue': '400 Bad Request',
|
|
65
|
+
'InvalidParameterValue': '400 Bad Request',
|
|
66
|
+
'VersionNegotiationFailed': '400 Bad Request',
|
|
67
|
+
'InvalidUpdateSequence': '400 Bad Request',
|
|
68
|
+
'OptionNotSupported': '400 Not Implemented',
|
|
69
|
+
'NoApplicableCode': '400 Internal Server Error'
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
self.namespaces = {
|
|
73
|
+
'atom': 'http://www.w3.org/2005/Atom',
|
|
74
|
+
'csw': 'http://www.opengis.net/cat/csw/2.0.2',
|
|
75
|
+
'csw30': 'http://www.opengis.net/cat/csw/3.0',
|
|
76
|
+
'dc': 'http://purl.org/dc/elements/1.1/',
|
|
77
|
+
'dct': 'http://purl.org/dc/terms/',
|
|
78
|
+
'dif': 'http://gcmd.gsfc.nasa.gov/Aboutus/xml/dif/',
|
|
79
|
+
'fes20': 'http://www.opengis.net/fes/2.0',
|
|
80
|
+
'fgdc': 'http://www.opengis.net/cat/csw/csdgm',
|
|
81
|
+
'gm03': 'http://www.interlis.ch/INTERLIS2.3',
|
|
82
|
+
'gmd': 'http://www.isotc211.org/2005/gmd',
|
|
83
|
+
'gml': 'http://www.opengis.net/gml',
|
|
84
|
+
'gml32': 'http://www.opengis.net/gml/3.2',
|
|
85
|
+
'mdb': 'http://standards.iso.org/iso/19115/-3/mdb/2.0',
|
|
86
|
+
'ogc': 'http://www.opengis.net/ogc',
|
|
87
|
+
'os': 'http://a9.com/-/spec/opensearch/1.1/',
|
|
88
|
+
'ows': 'http://www.opengis.net/ows',
|
|
89
|
+
'ows11': 'http://www.opengis.net/ows/1.1',
|
|
90
|
+
'ows20': 'http://www.opengis.net/ows/2.0',
|
|
91
|
+
'rdf': 'http://www.w3.org/1999/02/22-rdf-syntax-ns#',
|
|
92
|
+
'sitemap': 'http://www.sitemaps.org/schemas/sitemap/0.9',
|
|
93
|
+
'soapenv': 'http://www.w3.org/2003/05/soap-envelope',
|
|
94
|
+
'xlink': 'http://www.w3.org/1999/xlink',
|
|
95
|
+
'xs': 'http://www.w3.org/2001/XMLSchema',
|
|
96
|
+
'xsi': 'http://www.w3.org/2001/XMLSchema-instance'
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
self.keep_ns_prefixes = [
|
|
100
|
+
'csw', 'dc', 'dct', 'gmd', 'gml', 'gml32', 'ows', 'xs'
|
|
101
|
+
]
|
|
102
|
+
|
|
103
|
+
self.md_core_model = {
|
|
104
|
+
'typename': 'pycsw:CoreMetadata',
|
|
105
|
+
'outputschema': 'http://pycsw.org/metadata',
|
|
106
|
+
'mappings': {
|
|
107
|
+
'pycsw:Identifier': 'identifier',
|
|
108
|
+
# CSW typename (e.g. csw:Record, md:MD_Metadata)
|
|
109
|
+
'pycsw:Typename': 'typename',
|
|
110
|
+
# schema namespace, i.e. http://www.isotc211.org/2005/gmd
|
|
111
|
+
'pycsw:Schema': 'schema',
|
|
112
|
+
# origin of resource, either 'local', or URL to web service
|
|
113
|
+
'pycsw:MdSource': 'mdsource',
|
|
114
|
+
# date of insertion
|
|
115
|
+
'pycsw:InsertDate': 'insert_date', # date of insertion
|
|
116
|
+
# raw XML metadata
|
|
117
|
+
'pycsw:XML': 'xml',
|
|
118
|
+
# raw metadata payload, xml to be migrated to this in the future
|
|
119
|
+
'pycsw:Metadata': 'metadata',
|
|
120
|
+
# raw metadata payload type, xml as default for now
|
|
121
|
+
'pycsw:MetadataType': 'metadata_type',
|
|
122
|
+
# bag of metadata element and attributes ONLY, no XML tags
|
|
123
|
+
'pycsw:AnyText': 'anytext',
|
|
124
|
+
'pycsw:Language': 'language',
|
|
125
|
+
'pycsw:Title': 'title',
|
|
126
|
+
'pycsw:Abstract': 'abstract',
|
|
127
|
+
'pycsw:Edition': 'edition',
|
|
128
|
+
'pycsw:Keywords': 'keywords',
|
|
129
|
+
'pycsw:KeywordType': 'keywordstype',
|
|
130
|
+
'pycsw:Themes': 'themes',
|
|
131
|
+
'pycsw:Format': 'format',
|
|
132
|
+
'pycsw:Source': 'source',
|
|
133
|
+
'pycsw:Date': 'date',
|
|
134
|
+
'pycsw:Modified': 'date_modified',
|
|
135
|
+
'pycsw:Type': 'type',
|
|
136
|
+
# geometry, specified in OGC WKT
|
|
137
|
+
'pycsw:BoundingBox': 'wkt_geometry',
|
|
138
|
+
'pycsw:VertExtentMin': 'vert_extent_min',
|
|
139
|
+
'pycsw:VertExtentMax': 'vert_extent_max',
|
|
140
|
+
'pycsw:CRS': 'crs',
|
|
141
|
+
'pycsw:AlternateTitle': 'title_alternate',
|
|
142
|
+
'pycsw:RevisionDate': 'date_revision',
|
|
143
|
+
'pycsw:CreationDate': 'date_creation',
|
|
144
|
+
'pycsw:PublicationDate': 'date_publication',
|
|
145
|
+
'pycsw:OrganizationName': 'organization',
|
|
146
|
+
'pycsw:SecurityConstraints': 'securityconstraints',
|
|
147
|
+
'pycsw:ParentIdentifier': 'parentidentifier',
|
|
148
|
+
'pycsw:TopicCategory': 'topicategory',
|
|
149
|
+
'pycsw:ResourceLanguage': 'resourcelanguage',
|
|
150
|
+
'pycsw:GeographicDescriptionCode': 'geodescode',
|
|
151
|
+
'pycsw:Denominator': 'denominator',
|
|
152
|
+
'pycsw:DistanceValue': 'distancevalue',
|
|
153
|
+
'pycsw:DistanceUOM': 'distanceuom',
|
|
154
|
+
'pycsw:TempExtent_begin': 'time_begin',
|
|
155
|
+
'pycsw:TempExtent_end': 'time_end',
|
|
156
|
+
'pycsw:ServiceType': 'servicetype',
|
|
157
|
+
'pycsw:ServiceTypeVersion': 'servicetypeversion',
|
|
158
|
+
'pycsw:Operation': 'operation',
|
|
159
|
+
'pycsw:CouplingType': 'couplingtype',
|
|
160
|
+
'pycsw:OperatesOn': 'operateson',
|
|
161
|
+
'pycsw:OperatesOnIdentifier': 'operatesonidentifier',
|
|
162
|
+
'pycsw:OperatesOnName': 'operatesoname',
|
|
163
|
+
'pycsw:Degree': 'degree',
|
|
164
|
+
'pycsw:AccessConstraints': 'accessconstraints',
|
|
165
|
+
'pycsw:OtherConstraints': 'otherconstraints',
|
|
166
|
+
'pycsw:Classification': 'classification',
|
|
167
|
+
'pycsw:ConditionApplyingToAccessAndUse': 'conditionapplyingtoaccessanduse',
|
|
168
|
+
'pycsw:Lineage': 'lineage',
|
|
169
|
+
'pycsw:ResponsiblePartyRole': 'responsiblepartyrole',
|
|
170
|
+
'pycsw:SpecificationTitle': 'specificationtitle',
|
|
171
|
+
'pycsw:SpecificationDate': 'specificationdate',
|
|
172
|
+
'pycsw:SpecificationDateType': 'specificationdatetype',
|
|
173
|
+
'pycsw:Creator': 'creator',
|
|
174
|
+
'pycsw:Publisher': 'publisher',
|
|
175
|
+
'pycsw:Contributor': 'contributor',
|
|
176
|
+
'pycsw:Relation': 'relation',
|
|
177
|
+
'pycsw:Platform': 'platform',
|
|
178
|
+
'pycsw:Instrument': 'instrument',
|
|
179
|
+
'pycsw:SensorType': 'sensortype',
|
|
180
|
+
'pycsw:CloudCover': 'cloudcover',
|
|
181
|
+
'pycsw:Bands': 'bands',
|
|
182
|
+
# links: list of dicts with properties: name, description, protocol, url
|
|
183
|
+
'pycsw:Links': 'links',
|
|
184
|
+
# contacts: list of dicts with properties: name, organization, address, postcode, city, region, country, email, phone, fax, onlineresource, position, role
|
|
185
|
+
'pycsw:Contacts': 'contacts',
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
self.model = None
|
|
190
|
+
|
|
191
|
+
self.models = {
|
|
192
|
+
'csw': {
|
|
193
|
+
'operations_order': [
|
|
194
|
+
'GetCapabilities', 'DescribeRecord', 'GetDomain',
|
|
195
|
+
'GetRecords', 'GetRecordById', 'GetRepositoryItem'
|
|
196
|
+
],
|
|
197
|
+
'operations': {
|
|
198
|
+
'GetCapabilities': {
|
|
199
|
+
'methods': {
|
|
200
|
+
'get': True,
|
|
201
|
+
'post': True,
|
|
202
|
+
},
|
|
203
|
+
'parameters': {
|
|
204
|
+
'sections': {
|
|
205
|
+
'values': ['ServiceIdentification', 'ServiceProvider',
|
|
206
|
+
'OperationsMetadata', 'Filter_Capabilities']
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
'DescribeRecord': {
|
|
211
|
+
'methods': {
|
|
212
|
+
'get': True,
|
|
213
|
+
'post': True,
|
|
214
|
+
},
|
|
215
|
+
'parameters': {
|
|
216
|
+
'schemaLanguage': {
|
|
217
|
+
'values': ['http://www.w3.org/XML/Schema',
|
|
218
|
+
'http://www.w3.org/TR/xmlschema-1/',
|
|
219
|
+
'http://www.w3.org/2001/XMLSchema']
|
|
220
|
+
},
|
|
221
|
+
'typeName': {
|
|
222
|
+
'values': ['csw:Record']
|
|
223
|
+
},
|
|
224
|
+
'outputFormat': {
|
|
225
|
+
'values': ['application/xml', 'application/json']
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
},
|
|
229
|
+
'GetRecords': {
|
|
230
|
+
'methods': {
|
|
231
|
+
'get': True,
|
|
232
|
+
'post': True,
|
|
233
|
+
},
|
|
234
|
+
'parameters': {
|
|
235
|
+
'resultType': {
|
|
236
|
+
'values': ['hits', 'results', 'validate']
|
|
237
|
+
},
|
|
238
|
+
'typeNames': {
|
|
239
|
+
'values': ['csw:Record']
|
|
240
|
+
},
|
|
241
|
+
'outputSchema': {
|
|
242
|
+
'values': ['http://www.opengis.net/cat/csw/2.0.2']
|
|
243
|
+
},
|
|
244
|
+
'outputFormat': {
|
|
245
|
+
'values': ['application/xml', 'application/json']
|
|
246
|
+
},
|
|
247
|
+
'CONSTRAINTLANGUAGE': {
|
|
248
|
+
'values': ['FILTER', 'CQL_TEXT']
|
|
249
|
+
},
|
|
250
|
+
'ElementSetName': {
|
|
251
|
+
'values': ['brief', 'summary', 'full']
|
|
252
|
+
}
|
|
253
|
+
},
|
|
254
|
+
'constraints': {
|
|
255
|
+
}
|
|
256
|
+
},
|
|
257
|
+
'GetRecordById': {
|
|
258
|
+
'methods': {
|
|
259
|
+
'get': True,
|
|
260
|
+
'post': True,
|
|
261
|
+
},
|
|
262
|
+
'parameters': {
|
|
263
|
+
'outputSchema': {
|
|
264
|
+
'values': ['http://www.opengis.net/cat/csw/2.0.2']
|
|
265
|
+
},
|
|
266
|
+
'outputFormat': {
|
|
267
|
+
'values': ['application/xml', 'application/json']
|
|
268
|
+
},
|
|
269
|
+
'ElementSetName': {
|
|
270
|
+
'values': ['brief', 'summary', 'full']
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
},
|
|
274
|
+
'GetRepositoryItem': {
|
|
275
|
+
'methods': {
|
|
276
|
+
'get': True,
|
|
277
|
+
'post': False,
|
|
278
|
+
},
|
|
279
|
+
'parameters': {
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
'parameters': {
|
|
284
|
+
'version': {
|
|
285
|
+
'values': ['2.0.2', '3.0.0']
|
|
286
|
+
},
|
|
287
|
+
'service': {
|
|
288
|
+
'values': ['CSW']
|
|
289
|
+
}
|
|
290
|
+
},
|
|
291
|
+
'constraints': {
|
|
292
|
+
'MaxRecordDefault': {
|
|
293
|
+
'values': ['10']
|
|
294
|
+
},
|
|
295
|
+
'PostEncoding': {
|
|
296
|
+
'values': ['XML', 'SOAP']
|
|
297
|
+
},
|
|
298
|
+
'XPathQueryables': {
|
|
299
|
+
'values': ['allowed']
|
|
300
|
+
}
|
|
301
|
+
},
|
|
302
|
+
'typenames': {
|
|
303
|
+
'csw:Record': {
|
|
304
|
+
'outputschema': 'http://www.opengis.net/cat/csw/2.0.2',
|
|
305
|
+
'queryables': {
|
|
306
|
+
'SupportedDublinCoreQueryables': {
|
|
307
|
+
# map Dublin Core queryables to core metadata model
|
|
308
|
+
'dc:title':
|
|
309
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Title']},
|
|
310
|
+
'dct:alternative':
|
|
311
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:AlternateTitle']},
|
|
312
|
+
'dc:creator':
|
|
313
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Creator']},
|
|
314
|
+
'dc:subject':
|
|
315
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Keywords']},
|
|
316
|
+
'dct:abstract':
|
|
317
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Abstract']},
|
|
318
|
+
'dc:publisher':
|
|
319
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Publisher']},
|
|
320
|
+
'dc:contributor':
|
|
321
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Contributor']},
|
|
322
|
+
'dct:modified':
|
|
323
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Modified']},
|
|
324
|
+
'dc:date':
|
|
325
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Date']},
|
|
326
|
+
'dc:type':
|
|
327
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Type']},
|
|
328
|
+
'dc:format':
|
|
329
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Format']},
|
|
330
|
+
'dc:identifier':
|
|
331
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Identifier']},
|
|
332
|
+
'dc:source':
|
|
333
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Source']},
|
|
334
|
+
'dc:language':
|
|
335
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Language']},
|
|
336
|
+
'dc:relation':
|
|
337
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Relation']},
|
|
338
|
+
'dc:rights':
|
|
339
|
+
{'dbcol':
|
|
340
|
+
self.md_core_model['mappings']['pycsw:AccessConstraints']},
|
|
341
|
+
'dct:spatial':
|
|
342
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:CRS']},
|
|
343
|
+
# bbox and full text map to internal fixed columns
|
|
344
|
+
'ows:BoundingBox':
|
|
345
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:BoundingBox']},
|
|
346
|
+
'csw:AnyText':
|
|
347
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:AnyText']},
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
},
|
|
353
|
+
'csw30': {
|
|
354
|
+
'operations_order': [
|
|
355
|
+
'GetCapabilities', 'GetDomain', 'GetRecords',
|
|
356
|
+
'GetRecordById', 'GetRepositoryItem'
|
|
357
|
+
],
|
|
358
|
+
'operations': {
|
|
359
|
+
'GetCapabilities': {
|
|
360
|
+
'methods': {
|
|
361
|
+
'get': True,
|
|
362
|
+
'post': True,
|
|
363
|
+
},
|
|
364
|
+
'parameters': {
|
|
365
|
+
'acceptVersions': {
|
|
366
|
+
'values': ['2.0.2', '3.0.0']
|
|
367
|
+
},
|
|
368
|
+
'acceptFormats': {
|
|
369
|
+
'values': ['text/xml', 'application/xml']
|
|
370
|
+
},
|
|
371
|
+
'sections': {
|
|
372
|
+
'values': ['ServiceIdentification', 'ServiceProvider',
|
|
373
|
+
'OperationsMetadata', 'Filter_Capabilities', 'All']
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
},
|
|
377
|
+
'GetRecords': {
|
|
378
|
+
'methods': {
|
|
379
|
+
'get': True,
|
|
380
|
+
'post': True,
|
|
381
|
+
},
|
|
382
|
+
'parameters': {
|
|
383
|
+
'typeNames': {
|
|
384
|
+
'values': ['csw:Record', 'csw30:Record']
|
|
385
|
+
},
|
|
386
|
+
'outputSchema': {
|
|
387
|
+
'values': ['http://www.opengis.net/cat/csw/3.0']
|
|
388
|
+
},
|
|
389
|
+
'outputFormat': {
|
|
390
|
+
'values': ['application/xml', 'application/json', 'application/atom+xml']
|
|
391
|
+
},
|
|
392
|
+
'CONSTRAINTLANGUAGE': {
|
|
393
|
+
'values': ['FILTER', 'CQL_TEXT']
|
|
394
|
+
},
|
|
395
|
+
'ElementSetName': {
|
|
396
|
+
'values': ['brief', 'summary', 'full']
|
|
397
|
+
}
|
|
398
|
+
},
|
|
399
|
+
'constraints': {
|
|
400
|
+
}
|
|
401
|
+
},
|
|
402
|
+
'GetRecordById': {
|
|
403
|
+
'methods': {
|
|
404
|
+
'get': True,
|
|
405
|
+
'post': True,
|
|
406
|
+
},
|
|
407
|
+
'parameters': {
|
|
408
|
+
'outputSchema': {
|
|
409
|
+
'values': ['http://www.opengis.net/cat/csw/3.0']
|
|
410
|
+
},
|
|
411
|
+
'outputFormat': {
|
|
412
|
+
'values': ['application/xml', 'application/json', 'application/atom+xml']
|
|
413
|
+
},
|
|
414
|
+
'ElementSetName': {
|
|
415
|
+
'values': ['brief', 'summary', 'full']
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
},
|
|
419
|
+
'GetRepositoryItem': {
|
|
420
|
+
'methods': {
|
|
421
|
+
'get': True,
|
|
422
|
+
'post': False,
|
|
423
|
+
},
|
|
424
|
+
'parameters': {
|
|
425
|
+
}
|
|
426
|
+
}
|
|
427
|
+
},
|
|
428
|
+
'parameters': {
|
|
429
|
+
'version': {
|
|
430
|
+
'values': ['2.0.2', '3.0.0']
|
|
431
|
+
},
|
|
432
|
+
'service': {
|
|
433
|
+
'values': ['CSW']
|
|
434
|
+
}
|
|
435
|
+
},
|
|
436
|
+
'constraints': {
|
|
437
|
+
'MaxRecordDefault': {
|
|
438
|
+
'values': ['10']
|
|
439
|
+
},
|
|
440
|
+
'PostEncoding': {
|
|
441
|
+
'values': ['XML', 'SOAP']
|
|
442
|
+
},
|
|
443
|
+
'XPathQueryables': {
|
|
444
|
+
'values': ['allowed']
|
|
445
|
+
},
|
|
446
|
+
'http://www.opengis.net/spec/csw/3.0/conf/OpenSearch': {
|
|
447
|
+
'values': ['TRUE']
|
|
448
|
+
},
|
|
449
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetCapabilities-XML': {
|
|
450
|
+
'values': ['TRUE']
|
|
451
|
+
},
|
|
452
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetRecordById-XML': {
|
|
453
|
+
'values': ['TRUE']
|
|
454
|
+
},
|
|
455
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetRecords-Basic-XML': {
|
|
456
|
+
'values': ['TRUE']
|
|
457
|
+
},
|
|
458
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetRecords-Distributed-XML': {
|
|
459
|
+
'values': ['TRUE']
|
|
460
|
+
},
|
|
461
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetRecords-Distributed-KVP': {
|
|
462
|
+
'values': ['TRUE']
|
|
463
|
+
},
|
|
464
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetRecords-Async-XML': {
|
|
465
|
+
'values': ['TRUE']
|
|
466
|
+
},
|
|
467
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetRecords-Async-KVP': {
|
|
468
|
+
'values': ['TRUE']
|
|
469
|
+
},
|
|
470
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetDomain-XML': {
|
|
471
|
+
'values': ['TRUE']
|
|
472
|
+
},
|
|
473
|
+
'http://www.opengis.net/spec/csw/3.0/conf/GetDomain-KVP': {
|
|
474
|
+
'values': ['TRUE']
|
|
475
|
+
},
|
|
476
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Transaction': {
|
|
477
|
+
'values': ['TRUE']
|
|
478
|
+
},
|
|
479
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Harvest-Basic-XML': {
|
|
480
|
+
'values': ['TRUE']
|
|
481
|
+
},
|
|
482
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Harvest-Basic-KVP': {
|
|
483
|
+
'values': ['TRUE']
|
|
484
|
+
},
|
|
485
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Harvest-Async-XML': {
|
|
486
|
+
'values': ['TRUE']
|
|
487
|
+
},
|
|
488
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Harvest-Async-KVP': {
|
|
489
|
+
'values': ['TRUE']
|
|
490
|
+
},
|
|
491
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Harvest-Periodic-XML': {
|
|
492
|
+
'values': ['TRUE']
|
|
493
|
+
},
|
|
494
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Harvest-Periodic-KVP': {
|
|
495
|
+
'values': ['TRUE']
|
|
496
|
+
},
|
|
497
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Filter-CQL': {
|
|
498
|
+
'values': ['TRUE']
|
|
499
|
+
},
|
|
500
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Filter-FES-XML': {
|
|
501
|
+
'values': ['TRUE']
|
|
502
|
+
},
|
|
503
|
+
'http://www.opengis.net/spec/csw/3.0/conf/Filter-FES-KVP-Advanced': {
|
|
504
|
+
'values': ['TRUE']
|
|
505
|
+
},
|
|
506
|
+
'http://www.opengis.net/spec/csw/3.0/conf/SupportedGMLVersions': {
|
|
507
|
+
'values': ['http://www.opengis.net/gml/3.2']
|
|
508
|
+
},
|
|
509
|
+
'http://www.opengis.net/spec/csw/3.0/conf/DefaultSortingAlgorithm': {
|
|
510
|
+
'values': ['TRUE']
|
|
511
|
+
},
|
|
512
|
+
'http://www.opengis.net/spec/csw/3.0/conf/CoreQueryables': {
|
|
513
|
+
'values': ['TRUE']
|
|
514
|
+
},
|
|
515
|
+
'http://www.opengis.net/spec/csw/3.0/conf/CoreSortables': {
|
|
516
|
+
'values': ['TRUE']
|
|
517
|
+
}
|
|
518
|
+
},
|
|
519
|
+
'typenames': {
|
|
520
|
+
'csw:Record': {
|
|
521
|
+
'outputschema': 'http://www.opengis.net/cat/csw/3.0',
|
|
522
|
+
'queryables': {
|
|
523
|
+
'SupportedDublinCoreQueryables': {
|
|
524
|
+
# map Dublin Core queryables to core metadata model
|
|
525
|
+
'dc:title':
|
|
526
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Title']},
|
|
527
|
+
'dct:alternative':
|
|
528
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:AlternateTitle']},
|
|
529
|
+
'dc:creator':
|
|
530
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Creator']},
|
|
531
|
+
'dc:subject':
|
|
532
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Keywords']},
|
|
533
|
+
'dct:abstract':
|
|
534
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Abstract']},
|
|
535
|
+
'dc:publisher':
|
|
536
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Publisher']},
|
|
537
|
+
'dc:contributor':
|
|
538
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Contributor']},
|
|
539
|
+
'dct:modified':
|
|
540
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Modified']},
|
|
541
|
+
'dc:date':
|
|
542
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Date']},
|
|
543
|
+
'dc:type':
|
|
544
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Type']},
|
|
545
|
+
'dc:format':
|
|
546
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Format']},
|
|
547
|
+
'dc:identifier':
|
|
548
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Identifier']},
|
|
549
|
+
'dc:source':
|
|
550
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Source']},
|
|
551
|
+
'dc:language':
|
|
552
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Language']},
|
|
553
|
+
'dc:relation':
|
|
554
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:Relation']},
|
|
555
|
+
'dc:rights':
|
|
556
|
+
{'dbcol':
|
|
557
|
+
self.md_core_model['mappings']['pycsw:AccessConstraints']},
|
|
558
|
+
'dct:spatial':
|
|
559
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:CRS']},
|
|
560
|
+
# bbox and full text map to internal fixed columns
|
|
561
|
+
'ows:BoundingBox':
|
|
562
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:BoundingBox']},
|
|
563
|
+
'csw:AnyText':
|
|
564
|
+
{'dbcol': self.md_core_model['mappings']['pycsw:AnyText']},
|
|
565
|
+
}
|
|
566
|
+
}
|
|
567
|
+
}
|
|
568
|
+
}
|
|
569
|
+
}
|
|
570
|
+
}
|
|
571
|
+
self.set_model(prefix)
|
|
572
|
+
|
|
573
|
+
def set_model(self, prefix):
|
|
574
|
+
"""sets model given request context"""
|
|
575
|
+
|
|
576
|
+
self.model = self.models[prefix]
|
|
577
|
+
|
|
578
|
+
def gen_domains(self):
|
|
579
|
+
"""Generate parameter domain model"""
|
|
580
|
+
domain = {}
|
|
581
|
+
domain['methods'] = {'get': True, 'post': True}
|
|
582
|
+
domain['parameters'] = {'ParameterName': {'values': []}}
|
|
583
|
+
for operation in self.model['operations'].keys():
|
|
584
|
+
for parameter in self.model['operations'][operation]['parameters']:
|
|
585
|
+
domain['parameters']['ParameterName']['values'].append('%s.%s' %
|
|
586
|
+
(operation, parameter))
|
|
587
|
+
return domain
|
|
588
|
+
|
|
589
|
+
def refresh_dc(self, mappings):
|
|
590
|
+
"""Refresh Dublin Core mappings"""
|
|
591
|
+
|
|
592
|
+
LOGGER.debug('refreshing Dublin Core mappings with %s', str(mappings))
|
|
593
|
+
|
|
594
|
+
defaults = {
|
|
595
|
+
'dc:title': 'pycsw:Title',
|
|
596
|
+
'dct:alternative': 'pycsw:AlternateTitle',
|
|
597
|
+
'dc:creator': 'pycsw:Creator',
|
|
598
|
+
'dc:subject': 'pycsw:Keywords',
|
|
599
|
+
'dct:abstract': 'pycsw:Abstract',
|
|
600
|
+
'dc:publisher': 'pycsw:Publisher',
|
|
601
|
+
'dc:contributor': 'pycsw:Contributor',
|
|
602
|
+
'dct:modified': 'pycsw:Modified',
|
|
603
|
+
'dc:date': 'pycsw:Date',
|
|
604
|
+
'dc:type': 'pycsw:Type',
|
|
605
|
+
'dc:format': 'pycsw:Format',
|
|
606
|
+
'dc:identifier': 'pycsw:Identifier',
|
|
607
|
+
'dc:source': 'pycsw:Source',
|
|
608
|
+
'dc:language': 'pycsw:Language',
|
|
609
|
+
'dc:relation': 'pycsw:Relation',
|
|
610
|
+
'dc:rights': 'pycsw:AccessConstraints',
|
|
611
|
+
'dct:spatial': 'pycsw:CRS',
|
|
612
|
+
'ows:BoundingBox': 'pycsw:BoundingBox',
|
|
613
|
+
'csw:AnyText': 'pycsw:AnyText',
|
|
614
|
+
}
|
|
615
|
+
|
|
616
|
+
for k, val in defaults.items():
|
|
617
|
+
for model, params in self.models.items():
|
|
618
|
+
queryables = params['typenames']['csw:Record']['queryables']
|
|
619
|
+
queryables['SupportedDublinCoreQueryables'][k] = {
|
|
620
|
+
'dbcol': mappings['mappings'][val]
|
|
621
|
+
}
|
pycsw/core/etree.py
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# =================================================================
|
|
3
|
+
#
|
|
4
|
+
# Authors: Tom Kralidis <tomkralidis@gmail.com>
|
|
5
|
+
# Ricardo Garcia Silva <ricardo.garcia.silva@gmail.com>
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2015 Tom Kralidis
|
|
8
|
+
# Copyright (c) 2017 Ricardo Garcia Silva
|
|
9
|
+
#
|
|
10
|
+
# Permission is hereby granted, free of charge, to any person
|
|
11
|
+
# obtaining a copy of this software and associated documentation
|
|
12
|
+
# files (the "Software"), to deal in the Software without
|
|
13
|
+
# restriction, including without limitation the rights to use,
|
|
14
|
+
# copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
15
|
+
# copies of the Software, and to permit persons to whom the
|
|
16
|
+
# Software is furnished to do so, subject to the following
|
|
17
|
+
# conditions:
|
|
18
|
+
#
|
|
19
|
+
# The above copyright notice and this permission notice shall be
|
|
20
|
+
# included in all copies or substantial portions of the Software.
|
|
21
|
+
#
|
|
22
|
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
23
|
+
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
24
|
+
# OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
25
|
+
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
26
|
+
# HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
27
|
+
# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
28
|
+
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
29
|
+
# OTHER DEALINGS IN THE SOFTWARE.
|
|
30
|
+
#
|
|
31
|
+
# =================================================================
|
|
32
|
+
|
|
33
|
+
"""Custom etree objects for pycsw
|
|
34
|
+
|
|
35
|
+
Be sure to use the ``PARSER`` object defined in this module whenever it is
|
|
36
|
+
necessary to parse external XML objects. This parser offers better protection
|
|
37
|
+
against known XML attacks.
|
|
38
|
+
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
from lxml import etree
|
|
42
|
+
|
|
43
|
+
PARSER = etree.XMLParser(resolve_entities=False)
|