VirtualBox

Changeset 73964 in vbox


Ignore:
Timestamp:
Aug 29, 2018 4:41:26 PM (7 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
124695
Message:

IPRT/rest: Missing copy stuff in array template; DLL linking. bugref:9167

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/cpp/restbase.h

    r73958 r73964  
    4848 * Abstract base class for serializing data objects.
    4949 */
    50 class RTCRestOutputBase
     50class RT_DECL_CLASS RTCRestOutputBase
    5151{
    5252public:
     
    116116 * Serialize to a string object.
    117117 */
    118 class RTCRestOutputToString : public RTCRestOutputBase
     118class RT_DECL_CLASS RTCRestOutputToString : public RTCRestOutputBase
    119119{
    120120public:
     
    167167 * input and also helps constructing full object name for logging and error reporting.
    168168 */
    169 struct RTCRestJsonCursor
     169struct RT_DECL_CLASS RTCRestJsonCursor
    170170{
    171171    /** Handle to the value being parsed. */
     
    204204 * The primary JSON cursor class.
    205205 */
    206 class RTCRestJsonPrimaryCursor
     206class RT_DECL_CLASS RTCRestJsonPrimaryCursor
    207207{
    208208public:
     
    257257 * Abstract base class for REST data objects.
    258258 */
    259 class RTCRestObjectBase
     259class RT_DECL_CLASS RTCRestObjectBase
    260260{
    261261public:
     
    357357 * Class wrapping 'bool'.
    358358 */
    359 class RTCRestBool : public RTCRestObjectBase
     359class RT_DECL_CLASS RTCRestBool : public RTCRestObjectBase
    360360{
    361361public:
     
    392392 * Class wrapping 'int64_t'.
    393393 */
    394 class RTCRestInt64 : public RTCRestObjectBase
     394class RT_DECL_CLASS RTCRestInt64 : public RTCRestObjectBase
    395395{
    396396public:
     
    427427 * Class wrapping 'int32_t'.
    428428 */
    429 class RTCRestInt32 : public RTCRestObjectBase
     429class RT_DECL_CLASS RTCRestInt32 : public RTCRestObjectBase
    430430{
    431431public:
     
    462462 * Class wrapping 'int16_t'.
    463463 */
    464 class RTCRestInt16 : public RTCRestObjectBase
     464class RT_DECL_CLASS RTCRestInt16 : public RTCRestObjectBase
    465465{
    466466public:
     
    497497 * Class wrapping 'double'.
    498498 */
    499 class RTCRestDouble : public RTCRestObjectBase
     499class RT_DECL_CLASS RTCRestDouble : public RTCRestObjectBase
    500500{
    501501public:
     
    532532 * Class wrapping 'RTCString'.
    533533 */
    534 class RTCRestString : public RTCString, public RTCRestObjectBase
     534class RT_DECL_CLASS RTCRestString : public RTCString, public RTCRestObjectBase
    535535{
    536536public:
     
    563563 * Abstract base class for the RTCRestArray template.
    564564 */
    565 class RTCRestArrayBase : public RTCRestObjectBase
     565class RT_DECL_CLASS RTCRestArrayBase : public RTCRestObjectBase
    566566{
    567567public:
    568568    /** Default destructor. */
    569569    RTCRestArrayBase();
    570     /** Copy constructor. */
    571     RTCRestArrayBase(RTCRestArrayBase const &a_rThat);
    572570    /** Destructor. */
    573571    virtual ~RTCRestArrayBase();
    574     /** Copy assignment operator. */
    575     RTCRestArrayBase &operator=(RTCRestArrayBase const &a_rThat);
    576572
    577573    /* Overridden methods: */
     
    680676     */
    681677    int insertCopyWorker(size_t a_idx, RTCRestObjectBase const &a_rValue, bool a_fReplace);
     678
     679private:
     680    /** Copy constructor on this class should never be used. */
     681    RTCRestArrayBase(RTCRestArrayBase const &a_rThat);
     682    /** Copy assignment operator on this class should never be used. */
     683    RTCRestArrayBase &operator=(RTCRestArrayBase const &a_rThat);
    682684};
    683685
     
    690692{
    691693public:
     694    /** Default constructor - empty array. */
    692695    RTCRestArray()
    693696        : RTCRestArrayBase()
    694697    {
    695698    }
     699
     700    /** Destructor. */
    696701    ~RTCRestArray()
    697702    {
     703    }
     704
     705    /** Copy constructor. */
     706    RTCRestArray(RTCRestArray const &a_rThat)
     707        : RTCRestArrayBase()
     708    {
     709        copyArrayWorker(a_rThat, true /*fThrow*/);
     710    }
     711
     712    /** Copy assignment operator. */
     713    RTCRestArray &operator=(RTCRestArray const &a_rThat)
     714    {
     715        copyArrayWorker(a_rThat, true /*fThrow*/);
     716        return *this;
    698717    }
    699718
     
    895914 * Abstract base class for the RTCRestStringMap template.
    896915 */
    897 class RTCRestStringMapBase : public RTCRestObjectBase
     916class RT_DECL_CLASS RTCRestStringMapBase : public RTCRestObjectBase
    898917{
    899918public:
     
    12161235 *       could be a specialized map implementation.
    12171236 */
    1218 class RTCRestObject : public RTCRestObjectBase
     1237class /*RT_DECL_CLASS*/ RTCRestObject : public RTCRestObjectBase
    12191238{
    12201239public:
     
    12481267 * Base class for REST client requests.
    12491268 */
    1250 class RTCRestClientRequestBase
     1269class RT_DECL_CLASS RTCRestClientRequestBase
    12511270{
    12521271public:
     
    13061325 * Base class for REST client responses.
    13071326 */
    1308 class RTCRestClientResponseBase
     1327class RT_DECL_CLASS RTCRestClientResponseBase
    13091328{
    13101329public:
     
    14941513 * Base class for REST client responses.
    14951514 */
    1496 class RTCRestClientApiBase
     1515class RT_DECL_CLASS RTCRestClientApiBase
    14971516{
    14981517public:
Note: See TracChangeset for help on using the changeset viewer.

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