本文整理了Java中org.xwiki.context.ExecutionContext.getProperty()
方法的一些代码示例,展示了ExecutionContext.getProperty()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ExecutionContext.getProperty()
方法的具体详情如下:
包路径:org.xwiki.context.ExecutionContext
类名称:ExecutionContext
方法名:getProperty
暂无
代码示例来源:origin: org.xwiki.commons/xwiki-commons-observation-local
/**
* @return the events stacked in the execution context
*/
private Stack<BeginEvent> getCurrentEvents()
{
Stack<BeginEvent> events = null;
ExecutionContext context = this.execution.getContext();
if (context != null) {
events = (Stack<BeginEvent>) context.getProperty(KEY_EVENTS);
}
return events;
}
代码示例来源:origin: org.xwiki.commons/xwiki-commons-observation-local
/**
* @return the events stacked in the execution context
*/
private Stack<BeginEvent> getCurrentEvents()
{
Stack<BeginEvent> events = null;
ExecutionContext context = this.execution.getContext();
if (context != null) {
events = (Stack<BeginEvent>) context.getProperty(DefaultObservationContext.KEY_EVENTS);
}
return events;
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-extension-script
/**
* Get the error generated while performing the previously called action.
*
* @return an eventual exception or {@code null} if no exception was thrown
*/
public Exception getLastError()
{
return (Exception) this.execution.getContext().getProperty(EXTENSIONERROR_KEY);
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-component-wiki
/**
* @return the XWikiContext extracted from the execution.
*/
private XWikiContext getXWikiContext()
{
return (XWikiContext) this.execution.getContext().getProperty("xwikicontext");
}
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-component-script
/**
* Get the error generated while performing the previously called action.
*
* @return the last exception or {@code null} if no exception was thrown
* @since 6.1M2
*/
public Exception getLastError()
{
return (Exception) this.execution.getContext().getProperty(ERROR_KEY);
}
代码示例来源:origin: org.xwiki.platform/xwiki-core-observation-remote
/**
* {@inheritDoc}
*
* @see org.xwiki.observation.remote.RemoteObservationManagerContext#isRemoteState()
*/
public boolean isRemoteState()
{
ExecutionContext context = this.execution.getContext();
return context != null && context.getProperty(REMOTESTATE) == Boolean.TRUE;
}
代码示例来源:origin: org.xwiki.platform/xwiki-core-officeimporter
/**
* @return any error messages encountered.
*/
public String getLastErrorMessage()
{
Object error = execution.getContext().getProperty(OFFICE_MANAGER_ERROR);
return (error != null) ? (String) error : null;
}
代码示例来源:origin: org.phenotips/lims-integration-api
/**
* Helper method for obtaining a valid xcontext from the execution context.
*
* @return the current request context
*/
private XWikiContext getXContext()
{
return (XWikiContext) this.execution.getContext().getProperty(XWikiContext.EXECUTIONCONTEXT_KEY);
}
}
代码示例来源:origin: com.xpn.xwiki.platform/xwiki-core
/**
* Utility method for accessing XWikiContext.
*
* @return the XWikiContext.
*/
private XWikiContext getContext()
{
return (XWikiContext) this.execution.getContext().getProperty("xwikicontext");
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-rendering-wikimacro-store
/**
* Utility method for accessing XWikiContext.
*
* @return the XWikiContext.
*/
private XWikiContext getContext()
{
return (XWikiContext) this.execution.getContext().getProperty("xwikicontext");
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-rendering-wikimacro-store
/**
* @return the XWiki context
*/
private XWikiContext getContext()
{
return (XWikiContext) this.execution.getContext().getProperty("xwikicontext");
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-url-api
@Override
public String getURLFormatId()
{
// Note: There should always be a context ready
ExecutionContext ec = this.execution.getContext();
return (String) ec.getProperty(CONTEXT_KEY);
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-extension-script
/**
* Get the error generated while performing the previously called action.
*
* @return an eventual exception or {@code null} if no exception was thrown
*/
public Exception getLastError()
{
return (Exception) this.execution.getContext().getProperty(ExtensionManagerScriptService.EXTENSIONERROR_KEY);
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-security-bridge
/**
* @return the current {@code XWikiContext}
*/
private XWikiContext getXWikiContext()
{
return ((XWikiContext) execution.getContext().getProperty(XWikiContext.EXECUTIONCONTEXT_KEY));
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-icon-script
/**
* Get the error generated while performing the previously called action.
*
* @return an eventual exception or {@code null} if no exception was thrown
* @since 6.3RC1
*/
public IconException getLastError()
{
return (IconException) this.execution.getContext().getProperty(ERROR_KEY);
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-watchlist-api
/**
* Get the error generated while performing the previously called action.
*
* @return the exception or {@code null} if no exception was thrown
*/
public Exception getLastError()
{
return (Exception) this.execution.getContext().getProperty(ERROR_KEY);
}
代码示例来源:origin: com.xpn.xwiki.platform/xwiki-core
/**
* Get XWiki context from execution context.
*
* @return the XWiki context for the current thread
*/
private XWikiContext getXWikiContext()
{
Execution execution = Utils.getComponent(Execution.class);
ExecutionContext ec = execution.getContext();
return ec != null ? (XWikiContext) ec.getProperty("xwikicontext") : null;
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-search-lucene-api
private XWikiContext getContext()
{
return (XWikiContext) Utils.getComponent(Execution.class).getContext()
.getProperty(XWikiContext.EXECUTIONCONTEXT_KEY);
}
代码示例来源:origin: com.xpn.xwiki.platform/xwiki-core
protected XWikiContext getContext()
{
Execution execution = Utils.getComponent(Execution.class);
ExecutionContext executionContext = execution.getContext();
return (XWikiContext) executionContext.getProperty("xwikicontext");
}
代码示例来源:origin: org.xwiki.platform/xwiki-platform-mail-send-storage
@Override
public void onPrepareMessageSuccess(ExtendedMimeMessage message, Map<String, Object> parameters)
{
super.onPrepareMessageSuccess(message, parameters);
MailStatus status = new MailStatus(getBatchId(), message, MailState.PREPARE_SUCCESS);
status.setWiki(
((XWikiContext) execution.getContext().getProperty(XWikiContext.EXECUTIONCONTEXT_KEY)).getWikiId());
saveStatus(status, parameters);
}
内容来源于网络,如有侵权,请联系作者删除!