Rhino C++ API
8.13
|
#include <RhRdkDataSource.h>
Public Member Functions | |
virtual void | AddDataSource (class IRhinoUiDataSource &ds)=0 |
virtual void | Commit (const UUID &uuidData, IRhinoUiEventInfo *pInfo=nullptr)=0 |
virtual void | CopyDataSourcesFrom (IRhinoUiDataSourceHost &host)=0 |
virtual void | Discard (const UUID &uuidData)=0 |
virtual void * | GetData (const UUID &uuidData, bool bForWrite, bool bAutoChangeBracket=true) const =0 |
virtual void | GetDataSources (ON_SimpleArray< IRhinoUiDataSource * > &aOut) const =0 |
virtual void | RemoveDataSource (IRhinoUiDataSource &ds)=0 |
Public Member Functions inherited from IRhinoUiDataSourceEventWatcher | |
virtual void | Delete (void)=0 |
virtual void * | EVF (const wchar_t *wszFunc, void *pvData)=0 |
virtual void | OnEvent (const UUID &uuidData, const IRhinoUiEventInfo *pInfo)=0 |
Additional Inherited Members | |
Protected Member Functions inherited from IRhinoUiDataSourceEventWatcher | |
virtual | ~IRhinoUiDataSourceEventWatcher () |
A data source host is an object, usually a controller, that hosts one or more data sources. These data sources allow the host to get or set data that is stored somewhere, often in a document. All data source hosts are automatically also data source event watchers which means they can be notified when the data changes. A data source host can host any number of data sources, each one capable of providing different data types. Note that the host does not own the data sources, it simply stores references to them.
|
pure virtual |
Add a data source to the host. The implementation of this method typically also registers the host as a data source event watcher.
|
pure virtual |
Commit changes made using GetData() with bForWrite=true.
uuidData | is the identifier of the data. |
pInfo | is a pointer to optional info to be sent with any event that is raised. Events will be sent for any data objects that have had data committed. Every call to GetData() with bForWrite=true must be matched by a call to either Commit() or Discard(). This method should not be called if the operation is cancelled. Instead you should call Discard(). |
|
pure virtual |
Copy the data sources from another host. The implementation of this method typically also registers this host as a data source event watcher.
|
pure virtual |
Discard changes made using GetData() with bForWrite=true.
|
pure virtual |
Get data, specified by a unique id, from one of the host's data source(s). Each data source will be asked to provide the data until either one provides it or there are no more data sources to ask.
uuidData | is the identifier of the data. |
bForWrite | is true if the data source is going to be written to. Every call to GetData() with bForWrite=true must be matched by a call to either Commit() or Discard(). |
bAutoChangeBracket | is true if a content change bracket should be applied. |
|
pure virtual |
Get the data sources that are being hosted.
|
pure virtual |
Removes a data source from the host. This is called when a data source is being deleted. The implementation of this method typically also unregisters the host as a data source event watcher.