Qt 4.8
Public Functions | List of all members
QPatternist::BinaryDataComparator Class Reference

Compares xs:base64Binary and xs:hexBinary values. More...

#include <qatomiccomparators_p.h>

Inheritance diagram for QPatternist::BinaryDataComparator:
QPatternist::AtomicComparator QPatternist::AtomicTypeVisitorResult QSharedData

Public Functions

virtual bool equals (const Item &op1, const Item &op2) const
 
- Public Functions inherited from QPatternist::AtomicComparator
 AtomicComparator ()
 
virtual ComparisonResult compare (const Item &op1, const AtomicComparator::Operator op, const Item &op2) const
 
virtual ~AtomicComparator ()
 
- Public Functions inherited from QPatternist::AtomicTypeVisitorResult
 AtomicTypeVisitorResult ()
 
virtual ~AtomicTypeVisitorResult ()
 
- Public Functions inherited from QSharedData
 QSharedData ()
 Constructs a QSharedData object with a reference count of 0. More...
 
 QSharedData (const QSharedData &)
 Constructs a QSharedData object with reference count 0. More...
 

Additional Inherited Members

- Public Types inherited from QPatternist::AtomicComparator
enum  ComparisonResult { LessThan = 1, Equal = 2, GreaterThan = 4, Incomparable = 8 }
 
enum  ComparisonType { AsGeneralComparison = 1, AsValueComparison }
 
enum  Operator {
  OperatorEqual = 1, OperatorNotEqual = 1 << 1, OperatorGreaterThan = 1 << 2, OperatorLessThan = 1 << 3,
  OperatorLessThanNaNLeast = 1 << 4, OperatorLessThanNaNGreatest = 1 << 5, OperatorGreaterOrEqual = OperatorEqual | OperatorGreaterThan, OperatorLessOrEqual = OperatorEqual | OperatorLessThan
}
 
typedef QFlags< OperatorOperators
 
typedef QExplicitlySharedDataPointer< AtomicComparatorPtr
 
- Public Types inherited from QPatternist::AtomicTypeVisitorResult
typedef QExplicitlySharedDataPointer< AtomicTypeVisitorResultPtr
 
- Static Public Functions inherited from QPatternist::AtomicComparator
static QString displayName (const AtomicComparator::Operator op, const ComparisonType type)
 
- Public Variables inherited from QSharedData
QAtomicInt ref
 

Detailed Description

Compares xs:base64Binary and xs:hexBinary values.

Author
Frans Englich frans.nosp@m..eng.nosp@m.lich@.nosp@m.noki.nosp@m.a.com

Definition at line 134 of file qatomiccomparators_p.h.

Functions

◆ equals()

bool BinaryDataComparator::equals ( const Item op1,
const Item op2 
) const
virtual

Determines whether op1 and op2 are equal. It is the same as calling compare() and checking whether the return value is Equal, but since comparison testing is such a common operation, this specialized function exists.

Returns
true if op1 and op2 are equal.
Parameters
op1the first operand
op2the second operand

Implements QPatternist::AtomicComparator.

Definition at line 114 of file qatomiccomparators.cpp.

116 {
117  return o1.as<Base64Binary>()->asByteArray() ==
118  o2.as<Base64Binary>()->asByteArray();
119 }
const TCastTarget * as() const
Implements the value instance of the xs:base64Binary type.

The documentation for this class was generated from the following files: