QuickOPC User's Guide and Reference
Simultaneous Operations
Fundamentals > Simultaneous Operations

OPC (Cleint-Server model) works with potentially large quantities of relatively small data items that may change rapidly in time. In order to handle this kind of load effectively, it is necessary to operate on larger “chunks” of data whenever possible. When there is an operation to be performed on multiple elements, the elements should be passed to the operation together, and the results obtained together as well.

In order to ensure high efficiency, your code should allow the same. This is achieved by calling methods that are designed to work on multiple items in parallel. Where it makes sense, QuickOPC provides such methods, and they contain the work Multiple in their names. For example, for reading a value of an OPC item, a method named ReadItemValue exists on the EasyDAClient object (or, ReadValue method on the EasyUAClient object). There is also a corresponding method named ReadMultipleItemValues on the EasyDAClient object (or, ReadMultipleValues on the EasyUAClient object) which can read multiple OPC items at once. It is strongly recommended that you call the methods that are designed for simultaneous operation wherever possible.

Methods for simultaneous operation return an array of OperationResult objects, or its derivatives. Each element in the output array corresponds to an element in the input array with the same index. Some methods or method overloads take multiple arguments, where some arguments are common for all elements, and one of them is the input array that has parts that are different for each element. There is always one method overload that takes a single argument which is an array of OperationArguments objects; this is the most generic method overload that allows each element be fully different from other elements.

See Also