Workspace 6.21.5
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
TextDifference Class Reference

#include <Tools/Widgets/textdifferencer.h>

Public Member Functions

 TextDifference ()
 
 TextDifference (Type action, const QString &_text)
 
bool isNull () const
 
bool operator!= (const TextDifference &d) const
 
bool operator== (const TextDifference &d) const
 
QString toString () const
 Display a human-readable version of this Diff.
 

Static Public Member Functions

static QString toString (Type action)
 

Public Attributes

QString text_
 
Type type_ {Type::Ignore}
 

Detailed Description

Class representing one diff operation.

Constructor & Destructor Documentation

◆ TextDifference() [1/2]

TextDifference ( Type  type,
const QString &  text 
)

Constructor. Initializes the TextDifference with the provided values.

Parameters
typeOne of Type::Append, Type::Remove or Type::Ignore
textThe text being applied

◆ TextDifference() [2/2]

Member Function Documentation

◆ isNull()

bool isNull ( ) const
inline

◆ operator!=()

bool operator!= ( const TextDifference d) const

◆ operator==()

bool operator== ( const TextDifference d) const

Is this TextDifference equivalent to another TextDifference?

Parameters
dAnother TextDifference to compare against
Returns
true or false

◆ toString() [1/2]

QString toString ( ) const

◆ toString() [2/2]

QString toString ( Type  action)
static

Member Data Documentation

◆ text_

QString text_

◆ type_

Type type_ {Type::Ignore}