geo_combine 0.1.0 → 0.5.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. checksums.yaml +5 -5
  2. data/.travis.yml +6 -1
  3. data/Gemfile +2 -1
  4. data/README.md +108 -23
  5. data/geo_combine.gemspec +4 -2
  6. data/lib/geo_combine.rb +11 -1
  7. data/lib/geo_combine/bounding_box.rb +71 -0
  8. data/lib/geo_combine/ckan_metadata.rb +112 -0
  9. data/lib/geo_combine/esri_open_data.rb +0 -9
  10. data/lib/geo_combine/exceptions.rb +8 -0
  11. data/lib/geo_combine/formatting.rb +6 -1
  12. data/lib/geo_combine/geo_blacklight_harvester.rb +203 -0
  13. data/lib/geo_combine/geoblacklight.rb +80 -12
  14. data/lib/geo_combine/ogp.rb +229 -0
  15. data/lib/geo_combine/railtie.rb +7 -0
  16. data/lib/geo_combine/version.rb +1 -1
  17. data/lib/tasks/geo_combine.rake +54 -20
  18. data/lib/xslt/fgdc2geoBL.xsl +95 -154
  19. data/lib/xslt/fgdc2html.xsl +105 -157
  20. data/lib/xslt/iso2geoBL.xsl +62 -84
  21. data/lib/xslt/iso2html.xsl +1107 -1070
  22. data/spec/features/iso2html_spec.rb +7 -1
  23. data/spec/fixtures/docs/basic_geoblacklight.json +5 -7
  24. data/spec/fixtures/docs/ckan.json +456 -0
  25. data/spec/fixtures/docs/full_geoblacklight.json +2 -8
  26. data/spec/fixtures/docs/geoblacklight_pre_v1.json +37 -0
  27. data/spec/fixtures/docs/ogp_harvard_line.json +28 -0
  28. data/spec/fixtures/docs/ogp_harvard_raster.json +28 -0
  29. data/spec/fixtures/docs/ogp_tufts_vector.json +31 -0
  30. data/spec/fixtures/json_docs.rb +20 -0
  31. data/spec/lib/geo_combine/bounding_box_spec.rb +59 -0
  32. data/spec/lib/geo_combine/ckan_metadata_spec.rb +114 -0
  33. data/spec/lib/geo_combine/esri_open_data_spec.rb +1 -14
  34. data/spec/lib/geo_combine/fgdc_spec.rb +11 -14
  35. data/spec/lib/geo_combine/formatting_spec.rb +6 -0
  36. data/spec/lib/geo_combine/geo_blacklight_harvester_spec.rb +190 -0
  37. data/spec/lib/geo_combine/geoblacklight_spec.rb +137 -11
  38. data/spec/lib/geo_combine/iso19139_spec.rb +5 -2
  39. data/spec/lib/geo_combine/ogp_spec.rb +163 -0
  40. data/spec/spec_helper.rb +1 -0
  41. metadata +63 -14
  42. data/lib/schema/geoblacklight-schema.json +0 -169
@@ -1,5 +1,5 @@
1
1
  {
2
- "uuid":"http://purl.stanford.edu/cz128vq0535",
2
+ "geoblacklight_version":"1.0",
3
3
  "dc_identifier_s":"http://purl.stanford.edu/cz128vq0535",
4
4
  "dc_title_s":"2005 Rural Poverty GIS Database: Uganda",
5
5
  "dc_description_s":"This polygon shapefile contains 2005 poverty data for 855 rural subcounties in Uganda. These data are intended for researchers, students, policy makers and the general public for reference and mapping purposes, and may be used for basic applications such as viewing, querying, and map output production.",
@@ -28,12 +28,6 @@
28
28
  "dct_spatial_sm":[
29
29
  "Uganda"
30
30
  ],
31
- "dc_relation_sm":[
32
- "http://sws.geonames.org/226074/about.rdf"
33
- ],
34
- "georss_box_s":"-1.478794 29.572742 4.234077 35.000308",
35
- "georss_polygon_s":"-1.478794 29.572742 4.234077 29.572742 4.234077 35.000308 -1.478794 35.000308 -1.478794 29.572742",
36
31
  "solr_geom":"ENVELOPE(29.572742, 35.000308, 4.234077, -1.478794)",
37
- "solr_bbox":"29.572742 -1.478794 35.000308 4.234077",
38
32
  "solr_year_i":2005
39
- }
33
+ }
@@ -0,0 +1,37 @@
1
+ {
2
+ "uuid": "urn:columbia.edu:Columbia.ESRI_Arcatlas_snow_ln",
3
+ "dc_identifier_s": "urn:columbia.edu:Columbia.ESRI_Arcatlas_snow_ln",
4
+ "dc_title_s": "Worldwide Snow Cover (Polygon), 1996",
5
+ "dc_description_s": "Snow Cover (Polygon) is a polyline theme representing rates or snowcover worldwide.",
6
+ "dc_rights_s": "Restricted",
7
+ "dct_provenance_s": "Columbia",
8
+ "dct_references_s": "{\"http://schema.org/downloadUrl\":\"https://www1.columbia.edu/sec/acis/eds/dgate/studies/C1301/data/snow_poly.zip\",\"http://www.w3.org/1999/xhtml\":\"https://geoblacklight-prod.cul.columbia.edu/metadata/fgdc/html/ESRI_Arcatlas_snow_ln.html\",\"http://www.isotc211.org/schemas/2005/gmd/\":\"https://geoblacklight-prod.cul.columbia.edu/metadata/fgdc/current/ESRI_Arcatlas_snow_ln.xml\"}",
9
+ "georss_box_s": "-85.0 -180.0 85.0 180.0",
10
+ "layer_id_s": "sde:columbia.ESRI_Arcatlas_snow_ln",
11
+ "layer_geom_type_s": "Polygon",
12
+ "layer_modified_dt": "2009-06-16T00:00:00Z",
13
+ "layer_slug_s": "sde-columbia-esri_arcatlas_snow_ln",
14
+ "solr_geom": "ENVELOPE(-180.0, 180.0, 85.0, -85.0)",
15
+ "solr_year_i": 1996,
16
+ "dc_creator_sm": [
17
+ "Environmental Systems Research Institute (Redlands, Calif.)"
18
+ ],
19
+ "dc_format_s": "Shapefile",
20
+ "dc_language_s": "",
21
+ "dc_publisher_s": "ESRI",
22
+ "dc_subject_sm": [
23
+ "climatologyMeteorologyAtmosphere"
24
+ ],
25
+ "dc_type_s": "Dataset",
26
+ "dct_spatial_sm": [
27
+ "Earth"
28
+ ],
29
+ "dct_temporal_sm": [
30
+ "1996"
31
+ ],
32
+ "dct_issued_s": "",
33
+ "dct_isPartOf_sm": [
34
+ "ArcAtlas"
35
+ ],
36
+ "georss_polygon_s": "85.0 -180.0 85.0 180.0 -85.0 180.0 -85.0 -180.0 85.0 -180.0"
37
+ }
@@ -0,0 +1,28 @@
1
+ {
2
+ "LayerId": "HARVARD.SDE.KNG_SNCARC",
3
+ "Name": "KNG_SNCARC",
4
+ "ExternalLayerId": "188",
5
+ "Institution": "Harvard",
6
+ "Access": "Restricted",
7
+ "DataType": "Line",
8
+ "Availability": "online",
9
+ "LayerDisplayName": "King County, Washington : streets",
10
+ "Publisher": "King County GIS Center",
11
+ "ThemeKeywords": "Roads Transportation Municipal transportation",
12
+ "PlaceKeywords": "Snohomish Pierce King County Washington",
13
+ "GeoReferenced": true,
14
+ "Abstract": "King County, Washington arc features from the King County street network coverage. Covers also portions of Snohomish and Pierce Counties. \n\nThe source coverage was derived from the King County Street Network coverage (kcsn). All feature classes other than arcs have been dropped and items have been removed from the AAT. Scale: 1:24,000.",
15
+ "Location": "{\"wms\": [\"http://hgl.harvard.edu:8080/geoserver/wms\"],\"wfs\": \"http://hgl.harvard.edu:8080/geoserver/wfs\"}",
16
+ "MaxY": 47.986427,
17
+ "MinY": 47.150354,
18
+ "MaxX": -121.6959,
19
+ "MinX": -122.525897,
20
+ "CenterX": -122.11089849999999,
21
+ "CenterY": 47.5683905,
22
+ "HalfWidth": 0.41499850000000293,
23
+ "HalfHeight": 0.4180364999999995,
24
+ "Area": 0.693938081781004,
25
+ "WorkspaceName": "hglshapefiles",
26
+ "ContentDate": "2003-01-01T01:01:01Z",
27
+ "FgdcText": "<?xml version = '1.0' encoding = 'UTF-8'?><metadata> <idinfo> <citation> <citeinfo> <origin>King County (Wash.)</origin> <pubdate>20030630</pubdate> <title>King County, Washington : streets</title> <geoform>vector digital data</geoform> <pubinfo> <pubplace>[Seattle, Washington].</pubplace> <publish>King County GIS Center</publish> </pubinfo> <onlink>http://hgl.harvard.edu:8080/HGL/jsp/HGL.jsp?action=VColl&amp;VCollName=KNG_SNCARC</onlink> </citeinfo> </citation> <descript> <abstract>King County, Washington arc features from the King County street network coverage. Covers also portions of Snohomish and Pierce Counties. The source coverage was derived from the King County Street Network coverage (kcsn). All feature classes other than arcs have been dropped and items have been removed from the AAT. Scale: 1:24,000.</abstract> <purpose>Based on TIGER data, KCSN is suitable for general reference, small-scale map displays, and network analysis. Future enhancements include deriving this data set directly from RECDNET.</purpose> </descript> <timeperd> <timeinfo> <sngdate> <caldate>20030624</caldate> </sngdate> </timeinfo> <current>source coverage publication date</current> </timeperd> <status> <progress>Complete</progress> <update>Irregular</update> </status> <spdom> <bounding> <westbc>-122.525897</westbc> <eastbc>-121.695900</eastbc> <northbc>47.986427</northbc> <southbc>47.150354</southbc> </bounding> </spdom> <keywords> <theme> <themekt>HGL Category Keyword Thesaurus</themekt> <themekey>Municipal</themekey> </theme> <theme> <themekt>LCSH</themekt> <themekey>Roads</themekey> <themekey>Transportation</themekey> </theme> <theme> <themekt>ISO 19115 Topic Category</themekt> <themekey>transportation</themekey> </theme> <place> <placekt>GNIS</placekt> <placekey>Washington</placekey> <placekey>King County</placekey> <placekey>Snohomish County</placekey> <placekey>Pierce County</placekey> </place> </keywords> <accconst>Access is granted to Harvard University Affiliates only. Affiliates are limited to current faculty, staff and students.</accconst> <useconst>Plots/maps displaying streets from this coverage must include a disclaimer indicating that the source of the data is from maps produced by Kroll. This disclaimer must read as follows: THIS DOCUMENT INCLUDES DATA COPYRIGHTED BY THE KROLL MAP COMPANY AND IS BEING USED WITH THEIR PERMISSION. USE IS RESTRICTED. For educational non-commercial use only. This data may not be redistributed by HGL users. King County data are made available with the understanding that they shall be used exclusively by the obtainer or his/her authorized agents.</useconst> <ptcontac> <cntinfo> <cntperp> <cntper>Tamara Davis</cntper> <cntorg>GIS group - Transit Infrastructure and Integration</cntorg> </cntperp> <cntaddr> <addrtype>mailing address</addrtype> <address>Exchange Building</address> <address>821 Second Ave., MS 150</address> <city>Seattle</city> <state>WA</state> <postal>98014</postal> <country>USA</country> </cntaddr> <cntvoice>(206) 684-2118</cntvoice> <cntemail>tamara.davis@metrokc.gov</cntemail> </cntinfo> </ptcontac> <datacred>See use constraints.</datacred> <native>Unknown.</native> </idinfo> <dataqual> <attracc> <attraccr>None</attraccr> </attracc> <logic>None.</logic> <complete>None.</complete> <posacc> <horizpa> <horizpar>This data set is not conflated to the King County Cadastral Base. The positional accuracy of this data set is undetermined.</horizpar> </horizpa> </posacc> <lineage> <srcinfo> <srccite> <citeinfo> <origin>King County (Wash.)</origin> <origin>King County (Wash.). GIS Center.</origin> <pubdate>20030624</pubdate> <title>KCSNC: Streets</title> <geoform>vector digital data</geoform> <pubinfo> <pubplace>[Seattle, Wash.]</pubplace> <publish>King County GIS Center</publish> </pubinfo> <othercit>CD-ROM layer: street-kcsnc</othercit> <lworkcit> <citeinfo> <origin>King County (Wash.). GIS Center</origin> <pubdate>2003</pubdate> <title>King County GIS data.</title> <geoform>digital data</geoform> <pubinfo> <pubplace>King County GIS Center</pubplace> <publish>[Seattle, Wash.]</publish> </pubinfo> <othercit>2 CD-ROMs; CD 1. Standard data -- CD 2. Parcel data.</othercit> </citeinfo> </lworkcit> </citeinfo> </srccite> <srcscale>Unknown</srcscale> <typesrc>online</typesrc> <srctime> <timeinfo> <sngdate> <caldate>20030624</caldate> </sngdate> </timeinfo> <srccurr>publication date</srccurr> </srctime> <srccitea>coverage</srccitea> <srccontr>Source coverage data layer from which shapefile was converted.</srccontr> </srcinfo> <procstep> <procdesc>King County, Washington data was obtained via a CD-ROM. The data were in the format of ArcINFO coverages and were converted to shapefiles using the \"coverage to shapefile\" wizard in ArcToolbox, version 8.3. The shapefiles were then imported to ArcSDE Layers using the ArcSDE command line importing tool, shp2sde, version 8.3.</procdesc> <srcused>coverage</srcused> <procdate>2005</procdate> <srcprod>shapefile</srcprod> <proccont> <cntinfo> <cntorgp> <cntorg>Harvard Geospatial Library</cntorg> </cntorgp> <cntpos>GIS Technician</cntpos> <cntaddr> <addrtype>mailing and physical address</addrtype> <address>Office for Information Systems</address> <address>Harvard University Library</address> <address>90 Mount Auburn Street</address> <city>Cambridge</city> <state>MA</state> <postal>02138</postal> <country>USA</country> </cntaddr> <cntvoice>617-495-2417</cntvoice> <cntfax>617-496-0440</cntfax> <cntemail>hgl_ref@hulmail.harvard.edu</cntemail> <hours>Monday - Friday, 9:00 am - 4:00 pm EST-USA</hours> </cntinfo> </proccont> </procstep> </lineage> </dataqual> <spdoinfo> <direct>Vector</direct> <ptvctinf> <sdtsterm> <sdtstype>String</sdtstype> <ptvctcnt>8185</ptvctcnt> </sdtsterm> </ptvctinf> </spdoinfo> <spref> <horizsys> <planar> <mapproj> <mapprojn>Lambert Conformal Conic</mapprojn> <lambertc> <stdparll>47.500000</stdparll> <stdparll>48.733333</stdparll> <longcm>-120.833333</longcm> <latprjo>47.000000</latprjo> <feast>1640416.666667</feast> <fnorth>0.000000</fnorth> </lambertc> </mapproj> <planci> <plance>coordinate pair</plance> <coordrep> <absres>0.000176</absres> <ordres>0.000176</ordres> </coordrep> <plandu>survey feet</plandu> </planci> </planar> <geodetic> <horizdn>D_North_American_1983_HARN</horizdn> <ellips>Geodetic Reference System 80</ellips> <semiaxis>6378137.000000</semiaxis> <denflat>298.257222</denflat> </geodetic> </horizsys> </spref> <eainfo> <detailed> <enttyp> <enttypl>KNG_SNCARC</enttypl> <enttypd>King County Streets</enttypd> <enttypds>King County GIS Center</enttypds> </enttyp> <attr> <attrlabl>FNODE_</attrlabl> <attrdef>From node</attrdef> <attrdefs>None</attrdefs> </attr> <attr> <attrlabl>TNODE_</attrlabl> <attrdef>To node</attrdef> <attrdefs>None</attrdefs> </attr> <attr> <attrlabl>LPOLY_</attrlabl> <attrdef>Left polygon</attrdef> <attrdefs>None</attrdefs> </attr> <attr> <attrlabl>RPOLY_</attrlabl> <attrdef>Right polygon</attrdef> <attrdefs>None</attrdefs> </attr> <attr> <attrlabl>LENGTH</attrlabl> <attrdef>Length of feature in coverage units.</attrdef> <attrdefs>ESRI</attrdefs> </attr> <attr> <attrlabl>KCSNC_</attrlabl> <attrdef>Internal feature number</attrdef> <attrdefs>None</attrdefs> <attrdomv> <udom>Sequential unique whole numbers that are automatically generated.</udom> </attrdomv> </attr> <attr> <attrlabl>KCSNC_ID</attrlabl> <attrdef>Internal feature number</attrdef> <attrdefs>None</attrdefs> </attr> <attr> <attrlabl>FRADDL</attrlabl> <attrdef>From Address Left : Address at the bottom from node on the left side of street</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>TOADDL</attrlabl> <attrdef>To Address Left : Address at the to node on the left side of street</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>FRADDR</attrlabl> <attrdef>From Address Right : Address at the from node on the right side of street</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>TOADDR</attrlabl> <attrdef>To Address Right : Address at the to node on the right side of street</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>ZIPL</attrlabl> <attrdef>Zip Code Left : The postal zip code on the left side of the street</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>ZIPR</attrlabl> <attrdef>Zip Code Right : The postal zip code on right side of street</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>KEYNAME</attrlabl> <attrdef>Key name : Link key identifier to street name table (kcsn.stname)</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>FEATURE</attrlabl> <attrdef>Feature : Full street name (with space between street name &amp; suffix direction)</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <udom>Text.</udom> </attrdomv> </attr> <attr> <attrlabl>FEATURE2</attrlabl> <attrdef>Feature 2 : Full street name (without space between street name &amp; suffix direction)</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <udom>Text.</udom> </attrdomv> </attr> <attr> <attrlabl>ALIAS1</attrlabl> <attrdef>Full Second street name and type/suffix direction</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <udom>Text.</udom> </attrdomv> </attr> <attr> <attrlabl>ALIAS2</attrlabl> <attrdef>Full 3rd street name and type/suffix direction</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <udom>Text.</udom> </attrdomv> </attr> <attr> <attrlabl>KEYALIAS1</attrlabl> <attrdef>Key Alias 1 : 2nd link key identifier to street name table (kcsn.stname)</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>KEYALIAS2</attrlabl> <attrdef>Key Alias 2 : 3rd link key identifier to street name table (kcsn.stname)</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>PREFIX</attrlabl> <attrdef>Prefix of the street</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <udom>Text.</udom> </attrdomv> </attr> <attr> <attrlabl>STNAME</attrlabl> <attrdef>Name of the street</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <udom>Text.</udom> </attrdomv> </attr> <attr> <attrlabl>STYPE</attrlabl> <attrdef>Type of the street</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <udom>Text.</udom> </attrdomv> </attr> <attr> <attrlabl>SUFFIX</attrlabl> <attrdef>Suffix of the street</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <udom>Text.</udom> </attrdomv> </attr> <attr> <attrlabl>GRADE</attrlabl> <attrdef>Slope of the street</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>BARRIER</attrlabl> <attrdef>Barrier : Trip planning defines streets where pedestrian crossings are not allowed</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>TROLLEY</attrlabl> <attrdef>Number identify streets as trolley overhead</attrdef> <attrdefs>King County GIS Center</attrdefs> </attr> <attr> <attrlabl>HOV</attrlabl> <attrdef>Numbers Indicate the direction of HOV lanes</attrdef> <attrdefs>King County GIS Center</attrdefs> <attrdomv> <edom> <edomv>0</edomv> </edom> <edom> <edomv>2</edomv> <edomvd>South</edomvd> <edomvds>King County GIS Center</edomvds> </edom> <edom> <edomv>5</edomv> <edomvd>Both</edomvd> <edomvds>King County GIS Center</edomvds> </edom> </attrdomv> </attr> <attr> <attrlabl>FID</attrlabl> <attrdef>Internal feature number.</attrdef> <attrdefs>ESRI</attrdefs> <attrdomv> <udom>Sequential unique whole numbers that are automatically generated.</udom> </attrdomv> </attr> <attr> <attrlabl>SHAPE</attrlabl> <attrdef>Feature geometry.</attrdef> <attrdefs>ESRI</attrdefs> <attrdomv> <udom>Coordinates defining the features.</udom> </attrdomv> </attr> <attr> <attrlabl>SHAPE.LEN</attrlabl> <attrdef>Length of feature in coverage units.</attrdef> <attrdefs>ESRI</attrdefs> </attr> </detailed> </eainfo> <distinfo> <distrib> <cntinfo> <cntorgp> <cntorg>Harvard Geospatial Library</cntorg> </cntorgp> <cntaddr> <addrtype>mailing and physical address</addrtype> <address>Harvard University Library</address> <address>Office For Information Systems</address> <address>90 Mount Auburn Street</address> <city>Cambridge</city> <state>MA</state> <postal>02138</postal> <country>USA</country> </cntaddr> <cntvoice>617-495-2417</cntvoice> <cntfax>617-496-0440</cntfax> <cntemail>hgl_ref@hulmail.harvard.edu</cntemail> <hours>Monday - Friday, 9:00 am - 4:00 pm EST-USA</hours> </cntinfo> </distrib> <resdesc>Downloadable Data</resdesc> <distliab>Although this data is being distributed by Harvard University, no warranty expressed or implied is made by the University as to the accuracy of the data and related materials. The act of distribution shall not constitute any such warranty, and no responsibility is assumed by the University in the use of this data, or related materials.</distliab> <stdorder> <digform> <digtinfo> <formname>SHAPE</formname> <filedec>ZIP</filedec> </digtinfo> <digtopt> <onlinopt> <computer> <networka> <networkr>http://hgl.harvard.edu/</networkr> </networka> </computer> </onlinopt> </digtopt> </digform> <fees>None</fees> <ordering>Web-based distribution only</ordering> </stdorder> </distinfo> <metainfo> <metd>20070125</metd> <metc> <cntinfo> <cntorgp> <cntorg>Harvard Geospatial Library</cntorg> </cntorgp> <cntpos>Geospatial Resources Cataloger</cntpos> <cntaddr> <addrtype>mailing and physical address</addrtype> <address>Harvard University Library</address> <address>Office For Information Systems</address> <address>90 Mount Auburn Street</address> <city>Cambridge</city> <state>MA</state> <postal>02138</postal> <country>USA</country> </cntaddr> <cntvoice>617-495-2417</cntvoice> <cntfax>617-496-0440</cntfax> <cntemail>hgl_ref@hulmail.harvard.edu</cntemail> <hours>Monday - Friday, 9:00 am - 4:00 pm EST-USA</hours> </cntinfo> </metc> <metstdn>FGDC Content Standards for Digital Geospatial Metadata</metstdn> <metstdv>FGDC-STD-001-1998</metstdv> <mettc>local time</mettc> <metextns> <onlink>http://www.esri.com/metadata/esriprof80.html</onlink> <metprof>ESRI Metadata Profile</metprof> </metextns> </metainfo></metadata>"
28
+ }
@@ -0,0 +1,28 @@
1
+ {
2
+ "LayerId": "HARVARD.SDE2.G1059_W57_1654_PF_SH1",
3
+ "Name": "G1059_W57_1654_PF_SH1",
4
+ "ExternalLayerId": "1188",
5
+ "Institution": "Harvard",
6
+ "Access": "Public",
7
+ "DataType": "Paper Map",
8
+ "Availability": "online",
9
+ "LayerDisplayName": "World Map, 1654 (Raster Image)",
10
+ "Publisher": "Harvard Map Collection, Harvard Library",
11
+ "ThemeKeywords": "Human settlements Landforms imageryBaseMapsEarthCover Transportation Bodies water Maps and towns of Villages Cities",
12
+ "PlaceKeywords": "regions Europe Africa Hemisphere South Earth Western Asia Northern America Eastern North Southern Australia Arctic",
13
+ "GeoReferenced": true,
14
+ "Abstract": "This layer is a georeferenced raster image of the historic paper map entitled: Nova totius terrarum orbis geographica ac hydrographica tabula, autore N.I. Piscator, from the Frederik de Wit's untitled Dutch Sea Atlas. It was published by F. de Wit in 1654. Scale [ca. 1:100,000,000]. Map in Latin.\n\nThe image inside the map neatline is georeferenced to the surface of the earth and fit to the World Geodetic System 1984 (WGS 84) coordinate system. All map collar and inset information is also available as part of the raster image, including any inset maps, profiles, statistical tables, directories, text, illustrations, index maps, legends, or other information associated with the principal map. \n\nThis map shows features such as drainage, cities and other human settlements, territorial boundaries, shoreline features, and more. Relief shown pictorially. \n\nThis layer is part of a selection of digitally scanned and georeferenced historic maps from the Harvard Map Collection. These maps typically portray both natural and manmade features. The selection represents a range of originators, ground condition dates, scales, and map purposes.",
15
+ "Location": "{\"wms\": [\"http://pelham.lib.harvard.edu:8080/geoserver/wms\"],\"wcs\": \"http://pelham.lib.harvard.edu:8080/geoserver/wcs\",\"download\": \"http://pelham.lib.harvard.edu:8080/HGL/HGLOpenDelivery\"}",
16
+ "MaxY": 90.0,
17
+ "MinY": -90.0,
18
+ "MaxX": 180.0,
19
+ "MinX": -180.0,
20
+ "CenterX": 0.0,
21
+ "CenterY": 0.0,
22
+ "HalfWidth": 180.0,
23
+ "HalfHeight": 90.0,
24
+ "Area": 64800.0,
25
+ "WorkspaceName": "cite",
26
+ "ContentDate": "1654-01-01T01:01:01Z",
27
+ "FgdcText": "<?xml version=\"1.0\" encoding=\"UTF-8\"?><!DOCTYPE metadata SYSTEM \"http://www.fgdc.gov/metadata/fgdc-std-001-1998.dtd\"><metadata><idinfo><citation><citeinfo><origin>Harvard Map Collection, Harvard Library</origin><origin>Visscher, Claes Jansz., 1586 or 1587-1652.</origin><origin>Wit, Frederik de.</origin><pubdate>201404</pubdate><title>World Map, 1654 (Raster Image)</title><geoform>map</geoform><pubinfo><pubplace>Cambridge, Massachusetts</pubplace><publish>Harvard Map Collection, Harvard Library</publish></pubinfo><onlink>http://hgl.harvard.edu:8080/HGL/hgl.jsp?action=VCollandamp;VCollName=G1059_W57_1654_PF_SH1</onlink></citeinfo></citation><descript><abstract>This layer is a georeferenced raster image of the historic paper map entitled: Nova totius terrarum orbis geographica ac hydrographica tabula, autore N.I. Piscator, from the Frederik de Wit's untitled Dutch Sea Atlas. It was published by F. de Wit in 1654. Scale [ca. 1:100,000,000]. Map in Latin.The image inside the map neatline is georeferenced to the surface of the earth and fit to the World Geodetic System 1984 (WGS 84) coordinate system. All map collar and inset information is also available as part of the raster image, including any inset maps, profiles, statistical tables, directories, text, illustrations, index maps, legends, or other information associated with the principal map. This map shows features such as drainage, cities and other human settlements, territorial boundaries, shoreline features, and more. Relief shown pictorially. This layer is part of a selection of digitally scanned and georeferenced historic maps from the Harvard Map Collection. These maps typically portray both natural and manmade features. The selection represents a range of originators, ground condition dates, scales, and map purposes.</abstract><purpose>Historic paper maps can provide an excellent view of the changes that have occurred in the cultural and physical landscape. The wide range of information provided on these maps make them useful in the study of historic geography, and urban and rural land use change. As this map has been georeferenced, it can be used in a GIS as a source or background layer in conjunction with other GIS data.</purpose></descript><timeperd><timeinfo><sngdate><caldate>1654</caldate></sngdate></timeinfo><current>source map publication date</current></timeperd><status><progress>Complete</progress><update>None planned</update></status><spdom><bounding><westbc>-180</westbc><eastbc>180</eastbc><northbc>90</northbc><southbc>-90</southbc></bounding></spdom><keywords><theme><themekt>LCSH</themekt><themekey>Maps</themekey><themekey>Human settlements</themekey><themekey>Cities and towns</themekey><themekey>Villages</themekey><themekey>Bodies of water</themekey><themekey>Landforms</themekey><themekey>Transportation</themekey></theme><theme><themekt>ISO 19115 Topic Category</themekt><themekey>imageryBaseMapsEarthCover</themekey></theme><place><placekt>LCSH</placekt><placekey>Earth</placekey><placekey>Northern Hemisphere</placekey><placekey>Southern Hemisphere</placekey><placekey>Eastern Hemisphere</placekey><placekey>Western Hemisphere</placekey><placekey>Africa</placekey><placekey>Asia</placekey><placekey>Australia</placekey><placekey>Europe</placekey><placekey>North America</placekey><placekey>South America</placekey><placekey>Arctic regions</placekey></place></keywords><accconst>None</accconst><useconst>For educational, non-commercial use only.</useconst><ptcontac><cntinfo><cntorgp><cntorg>Harvard Map Collection, Harvard Library</cntorg></cntorgp><cntpos>Harvard Geospatial Library</cntpos><cntaddr><addrtype>mailing and physical address</addrtype><address>Harvard Map Collection</address><address>Pusey Library</address><address>Harvard University</address><city>Cambridge</city><state>MA</state><postal>02138</postal><country>USA</country></cntaddr><cntvoice>617-495-2417</cntvoice><cntfax>617-496-0440</cntfax><cntemail>hgl_ref@hulmail.harvard.edu</cntemail><hours>Monday - Friday, 9:00 am - 4:00 pm EST-USA</hours></cntinfo></ptcontac><native>ESRI ArcGIS 10.1</native></idinfo><dataqual><attracc><attraccr>The georeferenced raster is a faithfully reproduced digital image of the original source map. Some differences may be detected between the source graphic used and the raster image due to the RGB values assigned that particular color. The intent is to recreate those colors as near as possible.</attraccr></attracc><complete>Data completeness for raster digital image files reflect content of the source graphic. Features may have been eliminated or generalized on the source graphic due to scale and legibility constraints</complete><posacc><horizpa><horizpar>The horizontal positional accuracy of a raster image is approximately the same as the accuracy of the published source map. The lack of a greater accuracy is largely the result of the inaccuracies with the original measurements and possible distortions in the original paper map document. There may also be errors introduced during the digitizing and georeferencing process. In most cases, however, errors in the raster image are small compared with sources of error in the original map graphic. The RMS error for this map is 7.40181 Decimal Degrees. This value describes how consistent the transformation is between the different control points (links). The RMS error is only an assessment of the accuracy of the transformation.</horizpar></horizpa></posacc><lineage><srcinfo><srccite><citeinfo><origin>Visscher, Claes Jansz., 1586 or 1587-1652.</origin><origin>Wit, Frederik de.</origin><pubdate>1654</pubdate><title>Nova totius terrarum orbis geographica ac hydrographica tabula</title><geoform>map</geoform><pubinfo><pubplace>Amsterdam</pubplace><publish>F. de Wit</publish></pubinfo><othercit>1 map : hand col. ; 29 x 43 cm., on sheet 49 x 57 cm.</othercit><lworkcit><citeinfo><origin>Wit, Frederik de.</origin><origin>Visscher, Claes Jansz., 1586 or 1587-1652.</origin><origin>Blaeu, Willem Janszoon, 1571-1638.</origin><origin>Jacobsz, Anthonie. 1606?-1650.</origin><origin>Jacobsz, Theunis, 1632?-1679.</origin><pubdate>1654</pubdate><title>[Dutch sea atlas].</title><geoform>atlas</geoform><pubinfo><pubplace>Amsterdam</pubplace><publish>F. de Wit</publish></pubinfo><othercit>1 atlas : 15 col. maps ; 50 x 61 cm.</othercit></citeinfo></lworkcit></citeinfo></srccite><srcscale>100000000</srcscale><typesrc>paper</typesrc><srctime><timeinfo><sngdate><caldate>1654</caldate></sngdate></timeinfo><srccurr>publication date</srccurr></srctime><srccitea>Paper Map</srccitea><srccontr>Source map for raster image</srccontr></srcinfo><procstep><procdesc>Production of this raster image began with the scanning of the paper map on a high-resolution scanner (Colortrac Smart LF Gx+T42 scanner and SmartWorksPro version 1.1.1.5 scanning software) at 400dpi. Resulting images were rotated and cropped as needed using Adobe Photoshop CS5 Extended version 12.0. Images were saved as lossless JPEG2000 files.</procdesc><srcused>Paper Map</srcused><procdate>2012</procdate><srcprod>JP2 Map Image</srcprod><proccont><cntinfo><cntorgp><cntorg>Harvard Geospatial Library</cntorg></cntorgp><cntpos>GIS Technician</cntpos><cntaddr><addrtype>mailing and physical address</addrtype><address>Harvard University Information Technology</address><address>Library Technology Services</address><address>90 Mount Auburn Street</address><city>Cambridge</city><state>MA</state><postal>02138</postal><country>USA</country></cntaddr><cntvoice>617-495-2417</cntvoice><cntfax>617-496-0440</cntfax><cntemail>hgl_ref@hulmail.harvard.edu</cntemail><hours>Monday - Friday, 9:00 am - 4:00 pm EST-USA</hours></cntinfo></proccont></procstep><procstep><procdesc>Using ArcMap 10.1 software, the digital JPEG2000 image was georeferenced to common points located on digital vector shapefiles. For this image, the following vector shapefile was used as a base map for reference: ESRI Data and Maps 2010: World Country Boundaries (1:10,000,000). The base map data is displayed in the World Geodetic System 1984 (WGS 84) coordinate system, and the image was subsequently georeferenced to the same projection. A world file (.j2w) was automatically generated and saved in association with the digital image. See 'Horizontal Accuracy' for the RMS error of this image. Please note that the projection will need to be defined by the user in order to display the image with other projected data and the world file will need to be stored in the same root directory as the image.</procdesc><srcused>JP2 Map Image</srcused><procdate>2012</procdate><srcprod>Georeferenced Raster Data</srcprod><proccont><cntinfo><cntorgp><cntorg>Harvard Geospatial Library</cntorg></cntorgp><cntpos>GIS Technician</cntpos><cntaddr><addrtype>mailing and physical address</addrtype><address>Harvard University Information Technology</address><address>Library Technology Services</address><address>90 Mount Auburn Street</address><city>Cambridge</city><state>MA</state><postal>02138</postal><country>USA</country></cntaddr><cntvoice>617-495-2417</cntvoice><cntfax>617-496-0440</cntfax><cntemail>hgl_ref@hulmail.harvard.edu</cntemail><hours>Monday - Friday, 9:00 am - 4:00 pm EST-USA</hours></cntinfo></proccont></procstep></lineage></dataqual><spdoinfo><direct>Raster</direct><rastinfo><rasttype>Pixel</rasttype><rowcount>7606</rowcount><colcount>8936</colcount><vrtcount>1</vrtcount></rastinfo></spdoinfo><spref><horizsys><geograph><latres>0.000001</latres><longres>0.000001</longres><geogunit>Decimal degrees</geogunit></geograph><geodetic><horizdn>D_WGS_1984</horizdn><ellips>WGS_1984</ellips><semiaxis>6378137.000000</semiaxis><denflat>298.257224</denflat></geodetic></horizsys></spref><eainfo><overview><eaover>The indexes reference a color palette of RGB values from 0 through 255, representing the color value from the original paper sheet map. The colors on that sheet can represent relief, drainage, vegetation, populated places, cultural features, coastal hydrography, transportation features (roads, railroads, tracks and trails), spot elevations and boundaries. The colors are sometimes explained in a legend that is incorporated into the map inset or collar.</eaover><eadetcit>Not applicable.</eadetcit></overview></eainfo><distinfo><distrib><cntinfo><cntorgp><cntorg>Harvard University Information Technology</cntorg></cntorgp><cntpos>Harvard Geospatial Library</cntpos><cntaddr><addrtype>mailing and physical address</addrtype><address>Library Technology Services</address><address>90 Mount Auburn Street</address><city>Cambridge</city><state>MA</state><postal>02138</postal><country>USA</country></cntaddr><cntvoice>617-495-2417</cntvoice><cntfax>617-496-0440</cntfax><cntemail>hgl_ref@hulmail.harvard.edu</cntemail><hours>Monday - Friday, 9:00 am - 4:00 pm EST-USA</hours></cntinfo></distrib><resdesc>Downloadable Data</resdesc><distliab>Although this data set has been developed by Harvard University, no warranty expressed or implied is made by the University as to the accuracy of the data and related materials. The act of distribution shall not constitute any such warranty, and no responsibility is assumed by the University in the use of this data, or related materials.</distliab><stdorder><digform><digtinfo><formname>JPEG2000</formname><filedec>ZIP</filedec></digtinfo><digtopt><onlinopt><computer><networka><networkr>http://hgl.harvard.edu/</networkr></networka></computer></onlinopt></digtopt></digform><fees>None</fees></stdorder></distinfo><metainfo><metd>20140422</metd><metc><cntinfo><cntorgp><cntorg>Harvard Geospatial Library</cntorg></cntorgp><cntpos>Geospatial Metadata Librarian</cntpos><cntaddr><addrtype>mailing and physical address</addrtype><address>Harvard University Information Technology</address><address>Library Technology Services</address><address>90 Mount Auburn Street</address><city>Cambridge</city><state>MA</state><postal>02138</postal><country>USA</country></cntaddr><cntvoice>617-495-2417</cntvoice><cntfax>617-496-0440</cntfax><cntemail>hgl_ref@hulmail.harvard.edu</cntemail><hours>Monday - Friday, 9:00 am - 4:00 pm EST-USA</hours></cntinfo></metc><metstdn>FGDC Content Standards for Digital Geospatial Metadata</metstdn><metstdv>FGDC-STD-001-1998</metstdv><mettc>local time</mettc></metainfo></metadata>"
28
+ }
@@ -0,0 +1,31 @@
1
+ {
2
+ "LayerId": "Tufts.WorldShorelineArea95",
3
+ "Name": "GISPORTAL.GISOWNER01.WORLDSHORELINEAREA95",
4
+ "CollectionId": "geoserver",
5
+ "Institution": "Tufts",
6
+ "Access": "Public",
7
+ "DataType": "Polygon",
8
+ "Availability": "online",
9
+ "LayerDisplayName": "Vector Shoreline Area World 1995",
10
+ "Publisher": "United States. National Imagery and Mapping Agency",
11
+ "Originator": "United States. National Imagery and Mapping Agency",
12
+ "OriginatorSort": "United States. National Imagery and Mapping Agency",
13
+ "ThemeKeywords": "Shorelines polygon boundaries oceans Boundaries",
14
+ "PlaceKeywords": "Polar Europe Africa Hemisphere South Regions World Western Asia America Northern Eastern North Southern Australia",
15
+ "PlaceKeywordsSynonyms": "Polar Europe Africa Hemisphere South Regions World Western Asia America Northern Eastern North Southern Australia",
16
+ "GeoReferenced": true,
17
+ "Abstract": "This polygon dataset represents coastlines, countries, and oceans. This data set was originally created for mission planning for military operations. Other potential applications include cartographic representation and boundary determination. The original World Vector Shoreline (WVS) was a digital data file containing the shorelines, international boundaries, and country names of the world. WVS data were processed into NGAs Vector Product Format in 1995, resulting in the highest resolution demarcation of coastline globally available, the World Vector Shoreline Plus.",
18
+ "Location": "{\"wfs\":\"http://geoserver01.uit.tufts.edu/wfs\",\"wms\":[\"http://geoserver01.uit.tufts.edu/wms\"]}",
19
+ "MaxY": 90,
20
+ "MinY": -90,
21
+ "MaxX": 180,
22
+ "MinX": -180,
23
+ "CenterX": 0,
24
+ "CenterY": 0,
25
+ "HalfWidth": 180,
26
+ "HalfHeight": 90,
27
+ "Area": 64800,
28
+ "WorkspaceName": "sde",
29
+ "ContentDate": "1995-01-01T01:01:01Z",
30
+ "FgdcText": "<?xml version=\"1.0\" encoding=\"ISO-8859-1\" standalone=\"no\"?>\n<metadata>\n\t<idinfo>\n\t\t<citation>\n\t\t\t<citeinfo>\n\t\t\t\t<origin>United States. National Imagery and Mapping Agency</origin>\n\t\t\t\t<pubdate>1995</pubdate>\n\t\t\t\t<title>Vector Shoreline Area World 1995</title>\n\t\t\t\t<geoform>vector digital data</geoform>\n\t\t\t\t<onlink>http://shoreline.noaa.gov/data/datasheets/wvs.html</onlink>\n\t\t\t\t<lworkcit>\n\t\t\t\t\t<citeinfo>\n\t\t\t\t\t\t<origin>United States. National Imagery and Mapping Agency</origin>\n\t\t\t\t\t\t<pubdate>1995</pubdate>\n\t\t\t\t\t\t<title>World Vector Shoreline Dataset</title>\n\t\t\t\t\t\t<pubinfo>\n\t\t\t\t\t\t\t<pubplace>Charleston (S.C.)</pubplace>\n\t\t\t\t\t\t\t<publish>United States. National Imagery and Mapping Agency</publish>\n\t\t\t\t\t\t</pubinfo>\n\t\t\t\t\t\t<onlink>http://shoreline.noaa.gov/data/datasheets/wvs.html</onlink>\n\t\t\t\t\t</citeinfo>\n\t\t\t\t</lworkcit>\n\t\t\t\t<ftname Sync=\"TRUE\">WorldShorelineArea95</ftname>\n</citeinfo>\n\t\t</citation>\n\t\t<descript>\n\t\t\t<abstract>This polygon dataset represents coastlines, countries, and oceans. This data set was originally created for mission planning for military operations. Other potential applications include cartographic representation and boundary determination. The original World Vector Shoreline (WVS) was a digital data file containing the shorelines, international boundaries, and country names of the world. WVS data were processed into NGAs Vector Product Format in 1995, resulting in the highest resolution demarcation of coastline globally available, the World Vector Shoreline Plus.</abstract>\n\t\t\t<purpose>This dataset is intended for researchers, students, and policy makers for reference and mapping purposes, and may be used for basic applications such as viewing, querying, and map output production, or to provide a basemap to support graphical overlays and analysis with other spatial data.</purpose>\n\t\t\t<langdata Sync=\"TRUE\">en</langdata>\n</descript>\n\t\t<timeperd>\n\t\t\t<timeinfo>\n\t\t\t\t<sngdate>\n\t\t\t\t\t<caldate>1995</caldate>\n\t\t\t\t</sngdate>\n\t\t\t</timeinfo>\n\t\t\t<current>publication date</current>\n\t\t</timeperd>\n\t\t<status>\n\t\t\t<progress>Complete</progress>\n\t\t\t<update>As needed</update>\n\t\t</status>\n\t\t<spdom>\n\t\t\t<bounding>\n\t\t\t\t<westbc>\n-180.000000</westbc>\n\t\t\t\t<eastbc>\n180.000000</eastbc>\n\t\t\t\t<northbc>\n90.000000</northbc>\n\t\t\t\t<southbc>\n-90.000000</southbc>\n\t\t\t</bounding>\n\t\t\t<lboundng>\n<leftbc Sync=\"TRUE\">-180.000000</leftbc>\n<rightbc Sync=\"TRUE\">180.000000</rightbc>\n<bottombc Sync=\"TRUE\">-90.000000</bottombc>\n<topbc Sync=\"TRUE\">90.000000</topbc>\n</lboundng>\n</spdom>\n\t\t<keywords>\n\t\t\t<theme>\n\t\t\t\t<themekt>FGDC</themekt>\n\t\t\t\t<themekey>polygon</themekey>\n\t\t\t</theme>\n\t\t\t<theme>\n\t\t\t\t<themekt>ISO 19115 Topic Category</themekt>\n\t\t\t\t<themekey>oceans</themekey>\n\t\t\t\t<themekey>boundaries</themekey>\n\t\t\t</theme>\n\t\t\t<theme>\n\t\t\t\t<themekt>LCSH</themekt>\n\t\t\t\t<themekey>Shorelines</themekey>\n\t\t\t\t<themekey>Boundaries</themekey>\n\t\t\t</theme>\n\t\t\t<place>\n\t\t\t\t<placekt>LCNH</placekt>\n\t\t\t\t<placekey>Northern Hemisphere</placekey>\n\t\t\t\t<placekey>Western Hemisphere</placekey>\n\t\t\t\t<placekey>Eastern Hemisphere</placekey>\n\t\t\t\t<placekey>Southern Hemisphere</placekey>\n\t\t\t\t<placekey>Africa</placekey>\n\t\t\t\t<placekey>South America</placekey>\n\t\t\t\t<placekey>North America</placekey>\n\t\t\t\t<placekey>Europe</placekey>\n\t\t\t\t<placekey>Asia</placekey>\n\t\t\t\t<placekey>Australia</placekey>\n\t\t\t\t<placekey>Polar Regions</placekey>\n\t\t\t</place>\n\t\t\t<place>\n\t\t\t\t<placekt>Getty</placekt>\n\t\t\t\t<placekey>World</placekey>\n\t\t\t</place>\n\t\t</keywords>\n\t\t<accconst>Unrestricted Access Online</accconst>\n\t\t<useconst>For educational noncommercial use only.</useconst>\n\t\t<ptcontac>\n\t\t\t<cntinfo>\n\t\t\t\t<cntorgp>\n\t\t\t\t\t<cntorg>NOAA Coastal Services Center</cntorg>\n\t\t\t\t</cntorgp>\n\t\t\t\t<cntaddr>\n\t\t\t\t\t<addrtype>mailing and physical address</addrtype>\n\t\t\t\t\t<address>NOAA Coastal Services Center</address>\n\t\t\t\t\t<address>2234 South Hobson Avenue</address>\n\t\t\t\t\t<city>Charleston</city>\n\t\t\t\t\t<state>South Carolina</state>\n\t\t\t\t\t<postal>29405-2413</postal>\n\t\t\t\t\t<country>USA</country>\n\t\t\t\t</cntaddr>\n\t\t\t\t<cntvoice>843-740-1200</cntvoice>\n\t\t\t\t<cntfax>843-740-1224</cntfax>\n\t\t\t\t<cntemail>csc@scs.noaa.gov</cntemail>\n\t\t\t</cntinfo>\n\t\t</ptcontac>\n\t\t<native>Microsoft Windows Vista Version 6.1 (Build 7601) Service Pack 1; ESRI ArcCatalog 9.3.1.4000</native>\n\t\t<natvform Sync=\"TRUE\">Shapefile</natvform>\n</idinfo>\n\t<dataqual>\n\t\t<lineage>\n\t\t\t<srcinfo>\n\t\t\t\t<srcscale>1:250,000</srcscale>\n\t\t\t</srcinfo>\n\t\t\t<procstep>\n\t\t\t\t<procdesc>Metadata imported.</procdesc>\n\t\t\t\t<srcused>C:\\Users\\nsusma01\\AppData\\Local\\Temp\\xmlEFBB.tmp</srcused>\n\t\t\t\t<procdate>20130212</procdate>\n\t\t\t\t<proctime>11073200</proctime>\n\t\t\t</procstep>\n\t\t\t<procstep>\n\t\t\t\t<procdesc>Metadata imported.</procdesc>\n\t\t\t\t<srcused>S:\\GIS_Center_Projects\\EnterpriseGIS\\Layers\\Starter Metadata Template -Tufts - UTF-8.xml</srcused>\n\t\t\t\t<procdate>20130308</procdate>\n\t\t\t\t<proctime>13413000</proctime>\n\t\t\t</procstep>\n\t\t\t<procstep>\n\t\t\t\t<procdesc>Name changed from cocarea to WorldShorelineArea95.</procdesc>\n\t\t\t\t<procdate>20130319</procdate>\n\t\t\t\t<proccont>\n\t\t\t\t\t<cntinfo>\n\t\t\t\t\t\t<cntorgp>\n\t\t\t\t\t\t\t<cntorg>Tufts University Geographic Information Systems Center</cntorg>\n\t\t\t\t\t\t</cntorgp>\n\t\t\t\t\t\t<cntpos>GIS Data Technician</cntpos>\n\t\t\t\t\t\t<cntaddr>\n\t\t\t\t\t\t\t<addrtype>mailing and physical address</addrtype>\n\t\t\t\t\t\t\t<address>Academic Technology</address>\n\t\t\t\t\t\t\t<address>16 Dearborn Ave</address>\n\t\t\t\t\t\t\t<city>Somerville</city>\n\t\t\t\t\t\t\t<state>MA</state>\n\t\t\t\t\t\t\t<postal>02144</postal>\n\t\t\t\t\t\t\t<country>USA</country>\n\t\t\t\t\t\t</cntaddr>\n\t\t\t\t\t\t<cntvoice>617-627-3380</cntvoice>\n\t\t\t\t\t\t<cntemail>gis-support@elist.tufts.edu</cntemail>\n\t\t\t\t\t\t<hours>Monday-Friday, 9:00 AM-5:00 PM, EST-USA</hours>\n\t\t\t\t\t</cntinfo>\n\t\t\t\t</proccont>\n\t\t\t</procstep>\n\t\t\t<procstep>\n\t\t\t\t<procdesc>Dataset copied.</procdesc>\n\t\t\t\t<srcused>\\\\UITATECHGISFL3\\C$\\Users\\nsusma01\\Desktop\\WVS.gdb</srcused>\n\t\t\t\t<procdate>20130319</procdate>\n\t\t\t\t<proctime>12470100</proctime>\n\t\t\t</procstep>\n\t\t</lineage>\n\t</dataqual>\n\t<spdoinfo>\n\t\t<direct>Vector</direct>\n\t\t<ptvctinf>\n\t\t\t<sdtsterm Name=\"WorldShorelineArea95\">\n\t\t\t\t<sdtstype>G-polygon</sdtstype>\n\t\t\t\t<ptvctcnt>193284</ptvctcnt>\n\t\t\t</sdtsterm>\n\t\t\t<esriterm Name=\"WorldShorelineArea95\">\n<efeatyp Sync=\"TRUE\">Simple</efeatyp>\n<efeageom Sync=\"TRUE\">Polygon</efeageom>\n<esritopo Sync=\"TRUE\">FALSE</esritopo>\n<efeacnt Sync=\"TRUE\">193284</efeacnt>\n<spindex Sync=\"TRUE\">TRUE</spindex>\n<linrefer Sync=\"TRUE\">FALSE</linrefer>\n</esriterm>\n</ptvctinf>\n\t</spdoinfo>\n\t<spref>\n\t\t<horizsys>\n\t\t\t<geograph>\n\t\t\t\t<latres>0.000000</latres>\n\t\t\t\t<longres>0.000000</longres>\n\t\t\t\t<geogunit>Decimal degrees</geogunit>\n\t\t\t</geograph>\n\t\t\t<geodetic>\n\t\t\t\t<horizdn>D_WGS_1984</horizdn>\n\t\t\t\t<ellips>WGS_1984</ellips>\n\t\t\t\t<semiaxis>6378137.000000</semiaxis>\n\t\t\t\t<denflat>298.257224</denflat>\n\t\t\t</geodetic>\n\t\t\t<cordsysn>\n<geogcsn Sync=\"TRUE\">GCS_WGS_1984</geogcsn>\n</cordsysn>\n</horizsys>\n\t</spref>\n\t<eainfo>\n\t\t<detailed Name=\"WorldShorelineArea95\">\n\t\t\t<enttyp>\n\t\t\t\t<enttypl>\nWorldShorelineArea95</enttypl>\n\t\t\t\t<enttypt Sync=\"TRUE\">Feature Class</enttypt>\n<enttypc Sync=\"TRUE\">193284</enttypc>\n</enttyp>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>FID</attrlabl>\n\t\t\t\t<attrdef>Internal feature number.</attrdef>\n\t\t\t\t<attrdefs>ESRI</attrdefs>\n\t\t\t\t<attrdomv>\n\t\t\t\t\t<udom>Sequential unique whole numbers that are automatically generated.</udom>\n\t\t\t\t</attrdomv>\n\t\t\t\t<attalias Sync=\"TRUE\">FID</attalias>\n<attrtype Sync=\"TRUE\">OID</attrtype>\n<attwidth Sync=\"TRUE\">4</attwidth>\n<atprecis Sync=\"TRUE\">0</atprecis>\n<attscale Sync=\"TRUE\">0</attscale>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>Shape</attrlabl>\n\t\t\t\t<attrdef>Feature geometry.</attrdef>\n\t\t\t\t<attrdefs>Environmental Systems Research Institute (Redlands, Calif.)</attrdefs>\n\t\t\t\t<attrdomv>\n\t\t\t\t\t<udom>Coordinates defining the features.</udom>\n\t\t\t\t</attrdomv>\n\t\t\t\t<attalias Sync=\"TRUE\">Shape</attalias>\n<attrtype Sync=\"TRUE\">Geometry</attrtype>\n<attwidth Sync=\"TRUE\">0</attwidth>\n<atprecis Sync=\"TRUE\">0</atprecis>\n<attscale Sync=\"TRUE\">0</attscale>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>OBJECTID_1</attrlabl>\n\t\t\t\t<attrdef>Unique identifier</attrdef>\n\t\t\t\t<attrdefs>Tufts University. Geographic Information Systems Center</attrdefs>\n\t\t\t\t<attalias Sync=\"TRUE\">OBJECTID_1</attalias>\n<attrtype Sync=\"TRUE\">Number</attrtype>\n<attwidth Sync=\"TRUE\">9</attwidth>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>fac_id</attrlabl>\n\t\t\t\t<attrdef>Unknown attribute</attrdef>\n\t\t\t\t<attrdefs>Tufts University. Geographic Information Systems Center</attrdefs>\n\t\t\t\t<attalias Sync=\"TRUE\">fac_id</attalias>\n<attrtype Sync=\"TRUE\">Number</attrtype>\n<attwidth Sync=\"TRUE\">9</attwidth>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>facc</attrlabl>\n\t\t\t\t<attrdef>Feature and attribute coding catalog identifier</attrdef>\n\t\t\t\t<attrdefs>Tufts University. Geographic Information Systems Center</attrdefs>\n\t\t\t\t<attrdomv>\n\t\t\t\t\t<edom>\n\t\t\t\t\t\t<edomv>BA040</edomv>\n\t\t\t\t\t\t<edomvd>Water (except inland)</edomvd>\n\t\t\t\t\t\t<edomvds>Tufts University. Geographic Information Systems Center</edomvds>\n\t\t\t\t\t</edom>\n\t\t\t\t</attrdomv>\n\t\t\t\t<attrdomv>\n\t\t\t\t\t<edom>\n\t\t\t\t\t\t<edomv>FA001</edomv>\n\t\t\t\t\t\t<edomvd>Administrative area</edomvd>\n\t\t\t\t\t\t<edomvds>Tufts University. Geographic Information Systems Center</edomvds>\n\t\t\t\t\t</edom>\n\t\t\t\t</attrdomv>\n\t\t\t\t<attalias Sync=\"TRUE\">facc</attalias>\n<attrtype Sync=\"TRUE\">String</attrtype>\n<attwidth Sync=\"TRUE\">5</attwidth>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>facc_descr</attrlabl>\n\t\t\t\t<attalias Sync=\"TRUE\">facc_descr</attalias>\n<attrtype Sync=\"TRUE\">String</attrtype>\n<attwidth Sync=\"TRUE\">254</attwidth>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>nam</attrlabl>\n\t\t\t\t<attrdef>Abbreviated name of the country</attrdef>\n\t\t\t\t<attrdefs>Tufts University. Geographic Information Systems Center</attrdefs>\n\t\t\t\t<attalias Sync=\"TRUE\">nam</attalias>\n<attrtype Sync=\"TRUE\">String</attrtype>\n<attwidth Sync=\"TRUE\">2</attwidth>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>nam_descri</attrlabl>\n\t\t\t\t<attalias Sync=\"TRUE\">nam_descri</attalias>\n<attrtype Sync=\"TRUE\">String</attrtype>\n<attwidth Sync=\"TRUE\">254</attwidth>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>tile_id</attrlabl>\n\t\t\t\t<attrdef>Unique identifier of the tile</attrdef>\n\t\t\t\t<attrdefs>Tufts University. Geographic Information Systems Center</attrdefs>\n\t\t\t\t<attalias Sync=\"TRUE\">tile_id</attalias>\n<attrtype Sync=\"TRUE\">Number</attrtype>\n<attwidth Sync=\"TRUE\">4</attwidth>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>Shape_Leng</attrlabl>\n\t\t\t\t<attalias Sync=\"TRUE\">Shape_Leng</attalias>\n<attrtype Sync=\"TRUE\">Float</attrtype>\n<attwidth Sync=\"TRUE\">19</attwidth>\n<atnumdec Sync=\"TRUE\">11</atnumdec>\n</attr>\n\t\t\t<attr>\n\t\t\t\t<attrlabl>Shape_Area</attrlabl>\n\t\t\t\t<attrdef>Area of feature in internal units squared.</attrdef>\n\t\t\t\t<attrdefs>Environmental Systems Research Institute (Redlands, Calif.)</attrdefs>\n\t\t\t\t<attrdomv>\n\t\t\t\t\t<udom>Positive real numbers that are automatically generated.</udom>\n\t\t\t\t</attrdomv>\n\t\t\t\t<attalias Sync=\"TRUE\">Shape_Area</attalias>\n<attrtype Sync=\"TRUE\">Float</attrtype>\n<attwidth Sync=\"TRUE\">19</attwidth>\n<atnumdec Sync=\"TRUE\">11</atnumdec>\n</attr>\n\t\t</detailed>\n\t</eainfo>\n\t<distinfo>\n\t\t<distrib>\n\t\t\t<cntinfo>\n\t\t\t\t<cntorgp>\n\t\t\t\t\t<cntorg>Tufts University GIS Center</cntorg>\n\t\t\t\t</cntorgp>\n\t\t\t\t<cntpos>GIS Data Analyst</cntpos>\n\t\t\t\t<cntaddr>\n\t\t\t\t\t<addrtype>mailing and physical address</addrtype>\n\t\t\t\t\t<address>Academic Technology</address>\n\t\t\t\t\t<address>16 Dearborn Ave</address>\n\t\t\t\t\t<city>Somerville</city>\n\t\t\t\t\t<state>MA</state>\n\t\t\t\t\t<postal>02144</postal>\n\t\t\t\t\t<country>USA</country>\n\t\t\t\t</cntaddr>\n\t\t\t\t<cntvoice>617-627-3380</cntvoice>\n\t\t\t\t<cntemail>gis-support@elist.tufts.edu</cntemail>\n\t\t\t\t<hours>Monday-Friday, 9:00 AM-5:00 PM, EST-USA</hours>\n\t\t\t</cntinfo>\n\t\t</distrib>\n\t\t<resdesc>Online Dataset</resdesc>\n\t\t<stdorder>\n\t\t\t<digform>\n\t\t\t\t<digtinfo>\n\t\t\t\t\t<transize>178.944</transize>\n\t\t\t\t\t<dssize Sync=\"TRUE\">178.944</dssize>\n</digtinfo>\n\t\t\t</digform>\n\t\t</stdorder>\n\t</distinfo>\n\t<metainfo>\n\t\t<metd>20130416</metd>\n\t\t<metc>\n\t\t\t<cntinfo>\n\t\t\t\t<cntorgp>\n\t\t\t\t\t<cntorg>Tufts University GIS Center</cntorg>\n\t\t\t\t\t<cntper>REQUIRED: The person responsible for the metadata information.</cntper>\n\t\t\t\t</cntorgp>\n\t\t\t\t<cntpos>GIS Data Analyst</cntpos>\n\t\t\t\t<cntaddr>\n\t\t\t\t\t<addrtype>mailing and physical address</addrtype>\n\t\t\t\t\t<address>Academic Technology</address>\n\t\t\t\t\t<address>16 Dearborn Ave</address>\n\t\t\t\t\t<city>Somerville</city>\n\t\t\t\t\t<state>MA</state>\n\t\t\t\t\t<postal>02144</postal>\n\t\t\t\t\t<country>USA</country>\n\t\t\t\t</cntaddr>\n\t\t\t\t<cntvoice>617-627-3380</cntvoice>\n\t\t\t\t<cntemail>gis-support@elist.tufts.edu</cntemail>\n\t\t\t\t<hours>Monday-Friday, 9:00 AM-5:00 PM, EST-USA</hours>\n\t\t\t</cntinfo>\n\t\t</metc>\n\t\t<metstdn>FGDC Content Standards for Digital Geospatial Metadata</metstdn>\n\t\t<metstdv>FGDC-STD-001-1998</metstdv>\n\t\t<mettc>local time</mettc>\n\t\t<metextns>\n\t\t\t<onlink>http://www.esri.com/metadata/esriprof80.html</onlink>\n\t\t\t<metprof>ESRI Metadata Profile</metprof>\n\t\t</metextns>\n\t\t<metextns>\n\t\t\t<onlink>http://www.esri.com/metadata/esriprof80.html</onlink>\n\t\t\t<metprof>ESRI Metadata Profile</metprof>\n\t\t</metextns>\n\t\t<langmeta Sync=\"TRUE\">en</langmeta>\n<metextns>\n<onlink Sync=\"TRUE\">http://www.esri.com/metadata/esriprof80.html</onlink>\n<metprof Sync=\"TRUE\">ESRI Metadata Profile</metprof>\n</metextns>\n</metainfo>\n\t<dataIdInfo>\n<envirDesc Sync=\"TRUE\">Microsoft Windows Vista Version 6.1 (Build 7601) Service Pack 1; ESRI ArcCatalog 9.3.1.4000</envirDesc>\n<dataLang>\n<languageCode Sync=\"TRUE\" value=\"en\"/>\n</dataLang>\n<idCitation>\n<resTitle Sync=\"TRUE\">WorldShorelineArea95</resTitle>\n<presForm>\n<PresFormCd Sync=\"TRUE\" value=\"005\"/>\n</presForm>\n</idCitation>\n<spatRpType>\n<SpatRepTypCd Sync=\"TRUE\" value=\"001\"/>\n</spatRpType>\n<dataExt>\n<geoEle>\n<GeoBndBox esriExtentType=\"native\">\n<westBL Sync=\"TRUE\">-180</westBL>\n<eastBL Sync=\"TRUE\">180</eastBL>\n<northBL Sync=\"TRUE\">90</northBL>\n<southBL Sync=\"TRUE\">-90</southBL>\n<exTypeCode Sync=\"TRUE\">1</exTypeCode>\n</GeoBndBox>\n</geoEle>\n</dataExt>\n<geoBox esriExtentType=\"decdegrees\">\n<westBL Sync=\"TRUE\">-180</westBL>\n<eastBL Sync=\"TRUE\">180</eastBL>\n<northBL Sync=\"TRUE\">90</northBL>\n<southBL Sync=\"TRUE\">-90</southBL>\n<exTypeCode Sync=\"TRUE\">1</exTypeCode>\n</geoBox>\n</dataIdInfo>\n<mdLang>\n<languageCode Sync=\"TRUE\" value=\"en\"/>\n</mdLang>\n<mdStanName Sync=\"TRUE\">ISO 19115 Geographic Information - Metadata</mdStanName>\n<mdStanVer Sync=\"TRUE\">DIS_ESRI1.0</mdStanVer>\n<mdChar>\n<CharSetCd Sync=\"TRUE\" value=\"004\"/>\n</mdChar>\n<mdHrLv>\n<ScopeCd Sync=\"TRUE\" value=\"005\"/>\n</mdHrLv>\n<mdHrLvName Sync=\"TRUE\">dataset</mdHrLvName>\n<distInfo>\n<distributor>\n<distorTran>\n<onLineSrc>\n<orDesc Sync=\"TRUE\">002</orDesc>\n<linkage Sync=\"TRUE\">file://\\\\rstore2\\gisprojects$\\GIS_Center_Projects\\EnterpriseGIS\\Layers\\WVS\\WorldShorelineArea95.shp</linkage>\n<protocol Sync=\"TRUE\">Local Area Network</protocol>\n</onLineSrc>\n<transSize Sync=\"TRUE\">178.944</transSize>\n</distorTran>\n<distorFormat>\n<formatName Sync=\"TRUE\">Shapefile</formatName>\n</distorFormat>\n</distributor>\n</distInfo>\n<refSysInfo>\n<RefSystem>\n<refSysID>\n<identCode Sync=\"TRUE\">GCS_WGS_1984</identCode>\n</refSysID>\n</RefSystem>\n</refSysInfo>\n<spatRepInfo>\n<VectSpatRep>\n<topLvl>\n<TopoLevCd Sync=\"TRUE\" value=\"001\"/>\n</topLvl>\n<geometObjs Name=\"WorldShorelineArea95\">\n<geoObjTyp>\n<GeoObjTypCd Sync=\"TRUE\" value=\"001\"/>\n</geoObjTyp>\n<geoObjCnt Sync=\"TRUE\">193284</geoObjCnt>\n</geometObjs>\n</VectSpatRep>\n</spatRepInfo>\n<Esri>\n<SyncDate>20131115</SyncDate>\n<SyncTime>13264400</SyncTime>\n<ModDate>20131115</ModDate>\n<ModTime>13264400</ModTime>\n</Esri>\n<mdDateSt Sync=\"TRUE\">20131115</mdDateSt>\n</metadata>\n"
31
+ }
@@ -18,4 +18,24 @@ module JsonDocs
18
18
  def esri_opendata_metadata
19
19
  File.read(File.join(File.dirname(__FILE__), './docs/esri_open_data.json'))
20
20
  end
21
+
22
+ def ckan_metadata
23
+ File.read(File.join(File.dirname(__FILE__), './docs/ckan.json'))
24
+ end
25
+
26
+ def ogp_harvard_raster
27
+ File.read(File.join(File.dirname(__FILE__), './docs/ogp_harvard_raster.json'))
28
+ end
29
+
30
+ def ogp_harvard_line
31
+ File.read(File.join(File.dirname(__FILE__), './docs/ogp_harvard_line.json'))
32
+ end
33
+
34
+ def ogp_tufts_vector
35
+ File.read(File.join(File.dirname(__FILE__), './docs/ogp_tufts_vector.json'))
36
+ end
37
+
38
+ def geoblacklight_pre_v1
39
+ File.read(File.join(File.dirname(__FILE__), './docs/geoblacklight_pre_v1.json'))
40
+ end
21
41
  end
@@ -0,0 +1,59 @@
1
+ require 'spec_helper'
2
+
3
+ RSpec.describe GeoCombine::BoundingBox do
4
+ subject(:valid) do
5
+ described_class.new(west: -180, east: 180, north: 90, south: -90)
6
+ end
7
+ describe '#to_envelope' do
8
+ it 'returns a valid envelope syntax' do
9
+ expect(valid.to_envelope).to eq 'ENVELOPE(-180.0, 180.0, 90.0, -90.0)'
10
+ end
11
+ end
12
+ describe '#valid?' do
13
+ context 'when valid' do
14
+ it { valid.valid? }
15
+ end
16
+ context 'when south > north' do
17
+ subject(:invalid) do
18
+ described_class.new(west: -180, east: 180, north: 33, south: 34)
19
+ end
20
+ it { expect { invalid.valid? }.to raise_error GeoCombine::Exceptions::InvalidGeometry }
21
+ end
22
+ context 'when west > east' do
23
+ subject(:invalid) do
24
+ described_class.new(west: 10, east: -20, north: 90, south: -90)
25
+ end
26
+ it { expect { invalid.valid? }.to raise_error GeoCombine::Exceptions::InvalidGeometry }
27
+ end
28
+ context 'when west out of range' do
29
+ subject(:invalid) do
30
+ described_class.new(west: -181, east: 180, north: 90, south: -90)
31
+ end
32
+ it { expect { invalid.valid? }.to raise_error GeoCombine::Exceptions::InvalidGeometry }
33
+ end
34
+ context 'when east out of range' do
35
+ subject(:invalid) do
36
+ described_class.new(west: -180, east: 181, north: 90, south: -90)
37
+ end
38
+ it { expect { invalid.valid? }.to raise_error GeoCombine::Exceptions::InvalidGeometry }
39
+ end
40
+ context 'when north out of range' do
41
+ subject(:invalid) do
42
+ described_class.new(west: -180, east: 180, north: 91, south: -90)
43
+ end
44
+ it { expect { invalid.valid? }.to raise_error GeoCombine::Exceptions::InvalidGeometry }
45
+ end
46
+ context 'when south out of range' do
47
+ subject(:invalid) do
48
+ described_class.new(west: -180, east: 180, north: 90, south: -91)
49
+ end
50
+ it { expect { invalid.valid? }.to raise_error GeoCombine::Exceptions::InvalidGeometry }
51
+ end
52
+ end
53
+ describe '.from_envelope' do
54
+ it { expect(described_class.from_envelope(valid.to_envelope).to_envelope).to eq valid.to_envelope }
55
+ end
56
+ describe '.from_string_delimiter' do
57
+ it { expect(described_class.from_string_delimiter('-180, -90, 180, 90').to_envelope).to eq valid.to_envelope }
58
+ end
59
+ end
@@ -0,0 +1,114 @@
1
+ require 'spec_helper'
2
+
3
+ RSpec.describe GeoCombine::CkanMetadata do
4
+ include JsonDocs
5
+ let(:ckan_sample) { GeoCombine::CkanMetadata.new(ckan_metadata) }
6
+ describe '#to_geoblacklight' do
7
+ it 'returns a GeoCombine::Geoblacklight' do
8
+ expect(ckan_sample.to_geoblacklight).to be_an GeoCombine::Geoblacklight
9
+ end
10
+ end
11
+ describe '#geoblacklight_terms' do
12
+ describe 'builds a hash which maps metadata' do
13
+ let(:metadata) { ckan_sample.instance_variable_get(:@metadata) }
14
+ it 'with dc_identifier_s' do
15
+ expect(ckan_sample.geoblacklight_terms).to include(dc_identifier_s: metadata['id'])
16
+ end
17
+ it 'with dc_title_s' do
18
+ expect(ckan_sample.geoblacklight_terms).to include(dc_title_s: metadata['title'])
19
+ end
20
+ it 'with dc_rights_s' do
21
+ expect(ckan_sample.geoblacklight_terms).to include(dc_rights_s: 'Public')
22
+ end
23
+ it 'with dct_provenance_s' do
24
+ expect(ckan_sample.geoblacklight_terms).to include(dct_provenance_s: metadata['organization']['title'])
25
+ end
26
+ it 'with layer_slug_s' do
27
+ expect(ckan_sample.geoblacklight_terms).to include(layer_slug_s: metadata['name'])
28
+ end
29
+ it 'with solr_geom' do
30
+ expect(ckan_sample.geoblacklight_terms).to include(solr_geom: 'ENVELOPE(-158.2, -105.7, 59.2, 8.9)')
31
+ end
32
+ it 'with dc_subject_sm' do
33
+ expect(ckan_sample.geoblacklight_terms[:dc_subject_sm].length).to eq 63
34
+ end
35
+ context 'with no information resources' do
36
+ let(:ckan_sample) do
37
+ ckan = GeoCombine::CkanMetadata.new(ckan_metadata)
38
+ metadata = ckan.instance_variable_get('@metadata')
39
+ metadata['resources'].delete_if { |resource| resource['resource_locator_function'] == 'information' }
40
+ ckan
41
+ end
42
+ it 'has no url (home page) in dct_references_s' do
43
+ expect(JSON.parse(ckan_sample.geoblacklight_terms[:dct_references_s])).not_to include('http://schema.org/url')
44
+ end
45
+ end
46
+ context 'with no download resources' do
47
+ let(:ckan_sample) do
48
+ ckan = GeoCombine::CkanMetadata.new(ckan_metadata)
49
+ metadata = ckan.instance_variable_get('@metadata')
50
+ metadata['resources'].delete_if { |resource| resource['resource_locator_function'] == 'download' }
51
+ ckan
52
+ end
53
+ it 'has no downloadUrl in dct_references_s' do
54
+ expect(ckan_sample.downloadable?).to be_falsey
55
+ expect(JSON.parse(ckan_sample.geoblacklight_terms[:dct_references_s])).not_to include('http://schema.org/downloadUrl')
56
+ end
57
+ end
58
+ context 'with a ZIP download' do
59
+ let(:ckan_sample) do
60
+ ckan = GeoCombine::CkanMetadata.new(ckan_metadata)
61
+ metadata = ckan.instance_variable_get('@metadata')
62
+ metadata['resources'] = [
63
+ {
64
+ 'resource_locator_function' => 'download',
65
+ 'format' => 'ZIP',
66
+ 'url' => 'https://example.com/layer.zip'
67
+ }
68
+ ]
69
+ ckan
70
+ end
71
+ it 'has a format and a download URL' do
72
+ expect(ckan_sample.downloadable?).to be_truthy
73
+ expect(ckan_sample.geoblacklight_terms).to include(dc_format_s: 'ZIP')
74
+ expect(JSON.parse(ckan_sample.geoblacklight_terms[:dct_references_s])).to include('http://schema.org/downloadUrl' => 'https://example.com/layer.zip')
75
+ end
76
+ end
77
+ context 'without any resources' do
78
+ let(:ckan_sample) do
79
+ ckan = GeoCombine::CkanMetadata.new(ckan_metadata)
80
+ metadata = ckan.instance_variable_get('@metadata')
81
+ metadata.delete('resources')
82
+ ckan
83
+ end
84
+ it 'has no urls in dct_references_s' do
85
+ expect(ckan_sample.downloadable?).to be_falsey
86
+ expect(JSON.parse(ckan_sample.geoblacklight_terms[:dct_references_s])).not_to include('http://schema.org/url')
87
+ expect(JSON.parse(ckan_sample.geoblacklight_terms[:dct_references_s])).not_to include('http://schema.org/downloadUrl')
88
+ end
89
+ end
90
+ context 'with very long descriptions' do
91
+ let(:ckan_sample) do
92
+ ckan = GeoCombine::CkanMetadata.new(ckan_metadata)
93
+ metadata = ckan.instance_variable_get('@metadata')
94
+ metadata['notes'] = 'x' * 50000
95
+ ckan
96
+ end
97
+ it 'restricts the size' do
98
+ expect(ckan_sample.geoblacklight_terms[:dc_description_s].length).to eq GeoCombine::CkanMetadata::MAX_STRING_LENGTH + 1
99
+ end
100
+ end
101
+ context 'with no descriptions' do
102
+ let(:ckan_sample) do
103
+ ckan = GeoCombine::CkanMetadata.new(ckan_metadata)
104
+ metadata = ckan.instance_variable_get('@metadata')
105
+ metadata['notes'] = nil
106
+ ckan
107
+ end
108
+ it 'omits the description' do
109
+ expect(ckan_sample.geoblacklight_terms).not_to include(:dc_description_s)
110
+ end
111
+ end
112
+ end
113
+ end
114
+ end
@@ -21,9 +21,6 @@ RSpec.describe GeoCombine::EsriOpenData do
21
21
  describe '#geoblacklight_terms' do
22
22
  describe 'builds a hash which maps metadata' do
23
23
  let(:metadata) { esri_sample.instance_variable_get(:@metadata) }
24
- it 'with uuid' do
25
- expect(esri_sample.geoblacklight_terms).to include(uuid: metadata['id'])
26
- end
27
24
  it 'with dc_identifier_s' do
28
25
  expect(esri_sample.geoblacklight_terms).to include(dc_identifier_s: metadata['id'])
29
26
  end
@@ -44,10 +41,6 @@ RSpec.describe GeoCombine::EsriOpenData do
44
41
  expect(esri_sample).to receive(:references).and_return ''
45
42
  expect(esri_sample.geoblacklight_terms).to include(:dct_references_s)
46
43
  end
47
- it 'with georss_box_s' do
48
- expect(esri_sample).to receive(:georss_box).and_return ''
49
- expect(esri_sample.geoblacklight_terms).to include(georss_box_s: '')
50
- end
51
44
  it 'with layer_id_s that is blank' do
52
45
  expect(esri_sample.geoblacklight_terms).to include(layer_id_s: '')
53
46
  end
@@ -81,16 +74,10 @@ RSpec.describe GeoCombine::EsriOpenData do
81
74
  expect(esri_sample.references_hash).to include('http://resources.arcgis.com/en/help/arcgis-rest-api' => metadata['url'])
82
75
  end
83
76
  end
84
- describe '#georss_box' do
85
- it 'creates a GeoRSS box' do
86
- expect(esri_sample.georss_box).to be_an String
87
- expect(esri_sample.georss_box.split(' ').count).to eq 4
88
- end
89
- end
90
77
  describe '#envelope' do
91
78
  it 'creates an envelope for use in Solr' do
92
79
  expect(esri_sample.envelope).to be_an String
93
- expect(esri_sample.envelope).to match /ENVELOPE\(/
80
+ expect(esri_sample.envelope).to match /ENVELOPE\(.+,.+,.+,.+\)/
94
81
  end
95
82
  end
96
83
  end
@@ -19,16 +19,18 @@ RSpec.describe GeoCombine::Fgdc do
19
19
  end
20
20
  end
21
21
  describe '#to_geoblacklight' do
22
- let(:fgdc_geobl) { fgdc_object.to_geoblacklight(dct_references_s: '', ) }
22
+ let(:fgdc_geobl) { fgdc_object.to_geoblacklight }
23
23
  it 'returns a GeoCombine::Geoblacklight object' do
24
24
  expect(fgdc_geobl).to be_an GeoCombine::Geoblacklight
25
25
  end
26
- it 'is not valid' do
27
- expect { fgdc_geobl.valid? }.to raise_error
26
+ it 'is not valid due to bad modification date but valid otherwise' do
27
+ expect { fgdc_geobl.valid? }.to raise_error(JSON::Schema::ValidationError, /layer_modified_dt/)
28
+ fgdc_geobl.metadata.delete 'layer_modified_dt'
29
+ expect(fgdc_geobl.valid?).to be_truthy
28
30
  end
29
31
  describe 'with GeoBlacklight-Schema fields' do
30
- it 'uuid' do
31
- expect(fgdc_geobl.metadata['uuid']).to eq 'Ecuador50KDrillingTower11'
32
+ it 'geoblacklight_version' do
33
+ expect(fgdc_geobl.metadata['geoblacklight_version']).to eq '1.0'
32
34
  end
33
35
  it 'dc_identifier_s' do
34
36
  expect(fgdc_geobl.metadata['dc_identifier_s']).to eq 'http://www.geoportaligm.gob.ec/portal/'
@@ -59,7 +61,7 @@ RSpec.describe GeoCombine::Fgdc do
59
61
  expect(fgdc_geobl.metadata['dc_creator_sm']).to include 'Instituto Geografico Militar (Ecuador)'
60
62
  end
61
63
  it 'dc_format_s' do
62
- expect(fgdc_geobl.metadata['dc_format_s']).to eq 'application/x-esri-shapefile'
64
+ expect(fgdc_geobl.metadata['dc_format_s']).to eq 'Shapefile'
63
65
  end
64
66
  it 'dc_language_s' do
65
67
  expect(fgdc_geobl.metadata['dc_language_s']).to eq 'English'
@@ -79,23 +81,18 @@ RSpec.describe GeoCombine::Fgdc do
79
81
  expect(fgdc_geobl.metadata['dct_issued_s']).to eq '2011'
80
82
  end
81
83
  it 'dct_temporal_sm' do
82
- expect(fgdc_geobl.metadata['dct_temporal_sm']).to eq '2011'
84
+ expect(fgdc_geobl.metadata['dct_temporal_sm']).to be_an Array
85
+ expect(fgdc_geobl.metadata['dct_temporal_sm']).to include '2011'
83
86
  end
84
87
  it 'dct_isPartOf_sm' do
85
88
  expect(fgdc_geobl.metadata['dct_isPartOf_sm']).to be_an Array
86
89
  expect(fgdc_geobl.metadata['dct_isPartOf_sm']).to include 'Ecuador', 'Instituto Geografico Militar Data'
87
90
  end
88
- it 'georss_polygon_s' do
89
- expect(fgdc_geobl.metadata['georss_polygon_s']).to eq '-1.377743 -79.904768 -1.377743 -79.904768 -1.377743 -79.904768 -1.377743 -79.904768 -1.377743 -79.904768'
90
- end
91
91
  it 'solr_geom' do
92
92
  expect(fgdc_geobl.metadata['solr_geom']).to eq 'ENVELOPE(-79.904768, -79.904768, -1.377743, -1.377743)'
93
93
  end
94
- it 'georss_box_s' do
95
- expect(fgdc_geobl.metadata['georss_box_s']).to eq '-1.377743 -79.904768 -1.377743 -79.904768'
96
- end
97
94
  it 'solr_year_i' do
98
- expect(fgdc_geobl.metadata['solr_year_i']).to eq '2011'
95
+ expect(fgdc_geobl.metadata['solr_year_i']).to eq 2011
99
96
  end
100
97
  end
101
98
  end