use of org.eclipse.xtext.ui.editor.contentassist.ReplacementTextApplier in project xtext-eclipse by eclipse.
the class ContentAssistProcessorTestBuilder method getProposedText.
protected String getProposedText(ICompletionProposal completionProposal) {
String proposedText = completionProposal.getDisplayString();
if (completionProposal instanceof ConfigurableCompletionProposal) {
ConfigurableCompletionProposal configurableProposal = (ConfigurableCompletionProposal) completionProposal;
proposedText = configurableProposal.getReplacementString();
if (configurableProposal.getTextApplier() instanceof ReplacementTextApplier) {
proposedText = ((ReplacementTextApplier) configurableProposal.getTextApplier()).getActualReplacementString(configurableProposal);
}
}
return proposedText;
}
use of org.eclipse.xtext.ui.editor.contentassist.ReplacementTextApplier in project xtext-xtend by eclipse.
the class EclipseBug28DirtyStateModifierContentAssistTest method getProposedText.
private static String getProposedText(ICompletionProposal completionProposal) {
String proposedText = completionProposal.getDisplayString();
if (completionProposal instanceof ConfigurableCompletionProposal) {
ConfigurableCompletionProposal configurableProposal = (ConfigurableCompletionProposal) completionProposal;
proposedText = configurableProposal.getReplacementString();
if (configurableProposal.getTextApplier() instanceof ReplacementTextApplier) {
proposedText = ((ReplacementTextApplier) configurableProposal.getTextApplier()).getActualReplacementString(configurableProposal);
}
}
return proposedText;
}
use of org.eclipse.xtext.ui.editor.contentassist.ReplacementTextApplier in project xtext-eclipse by eclipse.
the class ContentAssistProcessorTestBuilder method getProposedText.
protected String getProposedText(ICompletionProposal completionProposal) {
String proposedText = completionProposal.getDisplayString();
if (completionProposal instanceof ConfigurableCompletionProposal) {
ConfigurableCompletionProposal configurableProposal = (ConfigurableCompletionProposal) completionProposal;
proposedText = configurableProposal.getReplacementString();
if (configurableProposal.getTextApplier() instanceof ReplacementTextApplier) {
proposedText = ((ReplacementTextApplier) configurableProposal.getTextApplier()).getActualReplacementString(configurableProposal);
}
}
return proposedText;
}
Aggregations