Nepomuk-Core
query.cpp
Go to the documentation of this file.
98 LiteralTerm(QString::fromLatin1("^(%1)").arg( m_excludeFolders.toStringList(KUrl::AddTrailingSlash).join( "|" ) )),
105 Nepomuk2::Query::Term Nepomuk2::Query::QueryPrivate::optimizeEvenMore(const Nepomuk2::Query::Term& term) const
198 Nepomuk2::Query::Query::RequestProperty::RequestProperty( const Nepomuk2::Types::Property& property,
215 Nepomuk2::Query::Query::RequestProperty& Nepomuk2::Query::Query::RequestProperty::operator=( const RequestProperty& other )
377 QList<Nepomuk2::Query::Query::RequestProperty> Nepomuk2::Query::Query::requestProperties() const
457 termGraphPattern = term.d_ptr->toSparqlGraphPattern( QLatin1String( "?r" ), 0, QString(), &qbd );
479 QString queryBase = QString::fromLatin1( "where { %1 FILTER(REGEX(STR(?r), '^nepomuk:/res')) . }" )
496 query = QString::fromLatin1("select count(%1) as ?cnt %2 where { { select count(*) as %1 ?r %3 } }")
538 // query = QLatin1String("define input:default-graph-exclude <nepomuk-ontology-group> ") + query;
669 query.setRequestProperties( QList<RequestProperty>() << Nepomuk2::Query::Query::RequestProperty( Nepomuk2::Vocabulary::NIE::url(), true ) );
697 return i18nc( "@title UDS_DISPLAY_NAME for a KIO directory listing. %1 is the query the user entered.",
QString toSparqlQuery(SparqlFlags flags=NoFlags) const
Convert the query into a SPARQL query which can be used with the Nepomuk query service or directly in...
Definition: query.cpp:409
KUrl toSearchUrl(SparqlFlags flags=NoFlags) const
Convert the query into a URL which can be listed using KIO::DirLister.
Definition: query.cpp:544
RequestPropertyMap requestPropertyMap() const
Build a request property map as used in QueryServiceClient::sparqlQuery() from the request properties...
Definition: query.cpp:585
QueryFlags queryFlags() const
Get the query flags to configure this query.
Definition: query.cpp:359
A negation term inverts the meaning of its sub term.
Definition: term.h:127
static QString titleFromQueryUrl(const KUrl &url)
Extact the title from a nepomuksearch:/ query URL.
Definition: query.cpp:680
QString variableName() const
The variable name set in setVariableName() or an empty string if none has been set.
Definition: comparisonterm.cpp:495
QString serializeQuery(const Query &query)
Definition: queryserializer.cpp:352
static Query fromString(const QString &queryString)
Parse a Query that has been encoded as a string via toString().
Definition: query.cpp:610
void setRequestProperties(const QList< RequestProperty > &properties)
Set the properties that should be reported with each search result.
Definition: query.cpp:371
QList< RequestProperty > requestProperties() const
Definition: query.cpp:377
QDataStream & operator<<(QDataStream &, const Nepomuk2::SimpleResource &)
Definition: simpleresource.cpp:307
QList< Term > subTerms() const
The sub terms that are combined in this group.
Definition: groupterm.cpp:94
void setLimit(int)
Set the maximum number of results this query should yield.
Definition: query.cpp:317
An optional term which marks its sub term as optional.
Definition: term.h:136
ComparisonTerm toComparisonTerm() const
Interpret this term as a ComparisonTerm.
Definition: term.cpp:266
void addRequestProperty(const RequestProperty &property)
Add a property that should be reported with each search result.
Definition: query.cpp:365
QHash< QString, Nepomuk2::Types::Property > RequestPropertyMap
Convinience definition for request property mappings as used in QueryServiceClient::sparqlQuery() and...
Definition: query.h:41
static Query fromQueryUrl(const KUrl &url)
Extract a query from a nepomuksearch:/ query URL.
Definition: query.cpp:634
Query operator&&(const Query &query, const Term &term)
Logical and operator which combines term into the term of query to match both.
Definition: query.cpp:708
static QString sparqlFromQueryUrl(const KUrl &url)
Extract the SPARQL query from a nepomuksearch:/ query URL.
Definition: query.cpp:656
A Nepomuk desktop query specialized for file searches.
Definition: filequery.h:44
A term matching the value of a property.
Definition: comparisonterm.h:70
A request property can be added to a Query to retrieve additional information about the results...
Definition: query.h:287
Match resource that match at least one of the sub terms.
Definition: orterm.h:43
void setFullTextScoringEnabled(bool enabled)
Nepomuk supports scoring the results based on any full text matching used in the query (full text mat...
Definition: query.cpp:329
A property is a resource of type rdf:Property which relates a domain with a range.
Definition: libnepomukcore/types/property.h:52
Nepomuk2::Types::Property property() const
Definition: query.cpp:221
RequestProperty(const Nepomuk2::Types::Property &property, bool optional=true)
Create a new request property.
Definition: query.cpp:198
static Query parseQuery(const QString &query)
Convenience method to quickly parse a query without creating an object.
Definition: queryparser.cpp:815
Query operator||(const Query &query, const Term &term)
Logical or operator which combines term into the term of query to match either one.
Definition: query.cpp:716
bool compareHash(const QHash< Key, Value > &h1, const QHash< Key, Value > &h2)
Definition: libnepomukcore/query/util.h:39
void addSubTerm(const Term &term)
Add a sub term to the list of terms that are combined in this group.
Definition: groupterm.cpp:108
void setQueryFlags(QueryFlags flags)
Set the query flags to configure this query.
Definition: query.cpp:353
bool fullTextScoringEnabled() const
Definition: query.cpp:341
void setVariableName(const QString &name)
Set the variable name that is to be used for the variable to match to.
Definition: comparisonterm.cpp:488
Qt::SortOrder fullTextScoringSortOrder() const
Definition: query.cpp:347
Query operator!(const Query &query)
Logical negation operator which negates the meaning of a query.
Definition: query.cpp:724
bool compareQList(const QList< T > &rp1, const QList< T > &rp2)
Definition: libnepomukcore/query/util.h:27
int limit() const
The maximum number of results that this query should yield.
Definition: query.cpp:299
Match all resources that match one of the sub terms.
Definition: term.h:105
void setFullTextScoringSortOrder(Qt::SortOrder order)
Set the full text scoring sort order.
Definition: query.cpp:335
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:48:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:48:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.