Database Verification Point Reference

prevnext

DatabaseVPComparator Class


The verification point framework calls the compare() method in this class to compare two DatabaseVPData objects. The comparison is for either case-sensitive equality or case-insensitive equality, depending on the options set in the DatabaseVP object that is driving the comparison.


Overview

public class DatabaseVPComparator
extends java.lang.Object
implements com.rational.test.vp.VerificationPointComparator
java.lang.Object
  |
  +--com.rational.test.vp.DatabaseVPComparator

Applicability

Commonly used with QualityArchitect.

This class requires QualityArchitect.


Summary

This class contains the following method:

Method Description
compare() Compares an expected data object and an actual data object, both of type VerificationPointData, and determines whether the test succeeds or fails.

Methods Inherited from Class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait


Constructor


Syntax

public DatabaseVPComparator()

DatabaseVPComparator.compare()

Compares an expected data object and an actual data object and determines whether the test succeeds or fails.


Syntax

public boolean compare(VerificationPointData vpdExpected, 
VerificationPointData vpdActual, java.lang.Object 
objOptions, java.lang.StringBuffer sFailureDescription)

Element Description
vpdExpected The expected data object.
vpdActual The actual data object.
objOptions Options that are passed from the DatabaseVP class to qualify the comparison. Options can include the following pre-defined options, plus any user-defined options. OPTION_TRIM, OPTION_EXPECT_FAILURE, COMPARE_CASESENSITIVE, and COMPARE_CASEINSENSITIVE .
sFailureDescription An output parameter that contains the differences between the expected and actual data objects in a failed verification point. The failure description is written to the log.


Return Value

A boolean value indicating whether the test passed or failed.


Comments

The expected and the actual data objects are DatabaseVPData implementations of VerificationPointData.

This method is specified by the compare() method in the interface VerificationPointComparator.

prevnext


Rational Test Script Services for Java Rational Software Corporation
Copyright (c) 2003, Rational Software Corporation http://www.rational.com
support@rational.com
info@rational.com