VirtualBox

Changeset 84857 in vbox for trunk


Ignore:
Timestamp:
Jun 17, 2020 7:46:06 AM (5 years ago)
Author:
vboxsync
Message:

Guest Control/Main: Added another GuestBase::getErrorAsString() convenience function. bugref:9320

Location:
trunk/src/VBox/Main
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/include/GuestCtrlImplPrivate.h

    r84844 r84857  
    12851285
    12861286    static FsObjType_T fileModeToFsObjType(RTFMODE fMode);
     1287    static Utf8Str getErrorAsString(const Utf8Str &strAction, const GuestErrorInfo& guestErrorInfo);
    12871288    static Utf8Str getErrorAsString(const GuestErrorInfo &guestErrorInfo);
    12881289
  • trunk/src/VBox/Main/src-client/GuestCtrlPrivate.cpp

    r84843 r84857  
    13131313#ifndef VBOX_GUESTCTRL_TEST_CASE
    13141314/**
     1315 * Convenience function to return a pre-formatted string using an action description and a guest error information.
     1316 *
     1317 * @returns Pre-formatted string with a user-friendly error string.
     1318 * @param   strAction           Action of when the error occurred.
     1319 * @param   guestErrorInfo      Related guest error information to use.
     1320 */
     1321/* static */ Utf8Str GuestBase::getErrorAsString(const Utf8Str& strAction, const GuestErrorInfo& guestErrorInfo)
     1322{
     1323    Assert(strAction.isNotEmpty());
     1324    return Utf8StrFmt("%s: %s", strAction.c_str(), getErrorAsString(guestErrorInfo).c_str());
     1325}
     1326
     1327/**
    13151328 * Returns a user-friendly error message from a given GuestErrorInfo object.
    13161329 *
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette