third_party/virtualbox/src/VBox/Main/src-server/MachineImpl.cpp
/**
 *  Returns true if the settings file is located in the directory named exactly
 *  as the machine; this means, among other things, that the machine directory
 *  should be auto-renamed.
 *
 *  @param aSettingsDir if not NULL, the full machine settings file directory
 *                      name will be assigned there.
 *
 *  @note Doesn't lock anything.
 *  @note Not thread safe (must be called from this object's lock).
 */
Returns true if the settings file is located in the directory named exactly
as the machine; this means, among other things, that the machine directory
should be auto-renamed.

@param aSettingsDir if not NULL, the full machine settings file directory
name will be assigned there.

@note Doesn't lock anything.
@note Not thread safe (must be called from this object's lock).
Returns true if the settings file is located in the directory named exactly as the machine ; this means among other things that the machine directory should be auto - renamed . @param aSettingsDir if not NULL the full machine settings file directory name will be assigned there . @note Doesn ' t lock anything . @note Not thread safe ( must be called from this object ' s lock ) .
bool Machine::i_isInOwnDir(Utf8Str *aSettingsDir ) const
{
    Utf8Str strMachineDirName(mData->m_strConfigFileFull);  
    strMachineDirName.stripFilename();                      
    if (aSettingsDir)
        *aSettingsDir = strMachineDirName;
    strMachineDirName.stripPath();                          
    Utf8Str strConfigFileOnly(mData->m_strConfigFileFull);  
    strConfigFileOnly.stripPath()                           .vbox
                     .stripSuffix();                        
    if (mUserData->s.fDirectoryIncludesUUID)
        strConfigFileOnly += Utf8StrFmt(" (%RTuuid)", mData->mUuid.raw());
    AssertReturn(!strMachineDirName.isEmpty(), false);
    AssertReturn(!strConfigFileOnly.isEmpty(), false);
    return strMachineDirName == strConfigFileOnly;
}
bool Machine :: i_isInOwnDir ( Utf8Str * aSettingsDir ) const { Utf8Str strMachineDirName ( mData -> m_strConfigFileFull ) ; strMachineDirName . stripFilename ( ) ; if ( aSettingsDir ) * aSettingsDir = strMachineDirName ; strMachineDirName . stripPath ( ) ; Utf8Str strConfigFileOnly ( mData -> m_strConfigFileFull ) ; strConfigFileOnly . stripPath ( ) . stripSuffix ( ) ; if ( mUserData -> s . fDirectoryIncludesUUID ) strConfigFileOnly += Utf8StrFmt ( " " , mData -> mUuid . raw ( ) ) ; AssertReturn ( ! strMachineDirName . isEmpty ( ) , false ) ; AssertReturn ( ! strConfigFileOnly . isEmpty ( ) , false ) ; return strMachineDirName == strConfigFileOnly ; }
Returns true if the settings file is located in the directory named exactly
  as the machine; this means, among other things, that the machine directory
  should be auto-renamed.
Returns true if the settings file is located in the directory named exactly as the machine ; this means among other things that the machine directory should be auto - renamed .
/* = NULL */ // path/to/machinesfolder/vmname/vmname.vbox // path/to/machinesfolder/vmname // vmname // path/to/machinesfolder/vmname/vmname.vbox // vmname.vbox // vmname /** @todo hack, make somehow use of ComposeMachineFilename */