aList.append( "<=" );
aList.append( ">=" );
aList.append( "<>" );
+ aList.append( "!=" ); // same as "<>" - for C++ addicts
addOperations( aList );
ListOfTypes aTypes;
{
if( isBin )
if( op=="<" || op==">" || op=="=" ||
- op=="<=" || op==">=" || op=="<>" )
+ op=="<=" || op==">=" || op=="<>" || op=="!=" )
return 1;
else if( op=="+" || op=="-" )
return 2;
set( v1, _v1<=_v2 );
else if( op==">=" )
set( v1, _v1>=_v2 );
- else if( op=="<>" )
+ else if( op=="<>" || op=="!=" )
set( v1, _v1!=_v2 );
}
else if( ( v1.type()==QVariant::Int || v1.type()==QVariant::Double ) &&
set( v1, _v1<=_v2 );
else if( op==">=" )
set( v1, _v1>=_v2 );
- else if( op=="<>" )
+ else if( op=="<>" || op=="!=" )
set( v1, _v1!=_v2 );
}
else
aList.append( "<=" );
aList.append( ">=" );
aList.append( "<>" );
+ aList.append( "!=" ); // same as "<>" - for C++ addicts
aList.append( "length" );
aList.append( "lower" );
aList.append( "upper" );
if( op=="+" )
return 2;
else if( op=="=" || op=="<" || op==">" ||
- op=="<=" || op==">=" || op=="<>" )
+ op=="<=" || op==">=" || op=="<>" || op=="!=" )
return 1;
else
return 0;
set( v1, _v1<_v2 );
else if( op==">" )
set( v1, _v1>_v2 );
- else if( op=="<>" )
+ else if( op=="<>" || op=="!=" )
set( v1, _v1!=_v2 );
else if( op=="<=" )
set( v1, _v1<_v2 || _v1==_v2 );
aList.append( "}" );
aList.append( "=" );
aList.append( "<>" );
+ aList.append( "!=" ); // same as "<>" - for C++ addicts
aList.append( "+" );
aList.append( "-" );
aList.append( "*" );
int QtxSets::prior( const QString& op, bool isBin ) const
{
if( isBin )
- if( op=="=" || op=="<>" )
+ if( op=="=" || op=="<>" || op=="!=" )
return 1;
else if( op=="+" || op=="-" || op=="*" )
return 2;
v1 = aNewList;
}
- else if( op=="=" || op=="<>" || op=="+" || op=="-" || op=="*" )
+ else if( op=="=" || op=="<>" || op=="!=" || op=="+" || op=="-" || op=="*" )
{
ValueSet aNewList;
add( aNewList, v1.toList() );
- if( op=="=" || op=="<>" || op=="-" )
+ if( op=="=" || op=="<>" || op=="!=" || op=="-" )
{
remove( aNewList, v2.toList() );
if( op=="=" )
set( v1, aNewList.isEmpty() );
- else if( op=="<>" )
+ else if( op=="<>" || op=="!=" )
set( v1, !aNewList.isEmpty() );
else
v1 = aNewList;