Merge pull request #311 from ckan/Zharktas-patch-1
Use csw2 from owslib
This commit is contained in:
commit
7d39faa027
|
@ -65,7 +65,7 @@ class CswService(OwsService):
|
||||||
"""
|
"""
|
||||||
Perform various operations on a CSW service
|
Perform various operations on a CSW service
|
||||||
"""
|
"""
|
||||||
from owslib.csw import CatalogueServiceWeb as _Implementation
|
from owslib.catalogue.csw2 import CatalogueServiceWeb as _Implementation
|
||||||
|
|
||||||
def __init__(self, endpoint=None):
|
def __init__(self, endpoint=None):
|
||||||
super(CswService, self).__init__(endpoint)
|
super(CswService, self).__init__(endpoint)
|
||||||
|
@ -74,7 +74,7 @@ class CswService(OwsService):
|
||||||
def getrecords(self, qtype=None, keywords=[],
|
def getrecords(self, qtype=None, keywords=[],
|
||||||
typenames="csw:Record", esn="brief",
|
typenames="csw:Record", esn="brief",
|
||||||
skip=0, count=10, outputschema="gmd", **kw):
|
skip=0, count=10, outputschema="gmd", **kw):
|
||||||
from owslib.csw import namespaces
|
from owslib.catalogue.csw2 import namespaces
|
||||||
constraints = []
|
constraints = []
|
||||||
csw = self._ows(**kw)
|
csw = self._ows(**kw)
|
||||||
|
|
||||||
|
@ -102,7 +102,7 @@ class CswService(OwsService):
|
||||||
def getidentifiers(self, qtype=None, typenames="csw:Record", esn="brief",
|
def getidentifiers(self, qtype=None, typenames="csw:Record", esn="brief",
|
||||||
keywords=[], limit=None, page=10, outputschema="gmd",
|
keywords=[], limit=None, page=10, outputschema="gmd",
|
||||||
startposition=0, cql=None, **kw):
|
startposition=0, cql=None, **kw):
|
||||||
from owslib.csw import namespaces
|
from owslib.catalogue.csw2 import namespaces
|
||||||
constraints = []
|
constraints = []
|
||||||
csw = self._ows(**kw)
|
csw = self._ows(**kw)
|
||||||
|
|
||||||
|
@ -154,7 +154,7 @@ class CswService(OwsService):
|
||||||
kwa["startposition"] = startposition
|
kwa["startposition"] = startposition
|
||||||
|
|
||||||
def getrecordbyid(self, ids=[], esn="full", outputschema="gmd", **kw):
|
def getrecordbyid(self, ids=[], esn="full", outputschema="gmd", **kw):
|
||||||
from owslib.csw import namespaces
|
from owslib.catalogue.csw2 import namespaces
|
||||||
csw = self._ows(**kw)
|
csw = self._ows(**kw)
|
||||||
kwa = {
|
kwa = {
|
||||||
"esn": esn,
|
"esn": esn,
|
||||||
|
|
Loading…
Reference in New Issue