NIH | National Cancer Institute | NCI Wiki  

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Description:

Loads Code System found in source file using the loader specified.

Input:

  • java.net.URI source - (Mandatory) URI corresponding to the code system file.
  • java.net.URI metadata - (Optional) URI of the XML file containing custom code system meta data. Loads additional data to be maintained and queried as terminology meta-information within the system. All tags and values are interpreted as simple text-based key/value pairs.
  • java.net.URI manifest - (Optional) URI corresponding to the manifest file. The LexGrid Manifest accommodates the need to supplement or override default information provided by the source. More specifically, the manifest provides a means to customize the same code system metadata defined by the LexGrid model, since each element of the manifest extends directly from an element used to define the LexGrid coding scheme(aka code system) object. Each extended element allows for the administrator to specify whether the manifest definition replaces or supplements original values provided in the terminology source. Like the LexGrid Terminology model, the manifest is defined by a formal model mastered as XML Schema.
  • java.lang.String loaderName - (Mandatory) Loader to use for loading the code system. Use getSupportedLoaderNames() method to get all the loaders supported by the service.
    For example, 'OBOLoader' could be used to load code system source that is in OBO format, 'OWLLoader' for code system source in OWL format, 'LexGrid_Loader' for Code System in LexGrid XML format, etc.
  • boolean stopOnErrors - (Optional) default is false. True means stop if any load error is detected. False means attempt to load what can be loaded if recoverable errors are encountered.
  • boolean async - (Optional) Flag controlling whether load occurs in the calling thread.
    If true, the load will occur in a separate asynchronous process.
    If false, this method blocks until the load operation completes or fails. Regardless of setting, the getStatus and getLog calls are used to fetch results.
  • *boolean overwriteMetadata - (Optional) If true, existing meta data for the code system will be erased. If false, new meta data will be appended to existing meta data.
  • java.lang.String versionTag - (Optional) The tag (e.g "devel", "production", ...) to be set for the this code system.
  • boolean activate - (Optional) True: activates the code system after the load.

Output:

Array of edu.mayo.informatics.lexgrid.convert.utility.URNVersionPair - URN and Version of the loaded code system

Exception:

org.LexGrid.LexBIG.Exceptions.LBException

Sample Call:

  • Step 1: Instantiate CodeSystemLoadOperation if it is not done yet:
    Code Block
    org.lexevs.cts2.admin.load.CodeSystemLoadOperation csLoadOp = new org.lexevs.cts2.LexEvsCTS2Impl().getAdminOperation().getCodeSystemLoadOperation();
    
  • Step 2: Call load method by passing the inputfile location and other parameter values:
    Code Block
     URNVersionPair[] csloaded = csLoad.load(new File("resources/testData/fungal_anatomy.obo").toURI(), null, null, "OBOLoader", true, true, true, "DEV", true); 
    

Loading Code System

...

Object

This function provides the capability to load supplied Code System object.

...