adiwg-mdtranslator 1.2.1 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (254) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +7 -7
  3. data/Rakefile +1 -2
  4. data/adiwg-mdtranslator.gemspec +23 -23
  5. data/bin/mdtranslator +187 -155
  6. data/lib/adiwg/mdtranslator.rb +63 -38
  7. data/lib/adiwg/mdtranslator/internal/internal_metadata_obj.rb +123 -5
  8. data/lib/adiwg/mdtranslator/internal/module_coordinates.rb +55 -0
  9. data/lib/adiwg/mdtranslator/readers/mdJson/mdJson_reader.rb +98 -70
  10. data/lib/adiwg/mdtranslator/readers/mdJson/mdJson_validator.rb +13 -11
  11. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_additionalDocumentation.rb +13 -3
  12. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_address.rb +3 -1
  13. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_associatedResource.rb +22 -4
  14. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_boundingBox.rb +3 -1
  15. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_browseGraphic.rb +11 -1
  16. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_citation.rb +28 -9
  17. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_classedData.rb +49 -0
  18. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_classedDataItem.rb +53 -0
  19. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_contacts.rb +14 -12
  20. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_coverageInfo.rb +83 -0
  21. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_coverageItem.rb +136 -0
  22. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_dataDictionary.rb +9 -7
  23. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_dataQuality.rb +17 -3
  24. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_dateTime.rb +3 -1
  25. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_descriptiveKeyword.rb +22 -5
  26. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_dictionaryInfo.rb +18 -3
  27. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_digitalTransferOption.rb +80 -0
  28. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_dimension.rb +81 -0
  29. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_distributionInfo.rb +89 -0
  30. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_distributionOrder.rb +62 -0
  31. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_domain.rb +24 -5
  32. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_domainItem.rb +23 -4
  33. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_entity.rb +26 -7
  34. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_entityAttribute.rb +24 -1
  35. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_entityForeignKey.rb +20 -1
  36. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_entityIndex.rb +20 -1
  37. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_extent.rb +9 -7
  38. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_geoCoordSystem.rb +3 -1
  39. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_geoProperties.rb +9 -7
  40. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_geographicElement.rb +20 -18
  41. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_gridInfo.rb +67 -0
  42. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_imageInfo.rb +119 -0
  43. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_legalConstraint.rb +7 -1
  44. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_lineString.rb +5 -4
  45. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_lineage.rb +11 -5
  46. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_locale.rb +57 -0
  47. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_mdJson.rb +10 -9
  48. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_medium.rb +73 -0
  49. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_metadata.rb +14 -12
  50. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_metadataExtension.rb +3 -1
  51. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_metadataInfo.rb +35 -15
  52. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_onlineResource.rb +7 -1
  53. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_phone.rb +3 -1
  54. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_point.rb +5 -4
  55. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_polygon.rb +5 -4
  56. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_processStep.rb +19 -6
  57. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_resolution.rb +7 -1
  58. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_resourceFormat.rb +12 -1
  59. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_resourceIdentifier.rb +30 -5
  60. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_resourceInfo.rb +70 -33
  61. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_resourceMaintenance.rb +5 -3
  62. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_resourceSpecificUsage.rb +5 -3
  63. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_responsibleParty.rb +10 -8
  64. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_securityConstraint.rb +3 -1
  65. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/module_sensorInfo.rb +69 -0
  66. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_source.rb +11 -5
  67. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_spatialReference.rb +3 -1
  68. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_taxonClass.rb +3 -1
  69. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_taxonomy.rb +11 -9
  70. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_temporalElement.rb +9 -7
  71. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_timeInstant.rb +5 -3
  72. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_timePeriod.rb +6 -4
  73. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_verticalElement.rb +3 -1
  74. data/lib/adiwg/mdtranslator/readers/mdJson/{modules_1.0 → modules_v1}/module_voucher.rb +5 -3
  75. data/lib/adiwg/mdtranslator/readers/mdJson/modules_v1/version.rb +19 -0
  76. data/lib/adiwg/mdtranslator/readers/mdReaders.rb +21 -18
  77. data/lib/adiwg/mdtranslator/version.rb +15 -1
  78. data/lib/adiwg/mdtranslator/writers/html/html_writer.rb +11 -8
  79. data/lib/adiwg/mdtranslator/writers/html/md_html_writer.rb +21 -18
  80. data/lib/adiwg/mdtranslator/writers/html/sections/html_additionalDocumentation.rb +48 -0
  81. data/lib/adiwg/mdtranslator/writers/html/sections/html_associatedResource.rb +73 -0
  82. data/lib/adiwg/mdtranslator/writers/html/sections/html_body.rb +84 -135
  83. data/lib/adiwg/mdtranslator/writers/html/sections/html_citation.rb +18 -8
  84. data/lib/adiwg/mdtranslator/writers/html/sections/html_classedData.rb +50 -0
  85. data/lib/adiwg/mdtranslator/writers/html/sections/html_classedDataItem.rb +50 -0
  86. data/lib/adiwg/mdtranslator/writers/html/sections/html_contact.rb +5 -9
  87. data/lib/adiwg/mdtranslator/writers/html/sections/html_coverageInfo.rb +88 -0
  88. data/lib/adiwg/mdtranslator/writers/html/sections/html_coverageItem.rb +139 -0
  89. data/lib/adiwg/mdtranslator/writers/html/sections/html_dataDictionary.rb +13 -12
  90. data/lib/adiwg/mdtranslator/writers/html/sections/html_dataLineage.rb +5 -4
  91. data/lib/adiwg/mdtranslator/writers/html/sections/html_dataSource.rb +5 -4
  92. data/lib/adiwg/mdtranslator/writers/html/sections/html_dimension.rb +71 -0
  93. data/lib/adiwg/mdtranslator/writers/html/sections/html_distributor.rb +62 -0
  94. data/lib/adiwg/mdtranslator/writers/html/sections/html_domain.rb +3 -2
  95. data/lib/adiwg/mdtranslator/writers/html/sections/html_entity.rb +5 -4
  96. data/lib/adiwg/mdtranslator/writers/html/sections/html_extent.rb +7 -6
  97. data/lib/adiwg/mdtranslator/writers/html/sections/html_format.rb +7 -1
  98. data/lib/adiwg/mdtranslator/writers/html/sections/html_geographicElement.rb +7 -7
  99. data/lib/adiwg/mdtranslator/writers/html/sections/html_gridInfo.rb +65 -0
  100. data/lib/adiwg/mdtranslator/writers/html/sections/html_head.rb +18 -3
  101. data/lib/adiwg/mdtranslator/writers/html/sections/html_imageInfo.rb +120 -0
  102. data/lib/adiwg/mdtranslator/writers/html/sections/html_inlineCss.css +13 -20
  103. data/lib/adiwg/mdtranslator/writers/html/sections/html_keyword.rb +3 -2
  104. data/lib/adiwg/mdtranslator/writers/html/sections/html_medium.rb +19 -2
  105. data/lib/adiwg/mdtranslator/writers/html/sections/html_metadataInfo.rb +22 -9
  106. data/lib/adiwg/mdtranslator/writers/html/sections/html_orderProcess.rb +3 -2
  107. data/lib/adiwg/mdtranslator/writers/html/sections/html_processStep.rb +5 -4
  108. data/lib/adiwg/mdtranslator/writers/html/sections/html_resourceContact.rb +3 -2
  109. data/lib/adiwg/mdtranslator/writers/html/sections/html_resourceGeneral.rb +25 -14
  110. data/lib/adiwg/mdtranslator/writers/html/sections/html_resourceId.rb +30 -3
  111. data/lib/adiwg/mdtranslator/writers/html/sections/html_resourceInfo.rb +194 -129
  112. data/lib/adiwg/mdtranslator/writers/html/sections/html_resourceMaint.rb +3 -2
  113. data/lib/adiwg/mdtranslator/writers/html/sections/html_resourceOther.rb +7 -6
  114. data/lib/adiwg/mdtranslator/writers/html/sections/html_resourceUsage.rb +3 -2
  115. data/lib/adiwg/mdtranslator/writers/html/sections/html_responsibleParty.rb +3 -2
  116. data/lib/adiwg/mdtranslator/writers/html/sections/html_sensorInfo.rb +66 -0
  117. data/lib/adiwg/mdtranslator/writers/html/sections/html_taxonomy.rb +7 -6
  118. data/lib/adiwg/mdtranslator/writers/html/sections/html_temporalElement.rb +7 -6
  119. data/lib/adiwg/mdtranslator/writers/html/sections/html_timeInstant.rb +3 -2
  120. data/lib/adiwg/mdtranslator/writers/html/sections/html_timePeriod.rb +3 -2
  121. data/lib/adiwg/mdtranslator/writers/html/sections/html_transferOption.rb +29 -4
  122. data/lib/adiwg/mdtranslator/writers/html/version.rb +17 -0
  123. data/lib/adiwg/mdtranslator/writers/iso19110/class_FCfeatureCatalogue.rb +17 -16
  124. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_address.rb +12 -8
  125. data/lib/adiwg/mdtranslator/writers/iso19110/classes/class_baseUnit.rb +42 -0
  126. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_codelist.rb +8 -3
  127. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_contact.rb +16 -25
  128. data/lib/adiwg/mdtranslator/writers/iso19110/classes/class_conventionalUnit.rb +68 -0
  129. data/lib/adiwg/mdtranslator/writers/iso19110/classes/class_definitionUnit.rb +39 -0
  130. data/lib/adiwg/mdtranslator/writers/iso19110/classes/class_derivedUnit.rb +46 -0
  131. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_featureAttribute.rb +17 -14
  132. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_featureConstraint.rb +6 -2
  133. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_featureType.rb +16 -12
  134. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_listedValue.rb +9 -18
  135. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_multiplicity.rb +8 -4
  136. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_onlineResource.rb +13 -9
  137. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_responsibleParty.rb +16 -12
  138. data/lib/adiwg/mdtranslator/writers/{iso → iso19110}/classes/class_telephone.rb +9 -5
  139. data/lib/adiwg/mdtranslator/writers/iso19110/classes/class_unitsOfMeasure.rb +262 -0
  140. data/lib/adiwg/mdtranslator/writers/iso19110/iso19110_writer.rb +36 -16
  141. data/lib/adiwg/mdtranslator/writers/iso19110/version.rb +14 -0
  142. data/lib/adiwg/mdtranslator/writers/iso19115_2/class_MImetadata.rb +73 -37
  143. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_address.rb +116 -0
  144. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_aggregateInformation.rb +13 -9
  145. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_band.rb +165 -0
  146. data/lib/adiwg/mdtranslator/writers/{iso/units → iso19115_2/classes}/class_baseUnit.rb +6 -6
  147. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_boundingPolygon.rb +14 -10
  148. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_browseGraphic.rb +9 -5
  149. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_citation.rb +31 -16
  150. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_codelist.rb +56 -0
  151. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_contact.rb +87 -0
  152. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_contentInfo.rb +111 -0
  153. data/lib/adiwg/mdtranslator/writers/{iso/units → iso19115_2/classes}/class_conventionalUnit.rb +6 -6
  154. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_dataIdentification.rb +106 -59
  155. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_dataQuality.rb +11 -7
  156. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_date.rb +8 -5
  157. data/lib/adiwg/mdtranslator/writers/{iso/units → iso19115_2/classes}/class_definitionUnit.rb +7 -7
  158. data/lib/adiwg/mdtranslator/writers/{iso/units → iso19115_2/classes}/class_derivedUnit.rb +6 -6
  159. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_digitalTransferOptions.rb +92 -0
  160. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_dimension.rb +68 -0
  161. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_distribution.rb +8 -4
  162. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_distributor.rb +44 -22
  163. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_enumerationList.rb +7 -2
  164. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_extent.rb +18 -14
  165. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_format.rb +18 -2
  166. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_geographicBoundingBox.rb +6 -2
  167. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_geographicDescription.rb +8 -4
  168. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_geographicElement.rb +10 -6
  169. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_gridInfo.rb +80 -0
  170. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_identifier.rb +10 -6
  171. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_imageDescription.rb +157 -0
  172. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_keyword.rb +12 -8
  173. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_legalConstraints.rb +12 -8
  174. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_lineString.rb +13 -10
  175. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_lineage.rb +14 -10
  176. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_locale.rb +67 -0
  177. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_maintenanceInformation.rb +12 -8
  178. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_medium.rb +30 -9
  179. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_metadataExtension.rb +19 -15
  180. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_multiGeometry.rb +22 -17
  181. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_onlineResource.rb +94 -0
  182. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_point.rb +12 -9
  183. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_polygon.rb +14 -11
  184. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_processStep.rb +12 -9
  185. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_rangeElementDescription.rb +88 -0
  186. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_referenceSystem.rb +52 -0
  187. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_resolution.rb +6 -2
  188. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_resourceIdentifier.rb +94 -0
  189. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_responsibleParty.rb +106 -0
  190. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_securityConstraints.rb +12 -8
  191. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_source.rb +12 -8
  192. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_standardOrderProcess.rb +11 -9
  193. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_taxonClassification.rb +8 -4
  194. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_taxonSystem.rb +18 -14
  195. data/lib/adiwg/mdtranslator/writers/iso19115_2/classes/class_telephone.rb +92 -0
  196. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_temporalExtent.rb +10 -6
  197. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_timeInstant.rb +9 -8
  198. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_timePeriod.rb +10 -8
  199. data/lib/adiwg/mdtranslator/writers/{iso/units → iso19115_2/classes}/class_unitsOfMeasure.rb +48 -25
  200. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_usage.rb +11 -7
  201. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_useConstraints.rb +6 -2
  202. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_verticalExtent.rb +6 -2
  203. data/lib/adiwg/mdtranslator/writers/{iso → iso19115_2}/classes/class_vouchers.rb +8 -4
  204. data/lib/adiwg/mdtranslator/writers/iso19115_2/iso19115_2_writer.rb +32 -19
  205. data/lib/adiwg/mdtranslator/writers/iso19115_2/version.rb +17 -0
  206. data/lib/adiwg/mdtranslator/writers/mdWriters.rb +21 -24
  207. data/test/readers/mdJson/v1/tc_reader_mdjson_additionalDocumentation.rb +116 -0
  208. data/test/readers/mdJson/v1/tc_reader_mdjson_address.rb +111 -0
  209. data/test/readers/mdJson/v1/tc_reader_mdjson_associatedResource.rb +157 -0
  210. data/test/readers/mdJson/v1/tc_reader_mdjson_browseGraphic.rb +119 -0
  211. data/test/readers/mdJson/v1/tc_reader_mdjson_citation.rb +143 -0
  212. data/test/readers/mdJson/v1/tc_reader_mdjson_contact.rb +138 -0
  213. data/test/readers/mdJson/v1/tc_reader_mdjson_dataQuality.rb +111 -0
  214. data/test/readers/mdJson/v1/tc_reader_mdjson_dateTime.rb +159 -0
  215. data/test/readers/mdJson/v1/tc_reader_mdjson_descriptiveKeyword.rb +115 -0
  216. data/test/readers/mdJson/v1/tc_reader_mdjson_dictionaryInfo.rb +121 -0
  217. data/test/readers/mdJson/v1/tc_reader_mdjson_digitalTransferOption.rb +94 -0
  218. data/test/readers/mdJson/v1/tc_reader_mdjson_distributionOrder.rb +103 -0
  219. data/test/readers/mdJson/v1/tc_reader_mdjson_domain.rb +130 -0
  220. data/test/readers/mdJson/v1/tc_reader_mdjson_domainItem.rb +98 -0
  221. data/test/readers/mdJson/v1/tc_reader_mdjson_entity.rb +134 -0
  222. data/test/readers/mdJson/v1/tc_reader_mdjson_entityAttribute.rb +154 -0
  223. data/test/readers/mdJson/v1/tc_reader_mdjson_entityForeignKey.rb +100 -0
  224. data/test/readers/mdJson/v1/tc_reader_mdjson_entityIndex.rb +99 -0
  225. data/test/readers/mdJson/v1/tc_reader_mdjson_legalConstraint.rb +104 -0
  226. data/test/readers/mdJson/v1/tc_reader_mdjson_lineage.rb +117 -0
  227. data/test/readers/mdJson/v1/tc_reader_mdjson_medium.rb +98 -0
  228. data/test/readers/mdJson/v1/tc_reader_mdjson_metadataInfo.rb +141 -0
  229. data/test/readers/mdJson/v1/tc_reader_mdjson_onlineResource.rb +110 -0
  230. data/test/readers/mdJson/v1/tc_reader_mdjson_phone.rb +112 -0
  231. data/test/readers/mdJson/v1/tc_reader_mdjson_processStep.rb +118 -0
  232. data/test/readers/mdJson/v1/tc_reader_mdjson_resolution.rb +77 -0
  233. data/test/readers/mdJson/v1/tc_reader_mdjson_source.rb +117 -0
  234. data/test/readers/mdJson/v1/tc_translation_19110.rb +57 -0
  235. data/test/readers/mdJson/{v1_0/tc_translation.rb → v1/tc_translation_19115_2.rb} +16 -31
  236. data/test/writers/iso19115_2/tc_writer_iso19115_2_address.rb +22 -15
  237. metadata +219 -140
  238. data/lib/adiwg/mdtranslator/readers/mdJson/modules_1.0/module_coordinates.rb +0 -63
  239. data/lib/adiwg/mdtranslator/readers/mdJson/modules_1.0/module_distributionInfo.rb +0 -161
  240. data/lib/adiwg/mdtranslator/writers/html/sections/logo150.txt +0 -25
  241. data/lib/adiwg/mdtranslator/writers/iso/classes/class_digitalTransferOptions.rb +0 -62
  242. data/lib/adiwg/mdtranslator/writers/iso/classes/class_genericMetaData.rb +0 -74
  243. data/lib/adiwg/mdtranslator/writers/iso/classes/class_referenceIdentifier.rb +0 -53
  244. data/lib/adiwg/mdtranslator/writers/iso/classes/class_referenceSystem.rb +0 -40
  245. data/test/readers/mdJson/v1_0/tc_reader_mdjson_additionalDocumentation.rb +0 -85
  246. data/test/readers/mdJson/v1_0/tc_reader_mdjson_address.rb +0 -100
  247. data/test/readers/mdJson/v1_0/tc_reader_mdjson_associatedResource.rb +0 -101
  248. data/test/readers/mdJson/v1_0/tc_reader_mdjson_browseGraphic.rb +0 -86
  249. data/test/readers/mdJson/v1_0/tc_reader_mdjson_citation.rb +0 -116
  250. data/test/readers/mdJson/v1_0/tc_reader_mdjson_contact.rb +0 -138
  251. data/test/readers/mdJson/v1_0/tc_reader_mdjson_dictionaryInfo.rb +0 -95
  252. data/test/readers/mdJson/v1_0/tc_reader_mdjson_domain.rb +0 -99
  253. data/test/readers/mdJson/v1_0/tc_reader_mdjson_onlineResource.rb +0 -92
  254. data/test/readers/mdJson/v1_0/tc_reader_mdjson_phone.rb +0 -110
@@ -2,27 +2,31 @@
2
2
  # writer output in XML
3
3
 
4
4
  # History:
5
- # Stan Smith 2013-11-19 original script
5
+ # Stan Smith 2013-11-19 original script.
6
6
  # Stan Smith 2014-07-08 modify require statements to function in RubyGem structure
7
7
  # Stan Smith 2014-12-12 refactored to handle namespacing readers and writers
8
+ # Stan Smith 2015-06-22 replace global ($response) with passed in object (responseObj)
9
+ # Stan Smith 2015-07-14 refactored to make iso19110 independent of iso19115_2 classes
10
+ # Stan Smith 2015-07-14 refactored to eliminate namespace globals $WriterNS and $IsoNS
8
11
 
9
- require 'class_responsibleParty'
12
+ require_relative 'class_responsibleParty'
10
13
 
11
14
  module ADIWG
12
15
  module Mdtranslator
13
16
  module Writers
14
- module Iso
17
+ module Iso19115_2
15
18
 
16
19
  class MD_Usage
17
20
 
18
- def initialize(xml)
21
+ def initialize(xml, responseObj)
19
22
  @xml = xml
23
+ @responseObj = responseObj
20
24
  end
21
25
 
22
26
  def writeXML(hUsage)
23
27
 
24
28
  # classes used in MD_Usage
25
- rPartyClass = $IsoNS::CI_ResponsibleParty.new(@xml)
29
+ rPartyClass = CI_ResponsibleParty.new(@xml, @responseObj)
26
30
 
27
31
  @xml.tag!('gmd:MD_Usage') do
28
32
 
@@ -42,7 +46,7 @@ module ADIWG
42
46
  @xml.tag!('gmd:userDeterminedLimitations') do
43
47
  @xml.tag!('gco:CharacterString', s)
44
48
  end
45
- elsif $showAllTags
49
+ elsif @responseObj[:writerShowTags]
46
50
  @xml.tag!('gmd:userDeterminedLimitations')
47
51
  end
48
52
 
@@ -54,7 +58,7 @@ module ADIWG
54
58
  rPartyClass.writeXML(rParty)
55
59
  end
56
60
  end
57
- elsif $showAllTags
61
+ elsif @responseObj[:writerShowTags]
58
62
  @xml.tag!('gmd:userContactInfo')
59
63
  end
60
64
 
@@ -4,16 +4,20 @@
4
4
  # History:
5
5
  # Stan Smith 2013-10-31 original script
6
6
  # Stan Smith 2014-12-12 refactored to handle namespacing readers and writers
7
+ # Stan Smith 2015-06-22 replace global ($response) with passed in object (responseObj)
8
+ # Stan Smith 2015-07-14 refactored to make iso19110 independent of iso19115_2 classes
9
+ # Stan Smith 2015-07-14 refactored to eliminate namespace globals $WriterNS and $IsoNS
7
10
 
8
11
  module ADIWG
9
12
  module Mdtranslator
10
13
  module Writers
11
- module Iso
14
+ module Iso19115_2
12
15
 
13
16
  class MD_Constraints
14
17
 
15
- def initialize(xml)
18
+ def initialize(xml, responseObj)
16
19
  @xml = xml
20
+ @responseObj = responseObj
17
21
  end
18
22
 
19
23
  def writeXML(aUseCons)
@@ -4,16 +4,20 @@
4
4
  # History:
5
5
  # Stan Smith 2013-11-15 original script
6
6
  # Stan Smith 2014-12-12 refactored to handle namespacing readers and writers
7
+ # Stan Smith 2015-06-22 replace global ($response) with passed in object (responseObj)
8
+ # Stan Smith 2015-07-14 refactored to make iso19110 independent of iso19115_2 classes
9
+ # Stan Smith 2015-07-14 refactored to eliminate namespace globals $WriterNS and $IsoNS
7
10
 
8
11
  module ADIWG
9
12
  module Mdtranslator
10
13
  module Writers
11
- module Iso
14
+ module Iso19115_2
12
15
 
13
16
  class EX_VerticalExtent
14
17
 
15
- def initialize(xml)
18
+ def initialize(xml, responseObj)
16
19
  @xml = xml
20
+ @responseObj = responseObj
17
21
  end
18
22
 
19
23
  def writeXML(hVertEle)
@@ -5,24 +5,28 @@
5
5
  # Stan Smith 2013-11-19 original script
6
6
  # Stan Smith 2014-07-08 modify require statements to function in RubyGem structure
7
7
  # Stan Smith 2014-12-12 refactored to handle namespacing readers and writers
8
+ # Stan Smith 2015-06-22 replace global ($response) with passed in object (responseObj)
9
+ # Stan Smith 2015-07-14 refactored to make iso19110 independent of iso19115_2 classes
10
+ # Stan Smith 2015-07-14 refactored to eliminate namespace globals $WriterNS and $IsoNS
8
11
 
9
- require 'class_responsibleParty'
12
+ require_relative 'class_responsibleParty'
10
13
 
11
14
  module ADIWG
12
15
  module Mdtranslator
13
16
  module Writers
14
- module Iso
17
+ module Iso19115_2
15
18
 
16
19
  class MD_Vouchers
17
20
 
18
- def initialize(xml)
21
+ def initialize(xml, responseObj)
19
22
  @xml = xml
23
+ @responseObj = responseObj
20
24
  end
21
25
 
22
26
  def writeXML(hVoucher)
23
27
 
24
28
  # classes used in MD_Vouchers
25
- rPartyClass = $IsoNS::CI_ResponsibleParty.new(@xml)
29
+ rPartyClass = CI_ResponsibleParty.new(@xml, @responseObj)
26
30
 
27
31
  @xml.tag!('gmd:MD_Vouchers') do
28
32
 
@@ -7,49 +7,52 @@
7
7
  # Stan Smith 2014-07-08 modify require statements to function in RubyGem structure
8
8
  # Stan Smith 2014-12-12 refactored to handle namespacing readers and writers
9
9
  # Stan Smith 2015-06-11 change all codelists to use 'class_codelist' method
10
-
11
- $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '../iso/classes'))
10
+ # Stan Smith 2015-06-22 replace global ($response) with passed in object (responseObj)
11
+ # Stan Smith 2015-07-14 refactored to make iso19110 independent of iso19115_2 classes
12
+ # Stan Smith 2015-07-14 refactored to eliminate namespace globals $WriterNS and $IsoNS
12
13
 
13
14
  require 'builder'
14
15
  require 'date'
15
16
  require 'uuidtools'
16
- require 'adiwg/mdtranslator/writers/iso19115_2/class_MImetadata'
17
+ require_relative 'version'
18
+ require_relative 'class_MImetadata'
17
19
 
18
20
  module ADIWG
19
21
  module Mdtranslator
20
22
  module Writers
21
23
  module Iso19115_2
22
24
 
23
- def self.startWriter(internalObj)
25
+ def self.startWriter(intObj, responseObj, paramsObj)
24
26
 
25
- # reset ISO id='' counter
26
- $idCount = '_000'
27
+ # make internal and response objects available to the instance
28
+ @intObj = intObj
29
+ @responseObj = responseObj
27
30
 
28
31
  # set the format of the output file based on the writer specified
29
- $response[:writerFormat] = 'xml'
30
- $response[:writerVersion] = ADIWG::Mdtranslator::VERSION
32
+ responseObj[:writerFormat] = 'xml'
33
+ responseObj[:writerVersion] = ADIWG::Mdtranslator::Writers::Iso19115_2::VERSION
31
34
 
32
35
  # pre-scan the internal object to create a new extents for each geometry
33
36
  # ... that has supplemental information (temporal, vertical, identity).
34
37
  # ... the new extents will be added to internalObj
35
- prescanGeoElements(internalObj)
38
+ prescanGeoElements()
36
39
 
37
40
  # create new XML document
38
41
  xml = Builder::XmlMarkup.new(indent: 3)
39
- metadataWriter = $WriterNS::MI_Metadata.new(xml)
40
- metadata = metadataWriter.writeXML(internalObj)
42
+ metadataWriter = MI_Metadata.new(xml, responseObj)
43
+ metadata = metadataWriter.writeXML(@intObj)
41
44
 
42
45
  # set writer pass to true if no writer modules set it to false
43
46
  # false or warning will be set by code that places the message
44
47
  # load metadata into $response
45
- if $response[:writerPass].nil?
46
- $response[:writerPass] = true
48
+ if responseObj[:writerPass].nil?
49
+ responseObj[:writerPass] = true
47
50
  end
48
51
 
49
52
  return metadata
50
53
  end
51
54
 
52
- def self.prescanGeoElements(internalObj)
55
+ def self.prescanGeoElements()
53
56
  # supplemental information for the geographic element is carried in the
54
57
  # ... internal structure in the temporalElements:, verticalElements:,
55
58
  # ... and elementIdentifiers: attributes of the extGeoElements:
@@ -61,7 +64,7 @@ module ADIWG
61
64
  # ... moves the supplemental information from the geometry to the new extent.
62
65
  # In this implementation, supplemental information is only allowed for
63
66
  # ... geometry types of Point, LineString, and Polygon
64
- aExtents = internalObj[:metadata][:resourceInfo][:extents]
67
+ aExtents = @intObj[:metadata][:resourceInfo][:extents]
65
68
  unless aExtents.empty?
66
69
  aExtents.each do |hExtent|
67
70
  aGeoElements = hExtent[:extGeoElements]
@@ -114,14 +117,14 @@ module ADIWG
114
117
  # ... it will match the supplemental information extent description
115
118
  geoID = hGeoElement[:elementId]
116
119
  if geoID.nil?
117
- $idCount = $idCount.succ
118
- geoID = geoType + $idCount
120
+ @responseObj[:writerMissingIdCount] = @responseObj[:writerMissingIdCount].succ
121
+ geoID = geoType + @responseObj[:writerMissingIdCount]
119
122
  hGeoElement[:elementId] = geoID
120
123
  end
121
124
 
122
125
  # build unique id for extent geometry
123
- $idCount = $idCount.succ
124
- extGeoID = geoType + $idCount
126
+ @responseObj[:writerMissingIdCount] = @responseObj[:writerMissingIdCount].succ
127
+ extGeoID = geoType + @responseObj[:writerMissingIdCount]
125
128
 
126
129
  intMetadataClass = InternalMetadata.new
127
130
  intExtent = intMetadataClass.newExtent
@@ -144,6 +147,16 @@ module ADIWG
144
147
 
145
148
  end
146
149
 
150
+ # find contact in contact array and return the contact hash
151
+ def self.getContact(contactID)
152
+ @intObj[:contacts].each do |hContact|
153
+ if hContact[:contactId] == contactID
154
+ return hContact
155
+ end
156
+ end
157
+ return {}
158
+ end
159
+
147
160
  end
148
161
 
149
162
  end
@@ -0,0 +1,17 @@
1
+ # mdJson version history
2
+ # 1.3.0 2015-07-30 added support for locale in metadata record information
3
+ # 1.3.0 2015-07-31 added support for grid information
4
+ # 1.3.0 2015-08-28 added support for content coverage information
5
+
6
+ module ADIWG
7
+ module Mdtranslator
8
+ module Writers
9
+ module Iso19115_2
10
+
11
+ # current version of iso19115_2 writer
12
+ VERSION = '1.3.0'
13
+
14
+ end
15
+ end
16
+ end
17
+ end
@@ -4,55 +4,52 @@
4
4
  # Stan Smith 2014-12-11 original script
5
5
  # Stan Smith 2012-12-16 generalized handleWriter to use :writerName
6
6
  # Stan Smith 2015-03-04 changed method of setting $WriterNS
7
+ # Stan Smith 2015-06-22 replace global ($response) with passed in object (responseObj)
8
+ # Stan Smith 2015-07-14 refactored to make iso19110 independent of iso19115_2 classes
9
+ # Stan Smith 2015-07-14 refactored to eliminate namespace globals $WriterNS and $IsoNS
7
10
 
8
11
  module ADIWG
9
12
  module Mdtranslator
10
13
  module Writers
11
14
 
12
- def self.handleWriter(intObj)
15
+ def self.handleWriter(intObj, responseObj, paramsObj)
13
16
 
14
- # this is a temp fix until the directory structure is changed
15
- if $response[:writerName] == 'iso'
16
- $response[:writerPass] = false
17
- $response[:writerMessages] << 'Writer not called - see following message(s):\n'
18
- $response[:writerMessages] << "Writer name 'iso' is not supported."
19
- return false
20
- end
21
-
22
- # use writer name to load and initiate requested writer
23
- # build directory path for writer from writerName
24
- writerDir = File.join(path_to_resources, $response[:writerName])
17
+ # use writerName from responseObj to build directory path to writer
18
+ # the writer's high level folder must be under the 'writers' directory
19
+ writerDir = File.join(path_to_writers, responseObj[:writerName])
25
20
  if File.directory?(writerDir)
26
21
 
27
- # if directory path exists, build writer file name and then require it
28
- writerFile = File.join(writerDir, $response[:writerName] + '_writer')
22
+ # if directory path exists, build writer file name and require it
23
+ writerFile = File.join(writerDir, responseObj[:writerName] + '_writer')
29
24
  require writerFile
30
- writerClassName = $response[:writerName].dup
31
- writerClassName[0] = writerClassName[0].upcase
32
- $WriterNS = ADIWG::Mdtranslator::Writers.const_get(writerClassName)
33
25
 
34
- # pass internal object to requested writer
35
- $response[:writerOutput] = $WriterNS.startWriter(intObj)
26
+ # build the namespace for the writer
27
+ writerNS = responseObj[:writerName].dup
28
+ writerNS[0] = writerNS[0].upcase
29
+
30
+ # pass internal object and response object to the writer
31
+ responseObj[:writerOutput] = ADIWG::Mdtranslator::Writers.const_get(writerNS).startWriter(intObj, responseObj, paramsObj)
36
32
 
37
33
  else
38
34
  # directory path was not found
39
- $response[:writerPass] = false
40
- $response[:writerMessages] << 'Writer not called - see following message(s):\n'
41
- $response[:writerMessages] << "Writer name '#{$response[:writerName]}' is not supported."
35
+ responseObj[:writerPass] = false
36
+ responseObj[:writerMessages] << 'Writer not called - see following message(s):\n'
37
+ responseObj[:writerMessages] << "Writer name '#{responseObj[:writerName]}' is not supported."
42
38
  return false
43
39
  end
44
40
 
45
41
  end
46
42
 
47
43
  # return path to writers
48
- def self.path_to_resources
44
+ def self.path_to_writers
49
45
  File.dirname(File.expand_path(__FILE__))
50
46
  end
51
47
 
52
48
  # return writer readme text
49
+ # this is called from the Rails API
53
50
  def self.get_writer_readme(writer)
54
51
  readmeText = 'No readme found'
55
- path = File.join(path_to_resources, writer, 'readme.md')
52
+ path = File.join(path_to_writers, writer, 'readme.md')
56
53
  if File.exist?(path)
57
54
  file = File.open(path, 'r')
58
55
  readmeText = file.read
@@ -0,0 +1,116 @@
1
+ # MdTranslator - minitest of
2
+ # reader / mdJson / module_additionalDocumentation
3
+
4
+ # History:
5
+ # Stan Smith 2014-12-30 original script
6
+ # Stan Smith 2015-06-22 refactored setup to after removal of globals
7
+
8
+ # set reader version used by mdJson_reader.rb to require correct modules
9
+ module ADIWG
10
+ module Mdtranslator
11
+ module Readers
12
+ module MdJson
13
+
14
+ @responseObj = {
15
+ readerVersionUsed: '1.2.0'
16
+ }
17
+
18
+ end
19
+ end
20
+ end
21
+ end
22
+
23
+ require 'minitest/autorun'
24
+ require 'json'
25
+ require 'adiwg/mdtranslator/internal/internal_metadata_obj'
26
+ require 'adiwg/mdtranslator/readers/mdJson/mdJson_reader'
27
+ require 'adiwg/mdtranslator/readers/mdJson/modules_v1/module_additionalDocumentation'
28
+
29
+ class TestReaderMdJsonAdditionalDocumentation_v1 < MiniTest::Test
30
+
31
+ # set variables for test
32
+ @@NameSpace = ADIWG::Mdtranslator::Readers::MdJson::AdditionalDocumentation
33
+ @@responseObj = {
34
+ readerVersionUsed: '1.0',
35
+ readerExecutionPass: true,
36
+ readerExecutionMessages: []
37
+ }
38
+
39
+ # get json file for tests from examples folder
40
+ file = File.join(File.dirname(__FILE__), '../../../', 'schemas/v1_0/examples', 'additionalDocumentation.json')
41
+ file = File.open(file, 'r')
42
+ jsonFile = file.read
43
+ file.close
44
+ aIn = JSON.parse(jsonFile)
45
+
46
+ # only the first instance in the example array is used for tests
47
+ # the first example is fully populated
48
+ # remove responsible party from citation to prevent search for contact
49
+ # in contact array which has not been loaded
50
+ @@hIn = aIn[0]
51
+ @@hIn['citation']['responsibleParty'] = []
52
+ @@hIn['citation']['identifier']= []
53
+
54
+ def test_complete_additionalDocumentation_object
55
+ hIn = Marshal::load(Marshal.dump(@@hIn))
56
+ hResponse = Marshal::load(Marshal.dump(@@responseObj))
57
+ metadata = @@NameSpace.unpack(hIn, hResponse)
58
+
59
+ assert_equal metadata[:resourceType], 'resourceType'
60
+ refute_empty metadata[:citation]
61
+ end
62
+
63
+ def test_empty_additionalDocumentation_citation
64
+ hIn = Marshal::load(Marshal.dump(@@hIn))
65
+ hIn['citation'] = ''
66
+ hResponse = Marshal::load(Marshal.dump(@@responseObj))
67
+ hResponse[:readerExecutionPass] = true
68
+ hResponse[:readerExecutionMessages] = []
69
+ metadata = @@NameSpace.unpack(hIn, hResponse)
70
+
71
+ assert_nil metadata
72
+ refute hResponse[:readerExecutionPass]
73
+ refute_empty hResponse[:readerExecutionMessages]
74
+ end
75
+
76
+ def test_missing_additionalDocumentation_citation
77
+ hIn = Marshal::load(Marshal.dump(@@hIn))
78
+ hIn.delete('citation')
79
+ hResponse = Marshal::load(Marshal.dump(@@responseObj))
80
+ hResponse[:readerExecutionPass] = true
81
+ hResponse[:readerExecutionMessages] = []
82
+ metadata = @@NameSpace.unpack(hIn, hResponse)
83
+
84
+ assert_nil metadata
85
+ refute hResponse[:readerExecutionPass]
86
+ refute_empty hResponse[:readerExecutionMessages]
87
+ end
88
+
89
+ def test_empty_additionalDocumentation_elements
90
+ hIn = Marshal::load(Marshal.dump(@@hIn))
91
+ hIn['resourceType'] = ''
92
+ hResponse = Marshal::load(Marshal.dump(@@responseObj))
93
+ metadata = @@NameSpace.unpack(hIn, hResponse)
94
+
95
+ assert_nil metadata[:resourceType]
96
+ refute_empty metadata[:citation]
97
+ end
98
+
99
+ def test_missing_additionalDocumentation_elements
100
+ hIn = Marshal::load(Marshal.dump(@@hIn))
101
+ hIn.delete('resourceType')
102
+ hResponse = Marshal::load(Marshal.dump(@@responseObj))
103
+ metadata = @@NameSpace.unpack(hIn, hResponse)
104
+
105
+ assert_nil metadata[:resourceType]
106
+ refute_empty metadata[:citation]
107
+ end
108
+
109
+ def test_empty_additionalDocumentation_object
110
+ hResponse = Marshal::load(Marshal.dump(@@responseObj))
111
+ metadata = @@NameSpace.unpack({}, hResponse)
112
+
113
+ assert_nil metadata
114
+ end
115
+
116
+ end