synchronized void loadMapper() throws SMSException {
  String fileName=mRootDir + File.separator + DIR_TREE_FILENAME;
  File fileHandle=new File(fileName);
  if (fileHandle.isFile()) {
    if (!fileHandle.canRead()) {
      String errmsg="SMSEnhancedFlatFileObject.initialize: cannot read file " + fileName;
      mDebug.error(errmsg);
      throw new SMSException(errmsg);
    }
    parseDirectoryTreeXML(fileName);
  }
 else {
    try {
      fileHandle.createNewFile();
    }
 catch (    IOException e) {
      String errmsg="SMSEnhancedFlatFileObject.initialize: " + "cannot create file, " + fileName + ". Exception "+ e.getMessage();
      mDebug.error("SMSEnhancedFlatFileObject.initialize",e);
      throw new SMSException(errmsg);
    }
catch (    SecurityException e) {
      String errmsg="SMSEnhancedFlatFileObject.initialize: " + "cannot create file, " + fileName + ". Exception "+ e.getMessage();
      mDebug.error("SMSEnhancedFlatFileObject.initialize",e);
      throw new SMSException(errmsg);
    }
    root=new SMSFlatFileTreeNode(mRootDN);
    try {
      Map map=new HashMap(2);
      Set set=new HashSet(4);
      set.add("top");
      set.add("organizationalunit");
      map.put("objectclass",set);
      create(null,"ou=services," + mRootDN,map);
      saveDirectoryTree();
    }
 catch (    SSOException e) {
    }
catch (    ServiceAlreadyExistsException e) {
      mDebug.message("SMSEnhancedFlatFileObject.initialize",e);
    }
  }
}

synchronized void loadMapper ( ) throws SMSException { String fileName = mRootDir + File . separator + DIR_TREE_FILENAME ; File fileHandle = new File ( fileName ) ; if ( fileHandle . isFile ( ) ) { if ( ! fileHandle . canRead ( ) ) { String errmsg = "SMSEnhancedFlatFileObject.initialize: cannot read file " + fileName ; mDebug . error ( errmsg ) ; throw new SMSException ( errmsg ) ; } parseDirectoryTreeXML ( fileName ) ; } else { try { fileHandle . createNewFile ( ) ; } catch ( IOException e ) { String errmsg = "SMSEnhancedFlatFileObject.initialize: " + "cannot create file, " + fileName + ". Exception " + e . getMessage ( ) ; mDebug . error ( "SMSEnhancedFlatFileObject.initialize" , e ) ; throw new SMSException ( errmsg ) ; } catch ( SecurityException e ) { String errmsg = "SMSEnhancedFlatFileObject.initialize: " + "cannot create file, " + fileName + ". Exception " + e . getMessage ( ) ; mDebug . error ( "SMSEnhancedFlatFileObject.initialize" , e ) ; throw new SMSException ( errmsg ) ; } root = new SMSFlatFileTreeNode ( mRootDN ) ; try { Map map = new HashMap ( 2 ) ; Set set = new HashSet ( 4 ) ; set . add ( "top" ) ; set . add ( "organizationalunit" ) ; map . put ( "objectclass" , set ) ; create ( null , "ou=services," + mRootDN , map ) ; saveDirectoryTree ( ) ; } catch ( SSOException e ) { } catch ( ServiceAlreadyExistsException e ) { mDebug . message ( "SMSEnhancedFlatFileObject.initialize" , e ) ; } } }
loads the dirrectory mapper , create it if it doesn ' t exist .
