bool init (const ACE_TCHAR *inst) { ACE_TString tmp (inst); size_t begin = 0; size_t pos = tmp.find (',', begin); if (pos != ACE_TString::npos) path_ = tmp.substring (begin, pos - begin); else { DANCE_ERROR (DANCE_LOG_ERROR, (LM_ERROR, DLINFO ACE_TEXT ("Options::Creation::init - ") ACE_TEXT ("Creation directive missing name, base location, and replace parameters, ") ACE_TEXT ("must have form path,name,base,replace\n"))); return false; } begin = pos + 1; pos = tmp.find (',', begin); if (pos != ACE_TString::npos) name_ = tmp.substring (begin, pos - begin); else { DANCE_ERROR (DANCE_LOG_ERROR, (LM_ERROR, DLINFO ACE_TEXT ("Options::Creation::init - ") ACE_TEXT ("Creation directive mssing base location and replace parameter, ") ACE_TEXT ("must have form path,name,base,replace\n"))); return false; } begin = pos + 1; pos = tmp.find (',', begin); if (pos != ACE_TString::npos) base_location_ = tmp.substring (begin, pos - begin); else { DANCE_ERROR (DANCE_LOG_ERROR, (LM_ERROR, DLINFO ACE_TEXT ("Options::Creation::init - ") ACE_TEXT ("Creation directive mssing replace parameter, ") ACE_TEXT ("must have form path,name,base,replace\n"))); return false; } begin = pos + 1; if (tmp[begin] == '0') replace_ = false; else if (tmp[begin] == '1') replace_ = true; else { DANCE_ERROR (DANCE_LOG_ERROR, (LM_ERROR, DLINFO ACE_TEXT ("Options::Creation::init - ") ACE_TEXT ("Replace directive muse be 1 or 0.\n"))); return false; } return true; }