DLESE Tools
v1.6.0

org.dlese.dpc.schemedit.standards.adn
Class AsnToAdnMapper

java.lang.Object
  extended by org.dlese.dpc.schemedit.standards.adn.AsnToAdnMapper

public class AsnToAdnMapper
extends Object

Provides services for mapping between different standards formats, namely ASN and ADN (dlese), as well as convenience methods for translating between the different gradeRange representations.

Author:
Jonathan Ostwald

Constructor Summary
AsnToAdnMapper(String path)
          Constructor for the AsnToAdnMapper object
 
Method Summary
 String getAdnText(String asnId)
          Gets the adnText corresponding to asnId
 String getAsfId(String adnText)
          Given adnText, return asnId
 String getAsfText(String asnId)
          Gets the asnText corresponding to asnId
 int getEndGrade(String gradeRange)
          Gets the endGrade attribute of the AsnToAdnMapper object
 String getGradeRangeLabel(String gradeRangeValue)
          Gets the label (for UI purposes) of a gradeRange value.
 Collection getGradeRanges()
          Returns unordered set of registered gradeRanges represented as controlled DLESE vocab (e.g., "DLESE:Primary elementary") corresponding to the grades represented by ASF standards, namely, K-12.
 Collection getIds()
          Returns unordered set containing all registered asnIds;
 File getSource()
           
 int getStartGrade(String gradeRange)
          Gets the startGrade attribute of the AsnToAdnMapper object
static void main(String[] args)
          The main program for the AsnToAdnMapper class
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AsnToAdnMapper

public AsnToAdnMapper(String path)
Constructor for the AsnToAdnMapper object

Parameters:
path - path to xml file containing mappings from ansId to ansText and adnText
Method Detail

getSource

public File getSource()

getAsfId

public String getAsfId(String adnText)
Given adnText, return asnId

Parameters:
adnText - NOT YET DOCUMENTED
Returns:
The asnId value

getAsfText

public String getAsfText(String asnId)
Gets the asnText corresponding to asnId

Parameters:
asnId - NOT YET DOCUMENTED
Returns:
The asnText value

getAdnText

public String getAdnText(String asnId)
Gets the adnText corresponding to asnId

Parameters:
asnId - NOT YET DOCUMENTED
Returns:
The adnText value

getIds

public Collection getIds()
Returns unordered set containing all registered asnIds;

Returns:
The ids value

main

public static void main(String[] args)
The main program for the AsnToAdnMapper class

Parameters:
args - The command line arguments

getGradeRanges

public Collection getGradeRanges()
Returns unordered set of registered gradeRanges represented as controlled DLESE vocab (e.g., "DLESE:Primary elementary") corresponding to the grades represented by ASF standards, namely, K-12.

Returns:
The gradeRanges value

getGradeRangeLabel

public String getGradeRangeLabel(String gradeRangeValue)
Gets the label (for UI purposes) of a gradeRange value. E.g., for the value of "DLESE:Primary elementary", the label is "Primary elementary".

Parameters:
gradeRangeValue - NOT YET DOCUMENTED
Returns:
The gradeRangeLabel value

getStartGrade

public int getStartGrade(String gradeRange)
Gets the startGrade attribute of the AsnToAdnMapper object

Parameters:
gradeRange - NOT YET DOCUMENTED
Returns:
The startGrade value

getEndGrade

public int getEndGrade(String gradeRange)
Gets the endGrade attribute of the AsnToAdnMapper object

Parameters:
gradeRange - NOT YET DOCUMENTED
Returns:
The endGrade value

DLESE Tools
v1.6.0