本文整理了Java中org.xwiki.query.Query.getStatement
方法的一些代码示例,展示了Query.getStatement
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Query.getStatement
方法的具体详情如下:
包路径:org.xwiki.query.Query
类名称:Query
方法名:getStatement
暂无
代码示例来源:origin: org.xwiki.platform/xwiki-platform-query-manager
@Override
public String getStatement()
{
return this.query.getStatement();
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-query-manager
@Override
public String getMessage()
{
if (query == null) {
return super.getMessage();
} else {
if (query.isNamed()) {
return super.getMessage() + ". Named query = [" + query.getStatement() + "]";
} else {
return super.getMessage() + ". Query statement = [" + query.getStatement() + "]";
}
}
}
}
代码示例来源:origin: com.xpn.xwiki.platform/xwiki-core
/**
* @param session hibernate session
* @param query Query object
* @return hibernate query
*/
protected org.hibernate.Query createHibernateQuery(Session session, Query query)
{
return query.isNamed()
? session.getNamedQuery(query.getStatement())
: session.createQuery(query.getStatement());
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-query-manager
@Override
public String getStatement()
{
return getWrappedQuery().getStatement();
}
代码示例来源:origin: com.xpn.xwiki.platform.plugins/xwiki-plugin-activitystream
/**
* {@inheritDoc}
*
* @see EventStream#searchEvents(Query)
*/
public List<Event> searchEvents(Query query) throws QueryException
{
Query q = this.qm.createQuery("select event from ActivityEventImpl event "
+ query.getStatement(), query.getLanguage());
for (Map.Entry<String, Object> entry : query.getNamedParameters().entrySet()) {
q.bindValue(entry.getKey(), entry.getValue());
}
for (Map.Entry<Integer, Object> entry : query.getPositionalParameters().entrySet()) {
q.bindValue(entry.getKey(), entry.getValue());
}
List<ActivityEvent> events = q.execute();
return convertActivitiesToEvents(events);
}
内容来源于网络,如有侵权,请联系作者删除!