com.mmm.cms.homehealth.v2308_1
Class GrouperDataManager_v2308

java.lang.Object
  extended by com.mmm.cms.homehealth.v2308_1.GrouperDataManager_v2308
All Implemented Interfaces:
Initializable

public class GrouperDataManager_v2308
extends java.lang.Object
implements Initializable

This class provides the Data management related to the Diagnosis codes, the NRS Diagnosis codes, the Diagnostic Categories, the Etiology Pairs, and the optional V-Codes The information is loaded from text files. Refer to the loading methods for the file formats

See Also:
throws IOException, FileNotFoundException,IOException, throws FileNotFoundException, IOException

Field Summary
static java.lang.String DIAGNOSIS_ETIOLOGY_PAIRS
          Diagnosis code Secondary / Etiology pairs table name: DiagnosisEtiologyPairs.txt
static java.lang.String DIAGNOSTIC_CATEGORY_TABLENAME
          Diagnostic Category table name: diagnosticCategory.txt
static java.lang.String ICD_9_DIAGNOSIS_CODE_TABLENAME
          Diagnosis Code table name: diagnosisCodes.txt
static java.lang.String NRS_DIAGNOSTIC_CATEGORY_TABLENAME
          NRS Diagnostic Category table name: NRSDiagnosticCategory.txt
static java.lang.String NRS_ICD_9_DIAGNOSIS_CODE_TABLENAME
          NRS Diagnosis Code table name: nrsDiagnosisCodes.txt
static java.lang.String NRSSCORING_CASEMIX_ADJUSTMENT_TABLENAME
          NRS Scoring Case Mix Adjustment table name: NRSScoring_CasemixAdjustments.txt
static java.lang.String OPTIONAL_VCODES_TABLENAME
          Optional V-Code table name: OptionalVCodes.txt
static java.lang.String PROPERTY_INCLUDE_CODE_DESCRIPTIONS
          Property identifier for indicating that the code information should or should not inculde the code's description information.
static java.lang.String PROPERTY_NAME_BASE_PATH
          Property identifier for the data's base directory: base.path
static java.lang.String SCORING_CASEMIX_ADJUSTMENT_TABLENAME
          Scoring Case Mix Adjustment table name: Scoring_CasemixAdjustments.txt
 
Constructor Summary
GrouperDataManager_v2308()
           
 
Method Summary
 java.io.File getBasePath()
          Get the value of basePath which is the folder location of the data files
 CaseMixAdjustmentItemIF getCaseMixAdjustment(int caseMixId)
          This will search the case mix table for the case mix id, and return the case mix admjustment item
 Icd9DiagnosisCodeIF getDiagnosisCode(java.lang.String value)
          This is a proxy to getDiagnosisCodeBase
protected  Icd9DiagnosisCodeIF getDiagnosisCodeBase(java.util.Hashtable<java.lang.String,Icd9DiagnosisCodeIF> codes, java.lang.String value)
          Searchs the supplied diagnosis code table, codes, for the code value.
 DiagnosticCategoryIF getDiagnosticGroup(long id)
          Searches for the Diagnostic Group object based on its ID
 CaseMixAdjustmentItemIF getNRSCaseMixAdjustment(int caseMixId)
          This will search the case mix table for the case mix id, and return the case mix admjustment item
 Icd9DiagnosisCodeIF getNRSDiagnosisCode(java.lang.String value)
          This is a proxy to getDiagnosisCodeBase
 DiagnosticCategoryIF getNRSDiagnosticGroup(long id)
          Searches for the Non-Routine Supplies Diagnostic Category/Group based on the ID
 void init(java.util.Properties props)
          This loads all the data required to represent a version of the Home Health Grouper.
 void loadCaseMixAdjustments()
          Loads the Case mix adjustment values for the Clinical scoring The data is loaded from a tab separated file with the format: Id name equation 1 value equation 2 value equation 3 value equation 4 value
protected  void loadDiagnosisCodeBase(java.io.File file, java.util.Hashtable<java.lang.String,Icd9DiagnosisCodeIF> codeHash)
          This is a consolidated/generic Diagnosis code loaded that requires the input file, and the hashtable to put the codes into The data is loaded from a tab separated file with the format: Diagnosis Code Description Diagnosis Group Number Secondary only code indicated with M (without quotes) - can be blank Diabetes related indicator - D = Diabetes, U = Diabetic Ulcer - can be blank
protected  void loadDiagnosisCodes()
          This will add the Diagnosis Codes associated with this version.
protected  void loadDiagnosticCategoriesBase(java.io.File file, java.util.Hashtable<java.lang.Integer,DiagnosticCategoryIF> categoryHash)
          Loads the Diagnostic Group information from a text file.
protected  void loadDiagnosticGroups()
          Loads the Diagnostic Group information from a text file The data is loaded from a tab separated file with the format: Id Diagnostic Category/Group name
 void loadEtiologyPairs()
          IMPORTANT: This requires that the diagnosis codes are loaded first.
 void loadNRSCaseMixAdjustments()
          Loads the Case mix adjustment values for the Non-Routine Supplies scoring.
protected  void loadNRSDiagnosisCodes()
          Loads Non-Routine Supplies related Diagnosis codes.
protected  void loadNRSDiagnosticGroups()
          This loads the Non-Routine Supplies Diagnostic Categories using the loadDiagnosticCategoriesBase()
 void loadOptionalVCodes()
          IMPORTANT: This requires that the diagnosis codes are loaded first.
 void setBasePath(java.io.File basePath)
          Set the value of basePath which is the folder location of the data files
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PROPERTY_NAME_BASE_PATH

public static final java.lang.String PROPERTY_NAME_BASE_PATH
Property identifier for the data's base directory: base.path

See Also:
Constant Field Values

PROPERTY_INCLUDE_CODE_DESCRIPTIONS

public static final java.lang.String PROPERTY_INCLUDE_CODE_DESCRIPTIONS
Property identifier for indicating that the code information should or should not inculde the code's description information.

See Also:
Constant Field Values

ICD_9_DIAGNOSIS_CODE_TABLENAME

public static java.lang.String ICD_9_DIAGNOSIS_CODE_TABLENAME
Diagnosis Code table name: diagnosisCodes.txt


NRS_ICD_9_DIAGNOSIS_CODE_TABLENAME

public static java.lang.String NRS_ICD_9_DIAGNOSIS_CODE_TABLENAME
NRS Diagnosis Code table name: nrsDiagnosisCodes.txt


DIAGNOSTIC_CATEGORY_TABLENAME

public static java.lang.String DIAGNOSTIC_CATEGORY_TABLENAME
Diagnostic Category table name: diagnosticCategory.txt


NRS_DIAGNOSTIC_CATEGORY_TABLENAME

public static java.lang.String NRS_DIAGNOSTIC_CATEGORY_TABLENAME
NRS Diagnostic Category table name: NRSDiagnosticCategory.txt


SCORING_CASEMIX_ADJUSTMENT_TABLENAME

public static java.lang.String SCORING_CASEMIX_ADJUSTMENT_TABLENAME
Scoring Case Mix Adjustment table name: Scoring_CasemixAdjustments.txt


NRSSCORING_CASEMIX_ADJUSTMENT_TABLENAME

public static java.lang.String NRSSCORING_CASEMIX_ADJUSTMENT_TABLENAME
NRS Scoring Case Mix Adjustment table name: NRSScoring_CasemixAdjustments.txt


DIAGNOSIS_ETIOLOGY_PAIRS

public static java.lang.String DIAGNOSIS_ETIOLOGY_PAIRS
Diagnosis code Secondary / Etiology pairs table name: DiagnosisEtiologyPairs.txt


OPTIONAL_VCODES_TABLENAME

public static java.lang.String OPTIONAL_VCODES_TABLENAME
Optional V-Code table name: OptionalVCodes.txt

Constructor Detail

GrouperDataManager_v2308

public GrouperDataManager_v2308()
Method Detail

getBasePath

public java.io.File getBasePath()
Get the value of basePath which is the folder location of the data files

Returns:
the value of basePath

setBasePath

public void setBasePath(java.io.File basePath)
Set the value of basePath which is the folder location of the data files

Parameters:
basePath - new value of basePath

getNRSDiagnosisCode

public Icd9DiagnosisCodeIF getNRSDiagnosisCode(java.lang.String value)
This is a proxy to getDiagnosisCodeBase

Parameters:
value -
Returns:
NRS Diagnosis code or null if not a valid code
See Also:
getDiagnosisCodeBase(Hashtable codes, String value)

loadNRSDiagnosisCodes

protected void loadNRSDiagnosisCodes()
                              throws java.io.FileNotFoundException,
                                     java.io.IOException
Loads Non-Routine Supplies related Diagnosis codes. This uses the loadDiagnosisCodeBase() to read the file.

Throws:
java.io.FileNotFoundException
java.io.IOException
See Also:
throws IOException

getDiagnosisCode

public Icd9DiagnosisCodeIF getDiagnosisCode(java.lang.String value)
This is a proxy to getDiagnosisCodeBase

Parameters:
value -
Returns:
Diagnosis code or null if not a valid code
See Also:
getDiagnosisCodeBase(Hashtable codes, String value)

getDiagnosisCodeBase

protected Icd9DiagnosisCodeIF getDiagnosisCodeBase(java.util.Hashtable<java.lang.String,Icd9DiagnosisCodeIF> codes,
                                                   java.lang.String value)
Searchs the supplied diagnosis code table, codes, for the code value. If found, then the code is cloned to allow the calling module to change its attributes without effecting the original code, which remains in the same state as when it was loaded.

Parameters:
codes -
value -
Returns:
the cloned() code or null if the the value is not valid code value

loadDiagnosisCodes

protected void loadDiagnosisCodes()
                           throws java.io.FileNotFoundException,
                                  java.io.IOException
This will add the Diagnosis Codes associated with this version. By default it will set the ValidCode and ValidForScoring indicators to true. This uses the loadDiagnosisCodeBase() to read the file.

Throws:
java.io.FileNotFoundException
java.io.IOException
See Also:
throws IOException

loadDiagnosisCodeBase

protected void loadDiagnosisCodeBase(java.io.File file,
                                     java.util.Hashtable<java.lang.String,Icd9DiagnosisCodeIF> codeHash)
                              throws java.io.IOException
This is a consolidated/generic Diagnosis code loaded that requires the input file, and the hashtable to put the codes into The data is loaded from a tab separated file with the format:

Parameters:
file -
codeHash -
Throws:
java.io.IOException

getDiagnosticGroup

public DiagnosticCategoryIF getDiagnosticGroup(long id)
Searches for the Diagnostic Group object based on its ID

Parameters:
id -
Returns:
DiagnosticCategoryIF or null if the ID is not valid

loadDiagnosticGroups

protected void loadDiagnosticGroups()
                             throws java.io.FileNotFoundException,
                                    java.io.IOException
Loads the Diagnostic Group information from a text file The data is loaded from a tab separated file with the format:

Throws:
java.io.FileNotFoundException
java.io.IOException

getNRSDiagnosticGroup

public DiagnosticCategoryIF getNRSDiagnosticGroup(long id)
Searches for the Non-Routine Supplies Diagnostic Category/Group based on the ID

Parameters:
id -
Returns:
DiagnosticCategory or null if the id is not found

loadNRSDiagnosticGroups

protected void loadNRSDiagnosticGroups()
                                throws java.io.FileNotFoundException,
                                       java.io.IOException
This loads the Non-Routine Supplies Diagnostic Categories using the loadDiagnosticCategoriesBase()

Throws:
java.io.FileNotFoundException
java.io.IOException
See Also:
throws FileNotFoundException, IOException

loadDiagnosticCategoriesBase

protected void loadDiagnosticCategoriesBase(java.io.File file,
                                            java.util.Hashtable<java.lang.Integer,DiagnosticCategoryIF> categoryHash)
                                     throws java.io.FileNotFoundException,
                                            java.io.IOException
Loads the Diagnostic Group information from a text file. The data is loaded from a tab separated file with the format:

Parameters:
file -
categoryHash -
Throws:
java.io.FileNotFoundException
java.io.IOException

init

public void init(java.util.Properties props)
          throws java.lang.Exception,
                 java.rmi.RemoteException
This loads all the data required to represent a version of the Home Health Grouper.

Specified by:
init in interface Initializable
Parameters:
props -
Throws:
java.lang.Exception
java.rmi.RemoteException

loadCaseMixAdjustments

public void loadCaseMixAdjustments()
                            throws java.io.FileNotFoundException,
                                   java.io.IOException
Loads the Case mix adjustment values for the Clinical scoring The data is loaded from a tab separated file with the format:

Throws:
java.io.FileNotFoundException
java.io.IOException

getCaseMixAdjustment

public CaseMixAdjustmentItemIF getCaseMixAdjustment(int caseMixId)
This will search the case mix table for the case mix id, and return the case mix admjustment item

Parameters:
caseMixId -
Returns:
Case mix adjustment item if found. null if not found

loadNRSCaseMixAdjustments

public void loadNRSCaseMixAdjustments()
                               throws java.io.FileNotFoundException,
                                      java.io.IOException
Loads the Case mix adjustment values for the Non-Routine Supplies scoring. The data is loaded from a tab separated file with the format:

Throws:
java.io.FileNotFoundException
java.io.IOException

getNRSCaseMixAdjustment

public CaseMixAdjustmentItemIF getNRSCaseMixAdjustment(int caseMixId)
This will search the case mix table for the case mix id, and return the case mix admjustment item

Parameters:
caseMixId -
Returns:
Case mix adjustment item if found. null if not found

loadEtiologyPairs

public void loadEtiologyPairs()
                       throws java.io.FileNotFoundException,
                              java.io.IOException
IMPORTANT: This requires that the diagnosis codes are loaded first. This loads the Etiology Pairs and associates the with the appropriate diagnosis code. The data is loaded from a tab separated file with the format:

Throws:
java.io.FileNotFoundException
java.io.IOException

loadOptionalVCodes

public void loadOptionalVCodes()
                        throws java.io.FileNotFoundException,
                               java.io.IOException
IMPORTANT: This requires that the diagnosis codes are loaded first.

Throws:
java.io.FileNotFoundException
java.io.IOException