WebCab Probability and Statistics for .NET v3.3 Demo

ADOMediator.UnderlyingInstance Property

This property holds the instance of a Correlation and Regression class, used in Database computations.

public object UnderlyingInstance {get; set;}

Remarks

Initially, this property is not set, so the next step after constructing an instance of this class is setting this property to an instance of one of the classes in the Correlation and Regression namespace.

Exceptions

Exception TypeCondition
ADOMediatorExceptionThrown when trying to assign an instance of a class which is not part of the WebCab Correlation and Regression namespace.

Example

The following example creates and assigns an instance of the Correlation class to an instance of the ADO Mediator class.

               // Create a new instance of this class.
               Correlation instance = new Correlation ();
               ...
               // Create an instance of the ADO Mediator class
               // (parameters omitted)
               ADOMediator ado = new ADOMediator (...);
               ...
               // Assign the Correlation instance to the ADO Mediator
               ado.UnderlyingInstance = instance;
            
After the assignment has taken place, the ADOMediator will direct all method calls to the Correlation instance. For example, if you wish to invoke a method belonging to the Correlation class, with values taken from the database, using a SELECT statement, you would write something similar to:
               double result = ado.OneSelect ("NameOfMethodInCorrelationClass",
                    "SELECT DATE, OPEN, CLOSE FROM IBM");
            
The ado instance of the ADOMediator class will call the NameOfMethodInCorrelationClass method on the instance returned by this property.

See Also

ADOMediator Class | WebCab.Libraries.Statistics.Correlation.ADO Namespace