1 11 package org.eclipse.jdt.core.eval; 12 13 import org.eclipse.core.runtime.IProgressMonitor; 14 import org.eclipse.jdt.core.*; 15 import org.eclipse.jdt.core.IJavaElement; 16 import org.eclipse.jdt.core.IJavaProject; 17 import org.eclipse.jdt.core.IType; 18 import org.eclipse.jdt.core.JavaModelException; 19 20 89 public interface IEvaluationContext { 90 96 public IGlobalVariable[] allVariables(); 97 117 public void codeComplete( 118 String codeSnippet, 119 int position, 120 ICompletionRequestor requestor) 121 throws JavaModelException; 122 150 public void codeComplete( 151 String codeSnippet, 152 int position, 153 ICompletionRequestor requestor, 154 WorkingCopyOwner owner) 155 throws JavaModelException; 156 175 public void codeComplete( 176 String codeSnippet, 177 int position, 178 CompletionRequestor requestor) 179 throws JavaModelException; 180 207 public void codeComplete( 208 String codeSnippet, 209 int position, 210 CompletionRequestor requestor, 211 WorkingCopyOwner owner) 212 throws JavaModelException; 213 233 public IJavaElement[] codeSelect(String codeSnippet, int offset, int length) 234 throws JavaModelException; 235 264 public IJavaElement[] codeSelect(String codeSnippet, int offset, int length, WorkingCopyOwner owner) 265 throws JavaModelException; 266 272 public void deleteVariable(IGlobalVariable variable); 273 308 public void evaluateCodeSnippet( 309 String codeSnippet, 310 String [] localVariableTypeNames, 311 String [] localVariableNames, 312 int[] localVariableModifiers, 313 IType declaringType, 314 boolean isStatic, 315 boolean isConstructorCall, 316 ICodeSnippetRequestor requestor, 317 IProgressMonitor progressMonitor) 318 throws JavaModelException; 319 338 public void evaluateCodeSnippet( 339 String codeSnippet, 340 ICodeSnippetRequestor requestor, 341 IProgressMonitor progressMonitor) 342 throws JavaModelException; 343 359 public void evaluateVariable( 360 IGlobalVariable variable, 361 ICodeSnippetRequestor requestor, 362 IProgressMonitor progressMonitor) 363 throws JavaModelException; 364 373 public String [] getImports(); 374 382 public String getPackageName(); 383 388 public IJavaProject getProject(); 389 405 public IGlobalVariable newVariable( 406 String typeName, 407 String name, 408 String initializer); 409 418 public void setImports(String [] imports); 419 426 public void setPackageName(String packageName); 427 434 public void validateImports(ICodeSnippetRequestor requestor) 435 throws JavaModelException; 436 437 456 public void codeComplete( 457 String codeSnippet, 458 int position, 459 org.eclipse.jdt.core.ICodeCompletionRequestor requestor) 460 throws JavaModelException; 461 462 } 463 | Popular Tags |