本文整理汇总了Java中org.eclipse.jface.text.contentassist.IContextInformationPresenter类的典型用法代码示例。如果您正苦于以下问题:Java IContextInformationPresenter类的具体用法?Java IContextInformationPresenter怎么用?Java IContextInformationPresenter使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IContextInformationPresenter类属于org.eclipse.jface.text.contentassist包,在下文中一共展示了IContextInformationPresenter类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: createContextFrame
点赞 3
import org.eclipse.jface.text.contentassist.IContextInformationPresenter; //导入依赖的package包/类
/**
* Creates a context frame for the given offset.
*
* @param information
* the context information
* @param offset
* the offset
* @return the created context frame
* @since 3.0
*/
private ContextFrame createContextFrame(IContextInformation information, int offset)
{
IContextInformationValidator validator = fContentAssistSubjectControlAdapter.getContextInformationValidator(
fContentAssistant, offset);
if (validator != null)
{
int beginOffset = (information instanceof IContextInformationExtension) ? ((IContextInformationExtension) information)
.getContextInformationPosition() : offset;
if (beginOffset == -1)
{
beginOffset = offset;
}
int visibleOffset = fContentAssistSubjectControlAdapter.getWidgetSelectionRange().x
- (offset - beginOffset);
IContextInformationPresenter presenter = fContentAssistSubjectControlAdapter
.getContextInformationPresenter(fContentAssistant, offset);
return new ContextFrame(information, beginOffset, offset, visibleOffset, validator, presenter);
}
return null;
}
开发者ID:apicloudcom,
项目名称:APICloud-Studio,
代码行数:33,
代码来源:ContextInformationPopup.java
示例2: ContextFrame
点赞 2
import org.eclipse.jface.text.contentassist.IContextInformationPresenter; //导入依赖的package包/类
public ContextFrame(IContextInformation information, int beginOffset, int offset, int visibleOffset,
IContextInformationValidator validator, IContextInformationPresenter presenter)
{
fInformation = information;
fBeginOffset = beginOffset;
fOffset = offset;
fVisibleOffset = visibleOffset;
fValidator = validator;
fPresenter = presenter;
}
开发者ID:apicloudcom,
项目名称:APICloud-Studio,
代码行数:11,
代码来源:ContextInformationPopup.java
示例3: ContextInformationDelegator
点赞 2
import org.eclipse.jface.text.contentassist.IContextInformationPresenter; //导入依赖的package包/类
private ContextInformationDelegator(IContextInformationValidator defaultContextInformationValidator) {
Assert.isTrue(defaultContextInformationValidator instanceof IContextInformationPresenter);
this.defaultContextInformationValidator = defaultContextInformationValidator;
}
开发者ID:fabioz,
项目名称:Pydev,
代码行数:5,
代码来源:SimpleAssistProcessor.java
示例4: updatePresentation
点赞 2
import org.eclipse.jface.text.contentassist.IContextInformationPresenter; //导入依赖的package包/类
@Override
public boolean updatePresentation(int offset, TextPresentation presentation) {
return ((IContextInformationPresenter) defaultContextInformationValidator).updatePresentation(offset,
presentation);
}
开发者ID:fabioz,
项目名称:Pydev,
代码行数:6,
代码来源:SimpleAssistProcessor.java
示例5: getContextInformationPresenter
点赞 1
import org.eclipse.jface.text.contentassist.IContextInformationPresenter; //导入依赖的package包/类
/**
* Returns the context information presenter that should be used to display context information. The position is
* used to determine the appropriate code assist processor to invoke.
*
* @param contentAssistant
* the code assistant
* @param offset
* a document offset
* @return a presenter
*/
public IContextInformationPresenter getContextInformationPresenter(ContentAssistant contentAssistant, int offset)
{
if (fContentAssistSubjectControl != null)
{
return contentAssistant.getContextInformationPresenter(fContentAssistSubjectControl, offset);
}
return contentAssistant.getContextInformationPresenter(fViewer, offset);
}
开发者ID:apicloudcom,
项目名称:APICloud-Studio,
代码行数:19,
代码来源:ContentAssistSubjectControlAdapter.java
示例6: getContextInformationPresenter
点赞 1
import org.eclipse.jface.text.contentassist.IContextInformationPresenter; //导入依赖的package包/类
/**
* Returns the context information presenter that should be used to display context information. The position is
* used to determine the appropriate code assist processor to invoke.
*
* @param viewer
* the text viewer
* @param offset
* a document offset
* @return a presenter
* @since 2.0
*/
IContextInformationPresenter getContextInformationPresenter(ITextViewer viewer, int offset)
{
IContextInformationValidator validator = getContextInformationValidator(viewer, offset);
if (validator instanceof IContextInformationPresenter)
{
return (IContextInformationPresenter) validator;
}
return null;
}
开发者ID:apicloudcom,
项目名称:APICloud-Studio,
代码行数:21,
代码来源:ContentAssistant.java