Skip to content

Commit

Permalink
add CSV format
Browse files Browse the repository at this point in the history
  • Loading branch information
janpisl committed Jun 28, 2018
1 parent 6702802 commit 256adac
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions pywps/inout/formats/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
_FORMATS = namedtuple('FORMATS', 'GEOJSON, JSON, SHP, GML, GEOTIFF, WCS,'
'WCS100, WCS110, WCS20, WFS, WFS100,'
'WFS110, WFS20, WMS, WMS130, WMS110,'
'WMS100, TEXT, NETCDF, LAZ, LAS')
'WMS100, TEXT, CSV, NETCDF, LAZ, LAS')


class DATA_TYPE(Enum):
Expand All @@ -35,6 +35,7 @@ def is_valid_datatype(data_type):
if data_type not in known_values:
raise Exception("Unknown data type")


class Format(object):
"""Input/output format specification
Expand Down Expand Up @@ -224,9 +225,10 @@ def json(self, jsonin):
Format('application/x-ogc-wfs; version=2.0', extension='.xml', data_type=0),
Format('application/x-ogc-wms', extension='.xml', data_type=0),
Format('application/x-ogc-wms; version=1.3.0', extension='.xml', data_type=0),
Format('application/x-ogc-wms; version=1.1.0', extension='.xml', data_type=0),
Format('application/x-ogc-wms; sversion=1.1.0', extension='.xml', data_type=0),
Format('application/x-ogc-wms; version=1.0.0', extension='.xml', data_type=0),
Format('text/plain', extension='.txt', data_type=0),
Format('text/plain', extension='.txt', data_type=2),
Format('text/csv', extension='.csv', data_type=2),
Format('application/x-netcdf', extension='.nc', data_type=0),
Format('application/octet-stream', extension='.laz', data_type=0),
Format('application/octet-stream', extension='.las', data_type=0),
Expand Down

0 comments on commit 256adac

Please sign in to comment.