org.eclipse.internal.xpand2.codeassist
Class KeywordProposalComputer
java.lang.Object
org.eclipse.internal.xpand2.codeassist.KeywordProposalComputer
- All Implemented Interfaces:
- ProposalComputer
public class KeywordProposalComputer
- extends Object
- implements ProposalComputer
Responsible for proposals of Xpand keywords.
- Since:
- 4.0
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
KeywordProposalComputer
public KeywordProposalComputer()
computeProposals
public List<Object> computeProposals(String txt,
ExecutionContext ctx,
ProposalFactory factory)
- Specified by:
computeProposals in interface ProposalComputer
getPrefix
protected String getPrefix(String txt)
- Parameters:
txt - Some text
- Returns:
- The capital letters (A-Z) at the end of txt
- Since:
- 2.0
getInsertionSuffix
protected String getInsertionSuffix(String keyword)
- Returns the character to insert after a specific keyword.
For all closing keywords (ENDFOREACH, ENDDEFINE) this will be the closing bracket.
The same for REM, since it does not contain anything.
For all other keywords a space character will be returned.
- Parameters:
keyword - Xpand keyword
- Returns:
- Whitespace or Xpand closing bracket
- Since:
- 2.0
- See Also:
XpandTokens
Copyright © 2015. All rights reserved.