'Get mime-type and format by file extension.
This only accepts "geojson" for the time being.'

def getTypeByExtension(self, extension):

    if (extension.lower() == 'geojson'):
        return ('application/json', 'GeoJSON')
    elif (extension.lower() == 'arcjson'):
        return ('application/json', 'ArcJSON')
    elif (extension.lower() == 'geobson'):
        return ('application/x-bson', 'GeoBSON')
    elif (extension.lower() == 'arcbson'):
        return ('application/x-bson', 'ArcBSON')
    elif (extension.lower() == 'geoamf'):
        return ('application/x-amf', 'GeoAMF')
    elif (extension.lower() == 'arcamf'):
        return ('application/x-amf', 'ArcAMF')
    elif (extension.lower() == 'wkt'):
        return ('text/x-wkt', 'WKT')
    raise KnownUnknown(('Vector    Provider    only    makes    .geojson,    .arcjson,    .geobson,    .arcbson,    .geoamf,    .arcamf    and    .wkt    tiles,    not    "%s"' % extension))
