mdTranslator

Directory Structure

/lib Directory

/lib holds all scripts for the mdTranslator gem:

  • adiwg-mdtranslator.rb - specifies the environment for the "adiwg-mdtranslator" gem.

  • /adiwg - holds all scripts for mdTranslator readers and writers.

lib Directory
Image 1: lib Directory

/lib/adiwg Directory

/adiwg directory holds all scripts for mdTranslator readers and writers:

  • mdtranslator.rb - entry point for the adiwg-mdtranslator gem.

  • mdtranslator_cli.rb - entry point and code for the CLI.

  • /mdtranslator - directory holds all scripts for mdTranslator readers and writers.

adiwg Directory
Image 2: adiwg Directory

/lib/adiwg/mdtranslator Directory

/mdtranslator - directory holds all scripts for mdTranslator readers and writers:

  • version.rb - keeps the version number for mdTranslator code and a history of changes.

  • /internal - holds methods used across multiple readers and writers.

  • /readers - holds the code for all mdTranslator readers.

  • /writers - holds the code for all mdTranslator writers.

mdtranslator Directory
Image 3: mdtranslator Directory

/lib/adiwg/mdtranslator/internal Directory

/internal - holds methods used across multiple readers and writers.

  • internal_metadata_obj.md - a collection of methods that construct objects that couple together to dynamically create the mdTranslator's internal data store.

  • module_codeListFun.md - a method to search a codelist for valid items.

  • module_coordinates.md - a collection of methods to convert lists of coordinates between strings and array in formats for ISO, FGDC, and GeoJSON. Includes a method for computing bounding box coordinates from a GeoJSON Feature Collection.

  • module_dateTimeFun.md - a collection of methods to handle date and time formats in ISO and string representations.

internal Directory
Image 4: internal Directory

/lib/adiwg/mdtranslator/readers Directory

/readers - holds all the code for mdTranslator readers.

  • mdReaders.rb - contains the method that accepts parameters from a call to mdTranslator and decides which reader to execute or to abort if a valid reader is not found. If reader returns valid internal data store from the read, control is passed to mdWriters.rb if a writer was requested, otherwise returns read status to the user.

  • /{reader name} - holds all the code for a specific reader. The directory name MUST be the code name of the reader.

readers Directory
Image 5: readers Directory

/lib/adiwg/mdtranslator/writers Directory

/writers - holds all the code for mdTranslator writers.

  • mdWriters.rb - contains the method that accepts parameters from mdReaders.rb and decides which writer to execute or to abort if a valid writer is not found. Returns results of the writer or error messages if writer execution fails.

  • /{writer name} - holds all the code for a specific writer. The directory name MUST be the code name of the writer.

writers Directory
Image 6: writers Directory

results matching ""

    No results matching ""