API:IDataSource
From Wiketomica
| API Home | Participants | API | Discussion | Demos | Downloads | Documentation | Contact Us | Acknowledgements |
Reason For Existence
One common simulation task is to take some sort of numerical data. The IDataSource interface would allow different codebases to use each other's data taking capabilities.
Proposed Interface
The IDataSource returns its IData object on request, as well as the IDataInfo description of the IData.
IDataSource {
/**
* Returns the data given by this source
*/
IData getData();
/**
* Returns the DataInfo instance that corresponds to the IData
* given by this IDataSource. This information is useful for
* setting up the data stream and for providing annotation when
* displaying or writing the IData.
*/
readonly attribute IDataInfo dataInfo;
}
Use
We expect IDataSources to often be used as the head of a data stream. The data is pulled from the IDataSource by some object (a DataPump in Etomica) and pushed to an IDataSink, which might process the data and/or push it on down the stream.
