Open SiteSearch 4.1.1
Final

ORG.oclc.HoldingServer
Class InstData

java.lang.Object
  |
  +--ORG.oclc.HoldingServer.InstData

public class InstData
extends Object


Field Summary
static int COUNTRY_CODE_LEN
          The length of the country code
static int GROUP_SYM_LEN
          The length of group symbol
static int INST_SYM_LEN
          The length of institution symbol, will be expended to 8 with the institution code expansion project
static String INSTDATA_SECTION
           
static long NumGroups
          Total number of groups
static long NumInsts
          Total number of institutions
static int STATE_CODE_LEN
          The length of the state code
 
Constructor Summary
InstData()
           
 
Method Summary
static void dumpGroupInfo()
          Dumps all the group info
static void dumpInstIndex()
          Dumps all the institution index info
static void dumpInstInfo()
          Dumps all the institution info object
static void dumpRegionInfo()
          Dumps all the region info
static GroupInfo getGroupInfo(String groupSym)
          Get GroupInfo by group symbol
static InstInfo getInstInfo(long instNum)
          Get InstInfo by institution number
static InstInfo getInstInfo(String instSym)
          Get InstInfo by institution symbol
static long getInstNum(String instSym)
          Get institution number by institution symbol
static String getInstSym(long instNum)
          Get institution symbol by institution number
static String getRegion(String region)
          Get region from region hashtable
static boolean initInstData(IniFile iniFile, String instDataSection)
          InitInstData get InstData file names from ini file Generate Hashtables for InstInfo, GroupInfo and RegionInfo for later access.
static void logInit()
          Initialize InstDataLog for tracing purposes
static void logInit(PrintStream log)
          Initialize InstDataLog for tracing purposes
static void logInit(String logFile)
          Initialize InstDataLog for tracing purposes
static void main(String[] args)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INSTDATA_SECTION

public static final String INSTDATA_SECTION

INST_SYM_LEN

public static final int INST_SYM_LEN
The length of institution symbol, will be expended to 8 with the institution code expansion project

GROUP_SYM_LEN

public static final int GROUP_SYM_LEN
The length of group symbol

STATE_CODE_LEN

public static final int STATE_CODE_LEN
The length of the state code

COUNTRY_CODE_LEN

public static final int COUNTRY_CODE_LEN
The length of the country code

NumInsts

public static long NumInsts
Total number of institutions

NumGroups

public static long NumGroups
Total number of groups
Constructor Detail

InstData

public InstData()
Method Detail

initInstData

public static boolean initInstData(IniFile iniFile,
                                   String instDataSection)
                            throws FileNotFoundException,
                                   IOException,
                                   EOFException,
                                   NullPointerException
InitInstData get InstData file names from ini file Generate Hashtables for InstInfo, GroupInfo and RegionInfo for later access.
Parameters:
iniFile - instdata ini file
instDataSection - instdata section name
Returns:
a boolean value. true: successful, false: failed.

getInstSym

public static String getInstSym(long instNum)
Get institution symbol by institution number
Parameters:
instNum - institution number
Returns:
institution symbol

getInstNum

public static long getInstNum(String instSym)
Get institution number by institution symbol
Parameters:
instSym - institution symbol
Returns:
institution number

getInstInfo

public static InstInfo getInstInfo(long instNum)
Get InstInfo by institution number
Parameters:
instNum - institution number
Returns:
InstInfo object.

getInstInfo

public static InstInfo getInstInfo(String instSym)
Get InstInfo by institution symbol
Parameters:
instSym - institution symbol
Returns:
InstInfo object.

getGroupInfo

public static GroupInfo getGroupInfo(String groupSym)
Get GroupInfo by group symbol
Parameters:
groupSym - group symbol
Returns:
GroupInfo object.

getRegion

public static String getRegion(String region)
Get region from region hashtable
Parameters:
region - region code
Returns:
a string contains states code within the region

dumpInstInfo

public static void dumpInstInfo()
Dumps all the institution info object

dumpInstIndex

public static void dumpInstIndex()
Dumps all the institution index info

dumpGroupInfo

public static void dumpGroupInfo()
Dumps all the group info

dumpRegionInfo

public static void dumpRegionInfo()
Dumps all the region info

logInit

public static void logInit()
Initialize InstDataLog for tracing purposes

logInit

public static void logInit(String logFile)
Initialize InstDataLog for tracing purposes
Parameters:
logFile - tracelog file name

logInit

public static void logInit(PrintStream log)
Initialize InstDataLog for tracing purposes
Parameters:
log - PrintStream name

main

public static void main(String[] args)
                 throws IOException

Open SiteSearch 4.1.1
Final