VirtualBox

Changeset 74093 in vbox for trunk/include/iprt/cpp


Ignore:
Timestamp:
Sep 5, 2018 7:30:01 PM (6 years ago)
Author:
vboxsync
Message:

IPRT/rest: Implemented the hybrid RTCRestAnyObject chameleon. bugref:9167

Location:
trunk/include/iprt/cpp
Files:
1 added
1 edited

Legend:

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

    r74075 r74093  
    877877};
    878878
    879 
    880 /**
    881  * Dynamic REST object.
    882  *
    883  * @todo figure this one out. it's possible this is only used in maps and
    884  *       could be a specialized map implementation.
    885  */
    886 class /*RT_DECL_CLASS*/ RTCRestObject : public RTCRestObjectBase
    887 {
    888 public:
    889     /** Default constructor. */
    890     RTCRestObject();
    891     /** Destructor. */
    892     virtual ~RTCRestObject();
    893 
    894     /** Copy constructor. */
    895     RTCRestObject(RTCRestObject const &a_rThat);
    896     /** Copy assignment operator. */
    897     RTCRestObject &operator=(RTCRestObject const &a_rThat);
    898     /** Safe Safe copy assignment method. */
    899     int assignCopy(RTCRestObject const &a_rThat);
    900 
    901     /* Overridden methods: */
    902     virtual int setNull(void) RT_OVERRIDE;
    903     virtual int resetToDefault() RT_OVERRIDE;
    904     virtual RTCRestOutputBase &serializeAsJson(RTCRestOutputBase &a_rDst) const RT_OVERRIDE;
    905     virtual int deserializeFromJson(RTCRestJsonCursor const &a_rCursor) RT_OVERRIDE;
    906     virtual int toString(RTCString *a_pDst, uint32_t a_fFlags = kCollectionFormat_Unspecified) const RT_OVERRIDE;
    907     virtual int fromString(RTCString const &a_rValue, const char *a_pszName, PRTERRINFO a_pErrInfo = NULL,
    908                            uint32_t a_fFlags = kCollectionFormat_Unspecified) RT_OVERRIDE;
    909     virtual kTypeClass typeClass(void) const RT_OVERRIDE;
    910     virtual const char *typeName(void) const RT_OVERRIDE;
    911 
    912     /** Factory method. */
    913     static DECLCALLBACK(RTCRestObjectBase *) createInstance(void);
    914 
    915 protected:
    916     /** @todo figure out the value stuff here later... */
    917 };
    918 
    919 
    920879/** @} */
    921880
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