C# 클래스 Opc.Ua.ServerTest.TestBase

The base class for all tests.
파일 보기 프로젝트 열기: OPCFoundation/UA-.NET 1 사용 예제들

공개 메소드들

메소드 설명
Run ( ServerTestCase testcase, int iteration ) : bool

Runs the test case.

TestBase ( string name, Session session, ServerTestConfiguration configuration, ReportMessageEventHandler reportMessage, ReportProgressEventHandler reportProgress, TestBase template ) : System

Initializes the test with session, configuration and logger.

보호된 메소드들

메소드 설명
Browse ( Node node, BrowseDescription nodeToBrowse, ReferenceDescriptionCollection references ) : bool

Browses the node and returns the references found.

CalculateInterval ( System.DateTime start, System.DateTime end ) : double

Calculates the difference between the two times in milliseconds.

CheckCoverage ( int &count ) : bool

Returns true if current node should be included in the test.

GetNodesInHierarchy ( ) : bool

Collects all of the nodes in the hierarchies specified in the configuration file.

GetWriteableVariablesInHierarchy ( ) : bool

Collects all of the nodes in the hierarchies specified in the configuration file.

LockServer ( ) : void

Locks the server.

Log ( Exception e, string format ) : void

Logs a message.

Log ( string format ) : void

Logs a message.

ReportProgress ( double position ) : void

Reports progress.

SetAttributeValue ( Node node, uint attributeId, object attributeValue ) : bool

Stores the attribute value in the object.

UnlockServer ( ) : void

Unlocks the server.

VerifyAttributeConsistency ( Node node ) : bool

Verifies that the node attributes are consistent with each other.

VerifyBadAttribute ( Node node, uint attributeId, StatusCode error ) : bool

Verifies an error returned during an attribute read.

VerifyGoodAttribute ( Node node, uint attributeId, DataValue value ) : bool

Verifies the value returned during an attribute read.

VerifyTimestamps ( Node node, uint attributeId, TimestampsToReturn timestampsToReturn, DataValue value ) : bool

Verifies that the timestamps match the requested filter.

비공개 메소드들

메소드 설명
Browse ( Node node, double start, double range ) : bool

Browses the node and verifies the results.

CollectVariables ( INode parent, List variables ) : void

Recursively collects the child variables.

CoverageToModulus ( uint coverage ) : int

Converts a percentage test converage to a modulus.

VerifyVariableBaseConsistency ( IVariableBase node ) : bool

Verifies that the variable or variable type attributes are consistent with each other.

VerifyVariableConsistency ( IVariable node ) : bool

Verifies that the variable attributes are consistent with each other.

VerifyVariableTypeConsistency ( IVariableType node ) : bool

Verifies that the variable type attributes are consistent with each other.

메소드 상세

Browse() 보호된 메소드

Browses the node and returns the references found.
protected Browse ( Node node, BrowseDescription nodeToBrowse, ReferenceDescriptionCollection references ) : bool
node Node
nodeToBrowse BrowseDescription
references ReferenceDescriptionCollection
리턴 bool

CalculateInterval() 보호된 메소드

Calculates the difference between the two times in milliseconds.
protected CalculateInterval ( System.DateTime start, System.DateTime end ) : double
start System.DateTime
end System.DateTime
리턴 double

CheckCoverage() 보호된 메소드

Returns true if current node should be included in the test.
protected CheckCoverage ( int &count ) : bool
count int
리턴 bool

GetNodesInHierarchy() 보호된 메소드

Collects all of the nodes in the hierarchies specified in the configuration file.
protected GetNodesInHierarchy ( ) : bool
리턴 bool

GetWriteableVariablesInHierarchy() 보호된 메소드

Collects all of the nodes in the hierarchies specified in the configuration file.
protected GetWriteableVariablesInHierarchy ( ) : bool
리턴 bool

LockServer() 보호된 메소드

Locks the server.
protected LockServer ( ) : void
리턴 void

Log() 보호된 메소드

Logs a message.
protected Log ( Exception e, string format ) : void
e System.Exception
format string
리턴 void

Log() 보호된 메소드

Logs a message.
protected Log ( string format ) : void
format string
리턴 void

ReportProgress() 보호된 메소드

Reports progress.
protected ReportProgress ( double position ) : void
position double
리턴 void

Run() 공개 메소드

Runs the test case.
public Run ( ServerTestCase testcase, int iteration ) : bool
testcase ServerTestCase
iteration int
리턴 bool

SetAttributeValue() 보호된 메소드

Stores the attribute value in the object.
protected SetAttributeValue ( Node node, uint attributeId, object attributeValue ) : bool
node Node
attributeId uint
attributeValue object
리턴 bool

TestBase() 공개 메소드

Initializes the test with session, configuration and logger.
public TestBase ( string name, Session session, ServerTestConfiguration configuration, ReportMessageEventHandler reportMessage, ReportProgressEventHandler reportProgress, TestBase template ) : System
name string
session Opc.Ua.Client.Session
configuration ServerTestConfiguration
reportMessage ReportMessageEventHandler
reportProgress ReportProgressEventHandler
template TestBase
리턴 System

UnlockServer() 보호된 메소드

Unlocks the server.
protected UnlockServer ( ) : void
리턴 void

VerifyAttributeConsistency() 보호된 메소드

Verifies that the node attributes are consistent with each other.
protected VerifyAttributeConsistency ( Node node ) : bool
node Node
리턴 bool

VerifyBadAttribute() 보호된 메소드

Verifies an error returned during an attribute read.
protected VerifyBadAttribute ( Node node, uint attributeId, StatusCode error ) : bool
node Node
attributeId uint
error StatusCode
리턴 bool

VerifyGoodAttribute() 보호된 메소드

Verifies the value returned during an attribute read.
protected VerifyGoodAttribute ( Node node, uint attributeId, DataValue value ) : bool
node Node
attributeId uint
value DataValue
리턴 bool

VerifyTimestamps() 보호된 메소드

Verifies that the timestamps match the requested filter.
protected VerifyTimestamps ( Node node, uint attributeId, TimestampsToReturn timestampsToReturn, DataValue value ) : bool
node Node
attributeId uint
timestampsToReturn TimestampsToReturn
value DataValue
리턴 bool