Search in sources :

Example 1 with STPProbeCompletionProposal

use of org.eclipse.linuxtools.internal.systemtap.ui.ide.editors.stp.proposals.STPProbeCompletionProposal in project linuxtools by eclipse.

the class STPCompletionProcessor method getProbeCompletionList.

private ICompletionProposal[] getProbeCompletionList(String prefix, int offset) {
    prefix = canonicalizePrefix(prefix);
    TreeNode[] completionData = stpMetadataSingleton.getProbeCompletions(prefix);
    ICompletionProposal[] result = new ICompletionProposal[completionData.length];
    for (int i = 0; i < completionData.length; i++) {
        result[i] = new STPProbeCompletionProposal(completionData[i], prefix.length(), offset);
    }
    return result;
}
Also used : TreeNode(org.eclipse.linuxtools.systemtap.structures.TreeNode) ICompletionProposal(org.eclipse.jface.text.contentassist.ICompletionProposal) STPProbeCompletionProposal(org.eclipse.linuxtools.internal.systemtap.ui.ide.editors.stp.proposals.STPProbeCompletionProposal)

Aggregations

ICompletionProposal (org.eclipse.jface.text.contentassist.ICompletionProposal)1 STPProbeCompletionProposal (org.eclipse.linuxtools.internal.systemtap.ui.ide.editors.stp.proposals.STPProbeCompletionProposal)1 TreeNode (org.eclipse.linuxtools.systemtap.structures.TreeNode)1