Skip to content

Commit

Permalink
Merge pull request #50 from hydroshare/49-csv-content-type
Browse files Browse the repository at this point in the history
Support for CSV content type
  • Loading branch information
pkdash authored Sep 25, 2024
2 parents 92a45e6 + d72c120 commit bc5dcd8
Show file tree
Hide file tree
Showing 26 changed files with 1,269 additions and 534 deletions.
80 changes: 80 additions & 0 deletions docs/CSVFileMetadata.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
# CSV File Aggregation Metadata

## Properties

- **`title`** *(string)*: A string containing a descriptive title for the aggregation. Default: `null`.
- **`subjects`** *(array)*: A list of keyword strings expressing the topic of the aggregation. Default: `[]`.
- **Items** *(string)*
- **`language`** *(string)*: The 3-character string for the language in which the metadata and content are expressed. Default: `"eng"`.
- **`additional_metadata`** *(array)*: A dictionary of additional metadata elements expressed as key-value pairs.
- **Items** *(object)*: A key-value pair. Default: `[]`.
- **`key`** *(string)*
- **`value`** *(string)*
- **`spatial_coverage`**: An object containing the geospatial coverage for the aggregation expressed as either a bounding box or point. Default: `null`.
- **Any of**
- : Refer to *[#/definitions/PointCoverage](#definitions/PointCoverage)*.
- : Refer to *[#/definitions/BoxCoverage](#definitions/BoxCoverage)*.
- *null*
- **`period_coverage`**: An object containing the temporal coverage for a aggregation expressed as a date range. Default: `null`.
- **Any of**
- : Refer to *[#/definitions/PeriodCoverage](#definitions/PeriodCoverage)*.
- *null*
- **`tableSchema`**: An object containing metadata for the CSV file content type.
- **All of**
- : Refer to *[#/definitions/CSVTableSchema](#definitions/CSVTableSchema)*.
- **`type`**: A string expressing the aggregation type from the list of HydroShare aggregation types. Default: `"CSV"`.
- **All of**
- : Refer to *[#/definitions/AggregationType](#definitions/AggregationType)*.
- **`url`** *(string)*: An object containing the URL of the aggregation.
- **`rights`**: An object containing information about the rights held in and over the aggregation and the license under which a aggregation is shared. Default: `null`.
- **Any of**
- : Refer to *[#/definitions/Rights](#definitions/Rights)*.
- *null*
## Definitions

- <a id="definitions/AggregationType"></a>**`AggregationType`** *(string)*: Must be one of: `["Generic", "FileSet", "GeoRaster", "NetCDF", "GeoFeature", "RefTimeseries", "TimeSeries", "ModelProgram", "ModelInstance", "CSV"]`.
- <a id="definitions/BoxCoverage"></a>**`BoxCoverage`** *(object)*: A class used to represent geographic coverage metadata for a resource or aggregation expressed as a
latitude-longitude bounding box.
- **`type`** *(string)*: A string containing the type of geographic coverage. Must be one of: `["box"]`. Default: `"box"`.
- **`name`** *(string)*: A string containing a name for the place associated with the geographic coverage. Default: `null`.
- **`northlimit`** *(number, required)*: A floating point value containing the constant coordinate for the northernmost face or edge of the bounding box. Exclusive minimum: `-90.0`. Exclusive maximum: `90.0`.
- **`eastlimit`** *(number, required)*: A floating point value containing the constant coordinate for the easternmost face or edge of the bounding box. Exclusive minimum: `-180.0`. Exclusive maximum: `180.0`.
- **`southlimit`** *(number, required)*: A floating point value containing the constant coordinate for the southernmost face or edge of the bounding box. Exclusive minimum: `-90.0`. Exclusive maximum: `90.0`.
- **`westlimit`** *(number, required)*: A floating point value containing the constant coordinate for the westernmost face or edge of the bounding box. Exclusive minimum: `-180.0`. Exclusive maximum: `180.0`.
- **`units`** *(string, required)*: A string containing the units applying to the unlabelled numeric values of northlimit, eastlimit, southlimit, and westlimit.
- **`projection`** *(string)*: A string containing the name of the projection used with any parameters required, such as ellipsoid parameters, datum, standard parallels and meridians, zone, etc. Default: `null`.
- <a id="definitions/CSVColumnSchema"></a>**`CSVColumnSchema`** *(object)*: A class used to represent the metadata associated with a CSV column.
- **`column_number`** *(integer, required)*: The column number of a column in the CSV file. Exclusive minimum: `0`.
- **`title`**: The title of of a column in the CSV file. Default: `null`.
- **Any of**
- *string*
- *null*
- **`description`**: The description of a column in the CSV file. Default: `null`.
- **Any of**
- *string*
- *null*
- **`datatype`** *(string, required)*: The datatype of a column in the CSV file. Must be one of: `["string", "number", "datetime", "boolean"]`.
- <a id="definitions/CSVColumnsSchema"></a>**`CSVColumnsSchema`** *(object)*: A class used to represent the metadata associated with all columns of a CSV file.
- **`columns`** *(array, required)*: A list of objects containing metadata for each of the columns in the CSV file.
- **Items**: Refer to *[#/definitions/CSVColumnSchema](#definitions/CSVColumnSchema)*.
- <a id="definitions/CSVTableSchema"></a>**`CSVTableSchema`** *(object)*: A class used to represent the metadata associated with a CSV file.
- **`rows`** *(integer, required)*: The number of data rows in the CSV file. Exclusive minimum: `0`.
- **`delimiter`** *(string, required)*: The delimiter used in the CSV file. Must be one of: `[",", ";", "\t"]`.
- **`table`**: An object containing metadata for all columns in the CSV file.
- **All of**
- : Refer to *[#/definitions/CSVColumnsSchema](#definitions/CSVColumnsSchema)*.
- <a id="definitions/PeriodCoverage"></a>**`PeriodCoverage`** *(object)*: A class used to represent temporal coverage metadata for a resource or aggregation.
- **`name`** *(string)*: A string containing a name for the time interval. Default: `null`.
- **`start`** *(string, required)*: A datetime object containing the instant corresponding to the commencement of the time interval.
- **`end`** *(string, required)*: A datetime object containing the instant corresponding to the termination of the time interval.
- <a id="definitions/PointCoverage"></a>**`PointCoverage`** *(object)*: A class used to represent geographic coverage metadata for a resource or aggregation expressed as a
point location.
- **`type`** *(string)*: A string containing the type of geographic coverage. Must be one of: `["point"]`. Default: `"point"`.
- **`name`** *(string)*: A string containing a name for the place associated with the geographic coverage. Default: `null`.
- **`east`** *(number, required)*: The coordinate of the point location measured in the east direction. Exclusive minimum: `-180.0`. Exclusive maximum: `180.0`.
- **`north`** *(number, required)*: The coordinate of the point location measured in the north direction. Exclusive minimum: `-90.0`. Exclusive maximum: `90.0`.
- **`units`** *(string, required)*: The units applying to the unlabelled numeric values of north and east.
- **`projection`** *(string, required)*: The name of the projection used with any parameters required, such as ellipsoid parameters, datum, standard parallels and meridians, zone, etc.
- <a id="definitions/Rights"></a>**`Rights`** *(object)*: A class used to represent the rights statement metadata associated with a resource.
- **`statement`** *(string, required)*: A string containing the text of the license or rights statement.
- **`url`** *(string, required)*: An object containing the URL pointing to a description of the license or rights statement.
87 changes: 51 additions & 36 deletions docs/FileSetMetadata.md
Original file line number Diff line number Diff line change
@@ -1,42 +1,57 @@
# TODO Jeff (title of class)

*TODO Jeff (description of class)*
# File Set Aggregation Metadata

## Properties

- **`url`** *(string)*: TODO Jeff.
- **`title`** *(string)*: TODO Jeff.
- **`subjects`** *(array)*: TODO Jeff. Default: `[]`.
- **`title`** *(string)*: A string containing a descriptive title for the aggregation. Default: `null`.
- **`subjects`** *(array)*: A list of keyword strings expressing the topic of the aggregation. Default: `[]`.
- **Items** *(string)*
- **`language`** *(string)*: TODO Jeff. Default: `eng`.
- **`additional_metadata`** *(object)*: TODO Jeff. Default: `{}`.
- **`spatial_coverage`**: TODO Jeff.
- **`period_coverage`**: TODO Jeff.
- **`rights`**: TODO Jeff.
- **`type`**: TODO Jeff.
- **`language`** *(string)*: The 3-character string for the language in which the metadata and content are expressed. Default: `"eng"`.
- **`additional_metadata`** *(array)*: A dictionary of additional metadata elements expressed as key-value pairs.
- **Items** *(object)*: A key-value pair. Default: `[]`.
- **`key`** *(string)*
- **`value`** *(string)*
- **`spatial_coverage`**: An object containing the geospatial coverage for the aggregation expressed as either a bounding box or point. Default: `null`.
- **Any of**
- : Refer to *[#/definitions/PointCoverage](#definitions/PointCoverage)*.
- : Refer to *[#/definitions/BoxCoverage](#definitions/BoxCoverage)*.
- *null*
- **`period_coverage`**: An object containing the temporal coverage for a aggregation expressed as a date range. Default: `null`.
- **Any of**
- : Refer to *[#/definitions/PeriodCoverage](#definitions/PeriodCoverage)*.
- *null*
- **`type`**: A string expressing the aggregation type from the list of HydroShare aggregation types. Default: `"FileSet"`.
- **All of**
- : Refer to *[#/definitions/AggregationType](#definitions/AggregationType)*.
- **`url`** *(string)*: An object containing the URL of the aggregation.
- **`rights`**: An object containing information about the rights held in and over the aggregation and the license under which a aggregation is shared. Default: `null`.
- **Any of**
- : Refer to *[#/definitions/Rights](#definitions/Rights)*.
- *null*
## Definitions

- **`PointCoverage`** *(object)*: TODO Jeff (description of class).
- **`type`** *(string)*: TODO Jeff.
- **`name`** *(string)*: TODO Jeff.
- **`east`** *(number)*: TODO Jeff.
- **`north`** *(number)*: TODO Jeff.
- **`units`** *(string)*: TODO Jeff.
- **`projection`** *(string)*: TODO Jeff.
- **`BoxCoverage`** *(object)*: TODO Jeff (description of class).
- **`type`** *(string)*: TODO Jeff.
- **`name`** *(string)*: TODO Jeff.
- **`northlimit`** *(number)*: TODO Jeff.
- **`eastlimit`** *(number)*: TODO Jeff.
- **`southlimit`** *(number)*: TODO Jeff.
- **`westlimit`** *(number)*: TODO Jeff.
- **`units`** *(string)*: TODO Jeff.
- **`projection`** *(string)*: TODO Jeff.
- **`PeriodCoverage`** *(object)*: TODO Jeff (description of class).
- **`name`** *(string)*: TODO Jeff.
- **`start`** *(string)*: TODO Jeff.
- **`end`** *(string)*: TODO Jeff.
- **`Rights`** *(object)*: TODO Jeff (description of class).
- **`statement`** *(string)*: TODO Jeff.
- **`url`** *(string)*: TODO Jeff.
- **`AggregationType`** *(string)*: An enumeration. Must be one of: `['Generic', 'FileSet', 'GeoRaster', 'NetCDF', 'GeoFeature', 'RefTimeseries', 'TimeSeries']`.
- <a id="definitions/AggregationType"></a>**`AggregationType`** *(string)*: Must be one of: `["Generic", "FileSet", "GeoRaster", "NetCDF", "GeoFeature", "RefTimeseries", "TimeSeries", "ModelProgram", "ModelInstance", "CSV"]`.
- <a id="definitions/BoxCoverage"></a>**`BoxCoverage`** *(object)*: A class used to represent geographic coverage metadata for a resource or aggregation expressed as a
latitude-longitude bounding box.
- **`type`** *(string)*: A string containing the type of geographic coverage. Must be one of: `["box"]`. Default: `"box"`.
- **`name`** *(string)*: A string containing a name for the place associated with the geographic coverage. Default: `null`.
- **`northlimit`** *(number, required)*: A floating point value containing the constant coordinate for the northernmost face or edge of the bounding box. Exclusive minimum: `-90.0`. Exclusive maximum: `90.0`.
- **`eastlimit`** *(number, required)*: A floating point value containing the constant coordinate for the easternmost face or edge of the bounding box. Exclusive minimum: `-180.0`. Exclusive maximum: `180.0`.
- **`southlimit`** *(number, required)*: A floating point value containing the constant coordinate for the southernmost face or edge of the bounding box. Exclusive minimum: `-90.0`. Exclusive maximum: `90.0`.
- **`westlimit`** *(number, required)*: A floating point value containing the constant coordinate for the westernmost face or edge of the bounding box. Exclusive minimum: `-180.0`. Exclusive maximum: `180.0`.
- **`units`** *(string, required)*: A string containing the units applying to the unlabelled numeric values of northlimit, eastlimit, southlimit, and westlimit.
- **`projection`** *(string)*: A string containing the name of the projection used with any parameters required, such as ellipsoid parameters, datum, standard parallels and meridians, zone, etc. Default: `null`.
- <a id="definitions/PeriodCoverage"></a>**`PeriodCoverage`** *(object)*: A class used to represent temporal coverage metadata for a resource or aggregation.
- **`name`** *(string)*: A string containing a name for the time interval. Default: `null`.
- **`start`** *(string, required)*: A datetime object containing the instant corresponding to the commencement of the time interval.
- **`end`** *(string, required)*: A datetime object containing the instant corresponding to the termination of the time interval.
- <a id="definitions/PointCoverage"></a>**`PointCoverage`** *(object)*: A class used to represent geographic coverage metadata for a resource or aggregation expressed as a
point location.
- **`type`** *(string)*: A string containing the type of geographic coverage. Must be one of: `["point"]`. Default: `"point"`.
- **`name`** *(string)*: A string containing a name for the place associated with the geographic coverage. Default: `null`.
- **`east`** *(number, required)*: The coordinate of the point location measured in the east direction. Exclusive minimum: `-180.0`. Exclusive maximum: `180.0`.
- **`north`** *(number, required)*: The coordinate of the point location measured in the north direction. Exclusive minimum: `-90.0`. Exclusive maximum: `90.0`.
- **`units`** *(string, required)*: The units applying to the unlabelled numeric values of north and east.
- **`projection`** *(string, required)*: The name of the projection used with any parameters required, such as ellipsoid parameters, datum, standard parallels and meridians, zone, etc.
- <a id="definitions/Rights"></a>**`Rights`** *(object)*: A class used to represent the rights statement metadata associated with a resource.
- **`statement`** *(string, required)*: A string containing the text of the license or rights statement.
- **`url`** *(string, required)*: An object containing the URL pointing to a description of the license or rights statement.
Loading

0 comments on commit bc5dcd8

Please sign in to comment.