42 #include <QStringList> 67 input = arg.stringValue();
83 input = arg.stringValue();
94 return QtXmlPatterns::tr(
"%1 must be followed by %2 or %3, not at " 95 "the end of the replacement string.")
109 const int len = input.length();
111 for(
int i = 0; i < len; ++i)
113 const QChar ch(input.at(i));
128 const QChar nextCh(input.at(i));
130 retval.append(nextCh);
133 context->
error(QtXmlPatterns::tr(
"In the replacement string, %1 must be " 134 "followed by at least one digit when not escaped.")
151 const QChar nextCh(input.at(i));
159 context->
error(QtXmlPatterns::tr(
"In the replacement string, %1 can only be used to " 160 "escape itself or %2, not %3")
218 const QString input(arg.stringValue());
225 return makeItemMappingIterator<Item>(
ConstPtr(
this),
QBool contains(QChar c, Qt::CaseSensitivity cs=Qt::CaseSensitive) const
Expression::List m_operands
virtual Item evaluateSingleton(const DynamicContext::Ptr &context) const
#define QT_END_NAMESPACE
This macro expands to.
The QRegExp class provides pattern matching using regular expressions.
QString formatKeyword(const QString &keyword)
QExplicitlySharedDataPointer< const TokenizeFN > ConstPtr
QString & replace(int i, int len, QChar after)
static QString errorAtEnd(const char ch)
Centralizes the translation string.
QAbstractXmlForwardIterator< T >::Ptr makeListIterator(const QList< T > &list)
The QString class provides a Unicode character string.
static const EmptyIterator< Item >::Ptr emptyIterator
virtual Item evaluateSingleton(const DynamicContext::Ptr &context) const
The QChar class provides a 16-bit Unicode character.
static AtomicString::Ptr fromValue(const QString &value)
void reserve(int size)
Attempts to allocate memory for at least size characters.
QString m_replacementString
#define QT_BEGIN_NAMESPACE
This macro expands to.
void error(const QString &message, const ReportContext::ErrorCode errorCode, const QSourceLocation &sourceLocation)
const T & at(int i) const
Returns the item at index position i in the list.
The QStringList class provides a list of strings.
The namespace for the internal API of QtXmlPatterns.
QString stringValue() const
Returns the string value of this Item.
Contains classes implementing the functions found in XQuery 1.0 and XPath 2.0 Functions and Operators...
static Boolean::Ptr fromValue(const bool value)
Item mapToItem(const QString &subject, const DynamicContext::Ptr &) const
T & first()
Returns a reference to the first item in the list.
bool isNull() const
Returns true if this string is null; otherwise returns false.
static bool qIsForwardIteratorEnd(const QString &item)
QString arg(qlonglong a, int fieldwidth=0, int base=10, const QChar &fillChar=QLatin1Char(' ')) const Q_REQUIRED_RESULT
Contains functions used for formatting arguments, such as keywords and paths, in translated strings...
Represents an item in the XPath 2.0 Data Model.
int captureCount() const
Returns the number of captures contained in the regular expression.
virtual QExplicitlySharedDataPointer< DynamicContext > dynamicContext() const =0
QExplicitlySharedDataPointer< DynamicContext > Ptr
QString parseReplacement(const int captureCount, const DynamicContext::Ptr &context) const
virtual Item::Iterator::Ptr evaluateSequence(const DynamicContext::Ptr &context) const
bool is(const ID id) const
The QLatin1Char class provides an 8-bit ASCII/Latin-1 character.
virtual Item evaluateSingleton(const DynamicContext::Ptr &context) const
virtual Expression::Ptr compress(const StaticContext::Ptr &context)