Пример #1
0
def parse_capabilities_url(url, version='1.1.1'):
    try:
        capabilities_url = wms_capapilities_url(url, version)
        capabilities_response = open_url(capabilities_url)
    except HTTPClientError, ex:
        log_error('ERROR: %s', ex.args[0])
        sys.exit(1)
Пример #2
0
def parse_capabilities(capabilities_url):
    try:
        capabilities_url = wms_111_cap_url(capabilities_url)
        capabilities_response = open_url(capabilities_url)
    except HTTPClientError, ex:
        log_error('ERROR: %s', ex.args[0])
        sys.exit(1)
Пример #3
0
def parse_capabilities_url(url, version='1.1.1'):
    try:
        capabilities_url = wms_capapilities_url(url, version)
        capabilities_response = open_url(capabilities_url)
    except HTTPClientError, ex:
        log_error('ERROR: %s', ex.args[0])
        sys.exit(1)
Пример #4
0
def parse_capabilities_url(url, version='1.1.1'):
    try:
        capabilities_url = wms_capapilities_url(url, version)
        capabilities_response = open_url(capabilities_url)
    except HTTPClientError as ex:
        log_error('ERROR: %s', ex.args[0])
        sys.exit(1)

    # after parsing capabilities_response will be empty, therefore cache it
    capabilities = BytesIO(capabilities_response.read())
    return parse_capabilities(capabilities, version=version)
Пример #5
0
def parse_capabilities_url(url, version='1.1.1'):
    try:
        capabilities_url = wms_capapilities_url(url, version)
        capabilities_response = open_url(capabilities_url)
    except HTTPClientError as ex:
        log_error('ERROR: %s', ex.args[0])
        sys.exit(1)

    # after parsing capabilities_response will be empty, therefore cache it
    capabilities = BytesIO(capabilities_response.read())
    return parse_capabilities(capabilities, version=version)
Пример #6
0
def parse_capabilities(capabilities_url):
    try:
        capabilities_response = open_url(capabilities_url)
    except HTTPClientError, ex:
        log_error('ERROR: %s', ex.args[0])
        sys.exit(1)
Пример #7
0
def download_capabilities(url):
    capabilities_url = wms_capapilities_url(url)
    return open_url(capabilities_url)
Пример #8
0
def download_capabilities(url):
    capabilities_url = wms_capapilities_url(url)
    return open_url(capabilities_url)