Class ExpressionFunctionProposalProvider

java.lang.Object
org.dawnsci.common.widgets.gda.function.jexl.ExpressionFunctionProposalProvider
All Implemented Interfaces:
org.eclipse.jface.fieldassist.IContentProposalProvider

public class ExpressionFunctionProposalProvider extends Object implements org.eclipse.jface.fieldassist.IContentProposalProvider
TODO: Resolve this difference/copy. This class is a copy of org.dawb.workbench.ui.expressions.ExpressionFunctionProposalProvider however it has been reworked to instead of rely on testing the provider instead creating proposals that have the needed information (lastMatchBounds, lastPosition). TODO: small additional TODO/Q about whether non-static methods should be excluded.
  • Constructor Details

    • ExpressionFunctionProposalProvider

      public ExpressionFunctionProposalProvider(Map<String,Object> functions)
      Construct a ExpressionFunctionProposalProvider whose content proposals are always the specified array of Objects.
      Parameters:
      functions - the Map of Objects that proposals are extracted from
  • Method Details

    • getProposals

      public JexlProposal[] getProposals(String contents, int position)
      Specified by:
      getProposals in interface org.eclipse.jface.fieldassist.IContentProposalProvider
    • setProposals

      public void setProposals(Map<String,Object> functions)
    • getLastMatchBounds

      public int[] getLastMatchBounds()
    • getLastPosition

      public int getLastPosition()