JavaCore extends Plugin
/******************************************************************************* 2 * Copyright (c) 2000, 2007 IBM Corporation and others. 3 * All rights reserved. This program and the accompanying materials 4 * are made available under the terms of the Eclipse Public License v1.0 5 * which accompanies this distribution, and is available at 6 * https://www.eclipse.org/legal/epl-v10.html 7 * 8 * Contributors: 9 * IBM Corporation - initial API and implementation 10 * IBM Corporation - added the following constants: 11 * COMPILER_PB_DEPRECATION_IN_DEPRECATED_CODE 12 * COMPILER_PB_STATIC_ACCESS_RECEIVER 13 * COMPILER_TASK_TAGS 14 * CORE_CIRCULAR_CLASSPATH 15 * CORE_INCOMPLETE_CLASSPATH 16 * IBM Corporation - added run(IWorkspaceRunnable, IProgressMonitor) 17 * IBM Corporation - added exclusion patterns to source classpath entries 18 * IBM Corporation - added specific output location to source classpath entries 19 * IBM Corporation - added the following constants: 20 * CORE_JAVA_BUILD_CLEAN_OUTPUT_FOLDER 21 * CORE_JAVA_BUILD_RECREATE_MODIFIED_CLASS_FILES_IN_OUTPUT_FOLDER 22 * CLEAN 23 * IBM Corporation - added getClasspathContainerInitializer(String) 24 * IBM Corporation - added the following constants: 25 * CODEASSIST_ARGUMENT_PREFIXES 26 * CODEASSIST_ARGUMENT_SUFFIXES 27 * CODEASSIST_FIELD_PREFIXES 28 * CODEASSIST_FIELD_SUFFIXES 29 * CODEASSIST_LOCAL_PREFIXES 30 * CODEASSIST_LOCAL_SUFFIXES 31 * CODEASSIST_STATIC_FIELD_PREFIXES 32 * CODEASSIST_STATIC_FIELD_SUFFIXES 33 * COMPILER_PB_CHAR_ARRAY_IN_STRING_CONCATENATION 34 * IBM Corporation - added the following constants: 35 * COMPILER_PB_LOCAL_VARIABLE_HIDING 36 * COMPILER_PB_SPECIAL_PARAMETER_HIDING_FIELD 37 * COMPILER_PB_FIELD_HIDING 38 * COMPILER_PB_POSSIBLE_ACCIDENTAL_BOOLEAN_ASSIGNMENT 39 * CORE_INCOMPATIBLE_JDK_LEVEL 40 * VERSION_1_5 41 * COMPILER_PB_EMPTY_STATEMENT 42 * IBM Corporation - added the following constants: 43 * COMPILER_PB_INDIRECT_STATIC_ACCESS 44 * COMPILER_PB_BOOLEAN_METHOD_THROWING_EXCEPTION 45 * COMPILER_PB_UNNECESSARY_CAST 46 * IBM Corporation - added the following constants: 47 * COMPILER_PB_INVALID_JAVADOC 48 * COMPILER_PB_INVALID_JAVADOC_TAGS 49 * COMPILER_PB_INVALID_JAVADOC_TAGS_VISIBILITY 50 * COMPILER_PB_MISSING_JAVADOC_TAGS 51 * COMPILER_PB_MISSING_JAVADOC_TAGS_VISIBILITY 52 * COMPILER_PB_MISSING_JAVADOC_TAGS_OVERRIDING 53 * COMPILER_PB_MISSING_JAVADOC_COMMENTS 54 * COMPILER_PB_MISSING_JAVADOC_COMMENTS_VISIBILITY 55 * COMPILER_PB_MISSING_JAVADOC_COMMENTS_OVERRIDING 56 * COMPILER_PB_DEPRECATION_WHEN_OVERRIDING_DEPRECATED_METHOD 57 * COMPILER_PB_UNUSED_DECLARED_THROWN_EXCEPTION_WHEN_OVERRIDING 58 * IBM Corporation - added the following constants: 59 * TIMEOUT_FOR_PARAMETER_NAME_FROM_ATTACHED_JAVADOC 60 * IBM Corporation - added the following constants: 61 * COMPILER_PB_FALLTHROUGH_CASE 62 * COMPILER_PB_PARAMETER_ASSIGNMENT 63 * COMPILER_PB_NULL_REFERENCE 64 * IBM Corporation - added the following constants: 65 * CODEASSIST_DEPRECATION_CHECK 66 * IBM Corporation - added the following constants: 67 * COMPILER_PB_POTENTIAL_NULL_REFERENCE 68 * COMPILER_PB_REDUNDANT_NULL_CHECK 69 * IBM Corporation - added the following constants: 70 * COMPILER_PB_UNUSED_PARAMETER_INCLUDE_DOC_COMMENT_REFERENCE 71 *******************************************************************************/ 72 package org.eclipse.jdt.core; 73 74 import java.io.File JavaDoc; 75 import java.util.ArrayList JavaDoc; 76 import java.util.HashMap JavaDoc; 77 import java.util.Hashtable JavaDoc; 78 import java.util.Map JavaDoc; 79 80 import org.eclipse.core.resources.IContainer; 81 import org.eclipse.core.resources.IFile; 82 import org.eclipse.core.resources.IFolder; 83 import org.eclipse.core.resources.IMarker; 84 import org.eclipse.core.resources.IMarkerDelta; 85 import org.eclipse.core.resources.IProject; 86 import org.eclipse.core.resources.IResource; 87 import org.eclipse.core.resources.IResourceChangeEvent; 88 import org.eclipse.core.resources.IResourceChangeListener; 89 import org.eclipse.core.resources.IWorkspace; 90 import org.eclipse.core.resources.IWorkspaceRoot; 91 import org.eclipse.core.resources.IWorkspaceRunnable; 92 import org.eclipse.core.resources.ResourcesPlugin; 93 import org.eclipse.core.runtime.Assert; 94 import org.eclipse.core.runtime.CoreException; 95 import org.eclipse.core.runtime.IConfigurationElement; 96 import org.eclipse.core.runtime.IExtension; 97 import org.eclipse.core.runtime.IExtensionPoint; 98 import org.eclipse.core.runtime.IPath; 99 import org.eclipse.core.runtime.IProgressMonitor; 100 import org.eclipse.core.runtime.OperationCanceledException; 101 import org.eclipse.core.runtime.Platform; 102 import org.eclipse.core.runtime.Plugin; 103 import org.eclipse.core.runtime.QualifiedName; 104 import org.eclipse.core.runtime.SubProgressMonitor; 105 import org.eclipse.core.runtime.jobs.ISchedulingRule; 106 import org.eclipse.jdt.core.compiler.CharOperation; 107 import org.eclipse.jdt.core.search.IJavaSearchConstants; 108 import org.eclipse.jdt.core.search.IJavaSearchScope; 109 import org.eclipse.jdt.core.search.SearchEngine; 110 import org.eclipse.jdt.core.search.SearchPattern; 111 import org.eclipse.jdt.core.search.TypeNameRequestor; 112 import org.eclipse.jdt.internal.compiler.classfmt.ClassFileConstants; 113 import org.eclipse.jdt.internal.compiler.impl.CompilerOptions; 114 import org.eclipse.jdt.internal.compiler.util.SuffixConstants; 115 import org.eclipse.jdt.internal.core.*; 116 import org.eclipse.jdt.internal.core.builder.JavaBuilder; 117 import org.eclipse.jdt.internal.core.builder.State; 118 import org.eclipse.jdt.internal.core.util.MementoTokenizer; 119 import org.eclipse.jdt.internal.core.util.Messages; 120 import org.eclipse.jdt.internal.core.util.Util; 121 import org.osgi.framework.BundleContext; 122 123 /** 124 * The plug-in runtime class for the Java model plug-in containing the core 125 * (UI-free) support for Java projects. 126 * <p> 127 * Like all plug-in runtime classes (subclasses of <code>Plugin</code>), this 128 * class is automatically instantiated by the platform when the plug-in gets 129 * activated. Clients must not attempt to instantiate plug-in runtime classes 130 * directly. 131 * </p> 132 * <p> 133 * The single instance of this class can be accessed from any plug-in declaring 134 * the Java model plug-in as a prerequisite via 135 * <code>JavaCore.getJavaCore()</code>. The Java model plug-in will be activated 136 * automatically if not already active. 137 * </p> 138 */ 139 public final class JavaCore extends Plugin { 140 141 private static final IResource[] NO_GENERATED_RESOURCES = new IResource[0]; 142 143 private static Plugin JAVA_CORE_PLUGIN = null; 144 /** 145 * The plug-in identifier of the Java core support 146 * (value <code>"org.eclipse.jdt.core"</code>). 147 */ 148 public static final String JavaDoc PLUGIN_ID = "org.eclipse.jdt.core" ; //$NON-NLS-1$ 149 150 /** 151 * The identifier for the Java builder 152 * (value <code>"org.eclipse.jdt.core.javabuilder"</code>). 153 */ 154 public static final String JavaDoc BUILDER_ID = PLUGIN_ID + ".javabuilder" ; //$NON-NLS-1$ 155 156 /** 157 * The identifier for the Java model 158 * (value <code>"org.eclipse.jdt.core.javamodel"</code>). 159 */ 160 public static final String JavaDoc MODEL_ID = PLUGIN_ID + ".javamodel" ; //$NON-NLS-1$ 161 162 /** 163 * The identifier for the Java nature 164 * (value <code>"org.eclipse.jdt.core.javanature"</code>). 165 * The presence of this nature on a project indicates that it is 166 * Java-capable. 167 * 168 * @see org.eclipse.core.resources.IProject#hasNature(java.lang.String) 169 */ 170 public static final String JavaDoc NATURE_ID = PLUGIN_ID + ".javanature" ; //$NON-NLS-1$ 171 172 /** 173 * Name of the handle id attribute in a Java marker. 174 */ 175 protected static final String JavaDoc ATT_HANDLE_ID = 176 "org.eclipse.jdt.internal.core.JavaModelManager.handleId" ; //$NON-NLS-1$ 177 178 /** 179 * Name of the User Library Container id. 180 * @since 3.0 181 */ 182 public static final String JavaDoc USER_LIBRARY_CONTAINER_ID= "org.eclipse.jdt.USER_LIBRARY"; //$NON-NLS-1$ 183 184 // *************** Possible IDs for configurable options. ******************** 185 186 /** 187 * Possible configurable option ID. 188 * @see #getDefaultOptions() 189 */ 190 public static final String JavaDoc COMPILER_LOCAL_VARIABLE_ATTR = PLUGIN_ID + ".compiler.debug.localVariable"; //$NON-NLS-1$ 191 /** 192 * Possible configurable option ID. 193 * @see #getDefaultOptions() 194 */ 195 public static final String JavaDoc COMPILER_LINE_NUMBER_ATTR = PLUGIN_ID + ".compiler.debug.lineNumber"; //$NON-NLS-1$ 196 /** 197 * Possible configurable option ID. 198 * @see #getDefaultOptions() 199 */ 200 public static final String JavaDoc COMPILER_SOURCE_FILE_ATTR = PLUGIN_ID + ".compiler.debug.sourceFile"; //$NON-NLS-1$ 201 /** 202 * Possible configurable option ID. 203 * @see #getDefaultOptions() 204 */ 205 public static final String JavaDoc COMPILER_CODEGEN_UNUSED_LOCAL = PLUGIN_ID + ".compiler.codegen.unusedLocal"; //$NON-NLS-1$ 206 /** 207 * Possible configurable option ID. 208 * @see #getDefaultOptions() 209 */ 210 public static final String JavaDoc COMPILER_CODEGEN_TARGET_PLATFORM = PLUGIN_ID + ".compiler.codegen.targetPlatform"; //$NON-NLS-1$ 211 /** 212 * Possible configurable option ID. 213 * @see #getDefaultOptions() 214 * @since 3.0 215 */ 216 public static final String JavaDoc COMPILER_CODEGEN_INLINE_JSR_BYTECODE = PLUGIN_ID + ".compiler.codegen.inlineJsrBytecode"; //$NON-NLS-1$ 217 /** 218 * Possible configurable option ID. 219 * @see #getDefaultOptions() 220 * @since 3.0 221 */ 222 public static final String JavaDoc COMPILER_DOC_COMMENT_SUPPORT = PLUGIN_ID + ".compiler.doc.comment.support"; //$NON-NLS-1$ 223 /** 224 * Possible configurable option ID. 225 * @see #getDefaultOptions() 226 * @deprecated - discontinued since turning off would violate language specs 227 */ 228 public static final String JavaDoc COMPILER_PB_UNREACHABLE_CODE = PLUGIN_ID + ".compiler.problem.unreachableCode"; //$NON-NLS-1$ 229 /** 230 * Possible configurable option ID. 231 * @see #getDefaultOptions() 232 * @deprecated - discontinued since turning off would violate language specs 233 */ 234 public static final String JavaDoc COMPILER_PB_INVALID_IMPORT = PLUGIN_ID + ".compiler.problem.invalidImport"; //$NON-NLS-1$ 235 /** 236 * Possible configurable option ID. 237 * @see #getDefaultOptions() 238 */ 239 public static final String JavaDoc COMPILER_PB_OVERRIDING_PACKAGE_DEFAULT_METHOD = PLUGIN_ID + ".compiler.problem.overridingPackageDefaultMethod"; //$NON-NLS-1$ 240 /** 241 * Possible configurable option ID. 242 * @see #getDefaultOptions() 243 */ 244 public static final String JavaDoc COMPILER_PB_METHOD_WITH_CONSTRUCTOR_NAME = PLUGIN_ID + ".compiler.problem.methodWithConstructorName"; //$NON-NLS-1$ 245 /** 246 * Possible configurable option ID. 247 * @see #getDefaultOptions() 248 */ 249 public static final String JavaDoc COMPILER_PB_DEPRECATION = PLUGIN_ID + ".compiler.problem.deprecation"; //$NON-NLS-1$ 250 /** 251 * Possible configurable option ID. 252 * @see #getDefaultOptions() 253 * @since 2.1 254 */ 255 public static final String JavaDoc COMPILER_PB_DEPRECATION_IN_DEPRECATED_CODE = PLUGIN_ID + ".compiler.problem.deprecationInDeprecatedCode"; //$NON-NLS-1$ 256 /** 257 * Possible configurable option ID. 258 * @see #getDefaultOptions() 259 * @since 3.0 260 */ 261 public static final String JavaDoc COMPILER_PB_DEPRECATION_WHEN_OVERRIDING_DEPRECATED_METHOD = "org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod"; //$NON-NLS-1$ 262 /** 263 * Possible configurable option ID. 264 * @see #getDefaultOptions() 265 */ 266 public static final String JavaDoc COMPILER_PB_HIDDEN_CATCH_BLOCK = PLUGIN_ID + ".compiler.problem.hiddenCatchBlock"; //$NON-NLS-1$ 267 /** 268 * Possible configurable option ID. 269 * @see #getDefaultOptions() 270 */ 271 public static final String JavaDoc COMPILER_PB_UNUSED_LOCAL = PLUGIN_ID + ".compiler.problem.unusedLocal"; //$NON-NLS-1$ 272 /** 273 * Possible configurable option ID. 274 * @see #getDefaultOptions() 275 */ 276 public static final String JavaDoc COMPILER_PB_UNUSED_PARAMETER = PLUGIN_ID + ".compiler.problem.unusedParameter"; //$NON-NLS-1$ 277 /** 278 * Possible configurable option ID. 279 * @see #getDefaultOptions() 280 * @since 2.1 281 */ 282 public static final String JavaDoc COMPILER_PB_UNUSED_PARAMETER_WHEN_IMPLEMENTING_ABSTRACT = PLUGIN_ID + ".compiler.problem.unusedParameterWhenImplementingAbstract"; //$NON-NLS-1$ 283 /** 284 * Possible configurable option ID. 285 * @see #getDefaultOptions() 286 * @since 2.1 287 */ 288 public static final String JavaDoc COMPILER_PB_UNUSED_PARAMETER_WHEN_OVERRIDING_CONCRETE = PLUGIN_ID + ".compiler.problem.unusedParameterWhenOverridingConcrete"; //$NON-NLS-1$ 289 /** 290 * Possible configurable option ID. 291 * @see #getDefaultOptions() 292 * @since 3.3 293 */ 294 public static final String JavaDoc COMPILER_PB_UNUSED_PARAMETER_INCLUDE_DOC_COMMENT_REFERENCE = PLUGIN_ID + ".compiler.problem.unusedParameterIncludeDocCommentReference"; //$NON-NLS-1$ 295 /** 296 * Possible configurable option ID. 297 * @see #getDefaultOptions() 298 * @since 2.0 299 */ 300 public static final String JavaDoc COMPILER_PB_UNUSED_IMPORT = PLUGIN_ID + ".compiler.problem.unusedImport"; //$NON-NLS-1$ 301 /** 302 * Possible configurable option ID. 303 * @see #getDefaultOptions() 304 */ 305 public static final String JavaDoc COMPILER_PB_SYNTHETIC_ACCESS_EMULATION = PLUGIN_ID + ".compiler.problem.syntheticAccessEmulation"; //$NON-NLS-1$ 306 /** 307 * Possible configurable option ID. 308 * @see #getDefaultOptions() 309 * @since 2.0 310 */ 311 public static final String JavaDoc COMPILER_PB_NON_NLS_STRING_LITERAL = PLUGIN_ID + ".compiler.problem.nonExternalizedStringLiteral"; //$NON-NLS-1$ 312 /** 313 * Possible configurable option ID. 314 * @see #getDefaultOptions() 315 * @since 2.0 316 */ 317 public static final String JavaDoc COMPILER_PB_ASSERT_IDENTIFIER = PLUGIN_ID + ".compiler.problem.assertIdentifier"; //$NON-NLS-1$ 318 /** 319 * Possible configurable option ID. 320 * @see #getDefaultOptions() 321 * @since 3.1 322 */ 323 public static final String JavaDoc COMPILER_PB_ENUM_IDENTIFIER = PLUGIN_ID + ".compiler.problem.enumIdentifier"; //$NON-NLS-1$ 324 /** 325 * Possible configurable option ID. 326 * @see #getDefaultOptions() 327 * @since 2.1 328 */ 329 public static final String JavaDoc COMPILER_PB_STATIC_ACCESS_RECEIVER = PLUGIN_ID + ".compiler.problem.staticAccessReceiver"; //$NON-NLS-1$ 330 /** 331 * Possible configurable option ID. 332 * @see #getDefaultOptions() 333 * @since 3.0 334 */ 335 public static final String JavaDoc COMPILER_PB_INDIRECT_STATIC_ACCESS = PLUGIN_ID + ".compiler.problem.indirectStaticAccess"; //$NON-NLS-1$ 336 /** 337 * Possible configurable option ID. 338 * @see #getDefaultOptions() 339 * @since 2.1 340 */ 341 public static final String JavaDoc COMPILER_PB_NO_EFFECT_ASSIGNMENT = PLUGIN_ID + ".compiler.problem.noEffectAssignment"; //$NON-NLS-1$ 342 /** 343 * Possible configurable option ID. 344 * @see #getDefaultOptions() 345 * @since 2.1 346 */ 347 public static final String JavaDoc COMPILER_PB_INCOMPATIBLE_NON_INHERITED_INTERFACE_METHOD = PLUGIN_ID + ".compiler.problem.incompatibleNonInheritedInterfaceMethod"; //$NON-NLS-1$ 348 /** 349 * Possible configurable option ID. 350 * @see #getDefaultOptions() 351 * @since 2.1 352 */ 353 public static final String JavaDoc COMPILER_PB_UNUSED_PRIVATE_MEMBER = PLUGIN_ID + ".compiler.problem.unusedPrivateMember"; //$NON-NLS-1$ 354 /** 355 * Possible configurable option ID. 356 * @see #getDefaultOptions() 357 * @since 3.0 358 */ 359 public static final String JavaDoc COMPILER_PB_LOCAL_VARIABLE_HIDING = PLUGIN_ID + ".compiler.problem.localVariableHiding"; //$NON-NLS-1$ 360 /** 361 * Possible configurable option ID. 362 * @see #getDefaultOptions() 363 * @since 3.0 364 */ 365 public static final String JavaDoc COMPILER_PB_SPECIAL_PARAMETER_HIDING_FIELD = PLUGIN_ID + ".compiler.problem.specialParameterHidingField"; //$NON-NLS-1$ 366 /** 367 * Possible configurable option ID. 368 * @see #getDefaultOptions() 369 * @since 3.0 370 */ 371 public static final String JavaDoc COMPILER_PB_FIELD_HIDING = PLUGIN_ID + ".compiler.problem.fieldHiding"; //$NON-NLS-1$ 372 /** 373 * Possible configurable option ID. 374 * @see #getDefaultOptions() 375 * @since 3.1 376 */ 377 public static final String JavaDoc COMPILER_PB_TYPE_PARAMETER_HIDING = PLUGIN_ID + ".compiler.problem.typeParameterHiding"; //$NON-NLS-1$ 378 /** 379 * Possible configurable option ID. 380 * @see #getDefaultOptions() 381 * @since 3.0 382 */ 383 public static final String JavaDoc COMPILER_PB_POSSIBLE_ACCIDENTAL_BOOLEAN_ASSIGNMENT = PLUGIN_ID + ".compiler.problem.possibleAccidentalBooleanAssignment"; //$NON-NLS-1$ 384 /** 385 * Possible configurable option ID. 386 * @see #getDefaultOptions() 387 * @since 3.2 388 */ 389 public static final String JavaDoc COMPILER_PB_FALLTHROUGH_CASE = PLUGIN_ID + ".compiler.problem.fallthroughCase"; //$NON-NLS-1$ 390 /** 391 * Possible configurable option ID. 392 * @see #getDefaultOptions() 393 * @since 3.0 394 */ 395 public static final String JavaDoc COMPILER_PB_EMPTY_STATEMENT = PLUGIN_ID + ".compiler.problem.emptyStatement"; //$NON-NLS-1$ 396 /** 397 * Possible configurable option ID. 398 * @see #getDefaultOptions() 399 * @since 3.0 400 */ 401 public static final String JavaDoc COMPILER_PB_BOOLEAN_METHOD_THROWING_EXCEPTION = PLUGIN_ID + ".compiler.problem.booleanMethodThrowingException"; //$NON-NLS-1$ 402 /** 403 * Possible configurable option ID. 404 * @see #getDefaultOptions() 405 * @since 3.0 406 */ 407 public static final String JavaDoc COMPILER_PB_UNNECESSARY_TYPE_CHECK = PLUGIN_ID + ".compiler.problem.unnecessaryTypeCheck"; //$NON-NLS-1$ 408 /** 409 * Possible configurable option ID. 410 * @see #getDefaultOptions() 411 * @since 3.0 412 */ 413 public static final String JavaDoc COMPILER_PB_UNNECESSARY_ELSE = PLUGIN_ID + ".compiler.problem.unnecessaryElse"; //$NON-NLS-1$ 414 /** 415 * Possible configurable option ID. 416 * @see #getDefaultOptions() 417 * @since 3.0 418 */ 419 public static final String JavaDoc COMPILER_PB_UNDOCUMENTED_EMPTY_BLOCK = PLUGIN_ID + ".compiler.problem.undocumentedEmptyBlock"; //$NON-NLS-1$ 420 /** 421 * Possible configurable option ID. 422 * @see #getDefaultOptions() 423 * @since 3.0 424 */ 425 public static final String JavaDoc COMPILER_PB_FINALLY_BLOCK_NOT_COMPLETING = PLUGIN_ID + ".compiler.problem.finallyBlockNotCompletingNormally"; //$NON-NLS-1$ 426 /** 427 * Possible configurable option ID. 428 * @see #getDefaultOptions() 429 * @since 3.0 430 */ 431 public static final String JavaDoc COMPILER_PB_UNUSED_DECLARED_THROWN_EXCEPTION = PLUGIN_ID + ".compiler.problem.unusedDeclaredThrownException"; //$NON-NLS-1$ 432 /** 433 * Possible configurable option ID. 434 * @see #getDefaultOptions() 435 * @since 3.0 436 */ 437 public static final String JavaDoc COMPILER_PB_UNUSED_DECLARED_THROWN_EXCEPTION_WHEN_OVERRIDING = PLUGIN_ID + ".compiler.problem.unusedDeclaredThrownExceptionWhenOverriding"; //$NON-NLS-1$ 438 /** 439 * Possible configurable option ID. 440 * @see #getDefaultOptions() 441 * @since 3.0 442 */ 443 public static final String JavaDoc COMPILER_PB_UNQUALIFIED_FIELD_ACCESS = PLUGIN_ID + ".compiler.problem.unqualifiedFieldAccess"; //$NON-NLS-1$ 444 /** 445 * Possible configurable option ID. 446 * @see #getDefaultOptions() 447 * @deprecated - got renamed into {@link #COMPILER_PB_UNCHECKED_TYPE_OPERATION} 448 * @since 3.1 449 */ 450 public static final String JavaDoc COMPILER_PB_UNSAFE_TYPE_OPERATION = PLUGIN_ID + ".compiler.problem.uncheckedTypeOperation"; //$NON-NLS-1$ 451 /** 452 * Possible configurable option ID. 453 * @see #getDefaultOptions() 454 * @since 3.1 455 */ 456 public static final String JavaDoc COMPILER_PB_UNCHECKED_TYPE_OPERATION = PLUGIN_ID + ".compiler.problem.uncheckedTypeOperation"; //$NON-NLS-1$ 457 /** 458 * Possible configurable option ID. 459 * @see #getDefaultOptions() 460 * @since 3.2 461 */ 462 public static final String JavaDoc COMPILER_PB_RAW_TYPE_REFERENCE = PLUGIN_ID + ".compiler.problem.rawTypeReference"; //$NON-NLS-1$ 463 /** 464 * Possible configurable option ID. 465 * @see #getDefaultOptions() 466 * @since 3.1 467 */ 468 public static final String JavaDoc COMPILER_PB_FINAL_PARAMETER_BOUND = PLUGIN_ID + ".compiler.problem.finalParameterBound"; //$NON-NLS-1$ 469 /** 470 * Possible configurable option ID. 471 * @see #getDefaultOptions() 472 * @since 3.1 473 */ 474 public static final String JavaDoc COMPILER_PB_MISSING_SERIAL_VERSION = PLUGIN_ID + ".compiler.problem.missingSerialVersion"; //$NON-NLS-1$ 475 /** 476 * Possible configurable option ID. 477 * @see #getDefaultOptions() 478 * @since 3.1 479 */ 480 public static final String JavaDoc COMPILER_PB_VARARGS_ARGUMENT_NEED_CAST = PLUGIN_ID + ".compiler.problem.varargsArgumentNeedCast"; //$NON-NLS-1$ 481 /** 482 * Possible configurable option ID. 483 * @see #getDefaultOptions() 484 * @since 3.1 485 */ 486 public static final String JavaDoc COMPILER_PB_AUTOBOXING = PLUGIN_ID + ".compiler.problem.autoboxing"; //$NON-NLS-1$ 487 /** 488 * Possible configurable option ID. 489 * @see #getDefaultOptions() 490 * @since 3.1 491 */ 492 public static final String JavaDoc COMPILER_PB_ANNOTATION_SUPER_INTERFACE = PLUGIN_ID + ".compiler.problem.annotationSuperInterface"; //$NON-NLS-1$ 493 /** 494 * Possible configurable option ID. 495 * @see #getDefaultOptions() 496 * @since 3.1 497 */ 498 public static final String JavaDoc COMPILER_PB_MISSING_OVERRIDE_ANNOTATION = PLUGIN_ID + ".compiler.problem.missingOverrideAnnotation"; //$NON-NLS-1$ 499 /** 500 * Possible configurable option ID. 501 * @see #getDefaultOptions() 502 * @since 3.1 503 */ 504 public static final String JavaDoc COMPILER_PB_MISSING_DEPRECATED_ANNOTATION = PLUGIN_ID + ".compiler.problem.missingDeprecatedAnnotation"; //$NON-NLS-1$ 505 /** 506 * Possible configurable option ID. 507 * @see #getDefaultOptions() 508 * @since 3.1 509 */ 510 public static final String JavaDoc COMPILER_PB_INCOMPLETE_ENUM_SWITCH = PLUGIN_ID + ".compiler.problem.incompleteEnumSwitch"; //$NON-NLS-1$ 511 /** 512 * Possible configurable option ID. 513 * @since 3.1 514 * @deprecated use {@link #COMPILER_PB_NULL_REFERENCE} instead 515 */ 516 public static final String JavaDoc COMPILER_PB_INCONSISTENT_NULL_CHECK = PLUGIN_ID + ".compiler.problem.inconsistentNullCheck"; //$NON-NLS-1$ 517 /** 518 * Possible configurable option ID. 519 * @see #getDefaultOptions() 520 * @since 3.2 521 */ 522 public static final String JavaDoc COMPILER_PB_UNUSED_LABEL = PLUGIN_ID + ".compiler.problem.unusedLabel"; //$NON-NLS-1$ 523 /** 524 * Possible configurable option ID. 525 * @see #getDefaultOptions() 526 * @since 3.0 527 */ 528 public static final String JavaDoc COMPILER_PB_INVALID_JAVADOC = PLUGIN_ID + ".compiler.problem.invalidJavadoc"; //$NON-NLS-1$ 529 /** 530 * Possible configurable option ID. 531 * @see #getDefaultOptions() 532 * @since 3.0 533 */ 534 public static final String JavaDoc COMPILER_PB_INVALID_JAVADOC_TAGS = PLUGIN_ID + ".compiler.problem.invalidJavadocTags"; //$NON-NLS-1$ 535 /** 536 * Possible configurable option ID. 537 * @see #getDefaultOptions() 538 * @since 3.1 539 */ 540 public static final String JavaDoc COMPILER_PB_INVALID_JAVADOC_TAGS__DEPRECATED_REF = PLUGIN_ID + ".compiler.problem.invalidJavadocTagsDeprecatedRef"; //$NON-NLS-1$ 541 /** 542 * Possible configurable option ID. 543 * @see #getDefaultOptions() 544 * @since 3.1 545 */ 546 public static final String JavaDoc COMPILER_PB_INVALID_JAVADOC_TAGS__NOT_VISIBLE_REF = PLUGIN_ID + ".compiler.problem.invalidJavadocTagsNotVisibleRef"; //$NON-NLS-1$ 547 /** 548 * Possible configurable option ID. 549 * @see #getDefaultOptions() 550 * @since 3.0 551 */ 552 public static final String JavaDoc COMPILER_PB_INVALID_JAVADOC_TAGS_VISIBILITY = PLUGIN_ID + ".compiler.problem.invalidJavadocTagsVisibility"; //$NON-NLS-1$ 553 /** 554 * Possible configurable option ID. 555 * @see #getDefaultOptions() 556 * @since 3.0 557 */ 558 public static final String JavaDoc COMPILER_PB_MISSING_JAVADOC_TAGS = PLUGIN_ID + ".compiler.problem.missingJavadocTags"; //$NON-NLS-1$ 559 /** 560 * Possible configurable option ID. 561 * @see #getDefaultOptions() 562 * @since 3.0 563 */ 564 public static final String JavaDoc COMPILER_PB_MISSING_JAVADOC_TAGS_VISIBILITY = PLUGIN_ID + ".compiler.problem.missingJavadocTagsVisibility"; //$NON-NLS-1$ 565 /** 566 * Possible configurable option ID. 567 * @see #getDefaultOptions() 568 * @since 3.0 569 */ 570 public static final String JavaDoc COMPILER_PB_MISSING_JAVADOC_TAGS_OVERRIDING = PLUGIN_ID + ".compiler.problem.missingJavadocTagsOverriding"; //$NON-NLS-1$ 571 /** 572 * Possible configurable option ID. 573 * @see #getDefaultOptions() 574 * @since 3.0 575 */ 576 public static final String JavaDoc COMPILER_PB_MISSING_JAVADOC_COMMENTS = PLUGIN_ID + ".compiler.problem.missingJavadocComments"; //$NON-NLS-1$ 577 /** 578 * Possible configurable option ID. 579 * @see #getDefaultOptions() 580 * @since 3.0 581 */ 582 public static final String JavaDoc COMPILER_PB_MISSING_JAVADOC_COMMENTS_VISIBILITY = PLUGIN_ID + ".compiler.problem.missingJavadocCommentsVisibility"; //$NON-NLS-1$ 583 /** 584 * Possible configurable option ID. 585 * @see #getDefaultOptions() 586 * @since 3.0 587 */ 588 public static final String JavaDoc COMPILER_PB_MISSING_JAVADOC_COMMENTS_OVERRIDING = PLUGIN_ID + ".compiler.problem.missingJavadocCommentsOverriding"; //$NON-NLS-1$ 589 /** 590 * Possible configurable option ID. 591 * @see #getDefaultOptions() 592 * @since 2.1 593 */ 594 public static final String JavaDoc COMPILER_PB_CHAR_ARRAY_IN_STRING_CONCATENATION = PLUGIN_ID + ".compiler.problem.noImplicitStringConversion"; //$NON-NLS-1$ 595 /** 596 * Possible configurable option ID. 597 * @see #getDefaultOptions() 598 * @since 2.0 599 */ 600 public static final String JavaDoc COMPILER_PB_MAX_PER_UNIT = PLUGIN_ID + ".compiler.maxProblemPerUnit"; //$NON-NLS-1$ 601 /** 602 * Possible configurable option ID. 603 * @see #getDefaultOptions() 604 * @since 3.2 605 */ 606 public static final String JavaDoc COMPILER_PB_FATAL_OPTIONAL_ERROR = PLUGIN_ID + ".compiler.problem.fatalOptionalError"; //$NON-NLS-1$ 607 /** 608 * Possible configurable option ID. 609 * @see #getDefaultOptions() 610 * @since 3.2 611 */ 612 public static final String JavaDoc COMPILER_PB_PARAMETER_ASSIGNMENT = PLUGIN_ID + ".compiler.problem.parameterAssignment"; //$NON-NLS-1$ 613 /** 614 * Possible configurable option ID. 615 * @see #getDefaultOptions() 616 * @since 2.0 617 */ 618 public static final String JavaDoc COMPILER_SOURCE = PLUGIN_ID + ".compiler.source"; //$NON-NLS-1$ 619 /** 620 * Possible configurable option ID. 621 * @see #getDefaultOptions() 622 * @since 2.0 623 */ 624 public static final String JavaDoc COMPILER_COMPLIANCE = PLUGIN_ID + ".compiler.compliance"; //$NON-NLS-1$ 625 /** 626 * Possible configurable option ID. 627 * @see #getDefaultOptions() 628 * @since 2.1 629 */ 630 public static final String JavaDoc COMPILER_TASK_PRIORITIES = PLUGIN_ID + ".compiler.taskPriorities"; //$NON-NLS-1$ 631 /** 632 * Possible configurable option value for COMPILER_TASK_PRIORITIES. 633 * @see #getDefaultOptions() 634 * @since 2.1 635 */ 636 public static final String JavaDoc COMPILER_TASK_PRIORITY_HIGH = "HIGH"; //$NON-NLS-1$ 637 /** 638 * Possible configurable option value for COMPILER_TASK_PRIORITIES. 639 * @see #getDefaultOptions() 640 * @since 2.1 641 */ 642 public static final String JavaDoc COMPILER_TASK_PRIORITY_LOW = "LOW"; //$NON-NLS-1$ 643 /** 644 * Possible configurable option value for COMPILER_TASK_PRIORITIES. 645 * @see #getDefaultOptions() 646 * @since 2.1 647 */ 648 public static final String JavaDoc COMPILER_TASK_PRIORITY_NORMAL = "NORMAL"; //$NON-NLS-1$ 649 /** 650 * Possible configurable option ID. 651 * @see #getDefaultOptions() 652 * @since 2.1 653 */ 654 public static final String JavaDoc COMPILER_TASK_TAGS = PLUGIN_ID + ".compiler.taskTags"; //$NON-NLS-1$ 655 /** 656 * Possible configurable option ID. 657 * @see #getDefaultOptions() 658 * @since 3.0 659 */ 660 public static final String JavaDoc COMPILER_TASK_CASE_SENSITIVE = PLUGIN_ID + ".compiler.taskCaseSensitive"; //$NON-NLS-1$ 661 /** 662 * Possible configurable option ID. 663 * @see #getDefaultOptions() 664 * @since 3.1 665 */ 666 public static final String JavaDoc COMPILER_PB_FORBIDDEN_REFERENCE = PLUGIN_ID + ".compiler.problem.forbiddenReference"; //$NON-NLS-1$ 667 /** 668 * Possible configurable option ID. 669 * @see #getDefaultOptions() 670 * @since 3.1 671 */ 672 public static final String JavaDoc COMPILER_PB_DISCOURAGED_REFERENCE = PLUGIN_ID + ".compiler.problem.discouragedReference"; //$NON-NLS-1$ 673 /** 674 * Possible configurable option ID. 675 * @see #getDefaultOptions() 676 * @since 3.1 677 */ 678 public static final String JavaDoc COMPILER_PB_SUPPRESS_WARNINGS = PLUGIN_ID + ".compiler.problem.suppressWarnings"; //$NON-NLS-1$ 679 /** 680 * Possible configurable option ID. 681 * @see #getDefaultOptions() 682 * @since 3.1 683 */ 684 public static final String JavaDoc COMPILER_PB_UNHANDLED_WARNING_TOKEN = PLUGIN_ID + ".compiler.problem.unhandledWarningToken"; //$NON-NLS-1$ 685 /** 686 * Possible configurable option ID. 687 * @see #getDefaultOptions() 688 * @since 3.2 689 */ 690 public static final String JavaDoc COMPILER_PB_NULL_REFERENCE = PLUGIN_ID + ".compiler.problem.nullReference"; //$NON-NLS-1$ 691 /** 692 * Possible configurable option ID. 693 * @see #getDefaultOptions() 694 * @since 3.3 695 */ 696 public static final String JavaDoc COMPILER_PB_POTENTIAL_NULL_REFERENCE = PLUGIN_ID + ".compiler.problem.potentialNullReference"; //$NON-NLS-1$ 697 /** 698 * Possible configurable option ID. 699 * @see #getDefaultOptions() 700 * @since 3.3 701 */ 702 public static final String JavaDoc COMPILER_PB_REDUNDANT_NULL_CHECK = PLUGIN_ID + ".compiler.problem.redundantNullCheck"; //$NON-NLS-1$ 703 /** 704 * Possible configurable option ID. 705 * @see #getDefaultOptions() 706 * @since 3.3 707 */ 708 public static final String JavaDoc COMPILER_PB_OVERRIDING_METHOD_WITHOUT_SUPER_INVOCATION = PLUGIN_ID + ".compiler.problem.overridingMethodWithoutSuperInvocation"; //$NON-NLS-1$ 709 /** 710 * Possible configurable option ID. 711 * @see #getDefaultOptions() 712 */ 713 public static final String JavaDoc CORE_JAVA_BUILD_ORDER = PLUGIN_ID + ".computeJavaBuildOrder"; //$NON-NLS-1$ 714 /** 715 * Possible configurable option ID. 716 * @see #getDefaultOptions() 717 * @since 2.0 718 */ 719 public static final String JavaDoc CORE_JAVA_BUILD_RESOURCE_COPY_FILTER = PLUGIN_ID + ".builder.resourceCopyExclusionFilter"; //$NON-NLS-1$ 720 /** 721 * Possible configurable option ID. 722 * @see #getDefaultOptions() 723 * @since 2.1 724 */ 725 public static final String JavaDoc CORE_JAVA_BUILD_DUPLICATE_RESOURCE = PLUGIN_ID + ".builder.duplicateResourceTask"; //$NON-NLS-1$ 726 /** 727 * Possible configurable option ID. 728 * @see #getDefaultOptions() 729 * @since 2.1 730 */ 731 public static final String JavaDoc CORE_JAVA_BUILD_CLEAN_OUTPUT_FOLDER = PLUGIN_ID + ".builder.cleanOutputFolder"; //$NON-NLS-1$ 732 /** 733 * Possible configurable option ID. 734 * @see #getDefaultOptions() 735 * @since 3.2 736 */ 737 public static final String JavaDoc CORE_JAVA_BUILD_RECREATE_MODIFIED_CLASS_FILES_IN_OUTPUT_FOLDER = PLUGIN_ID + ".builder.recreateModifiedClassFileInOutputFolder"; //$NON-NLS-1$ 738 /** 739 * Possible configurable option ID. 740 * @see #getDefaultOptions() 741 * @since 2.1 742 */ 743 public static final String JavaDoc CORE_INCOMPLETE_CLASSPATH = PLUGIN_ID + ".incompleteClasspath"; //$NON-NLS-1$ 744 /** 745 * Possible configurable option ID. 746 * @see #getDefaultOptions() 747 * @since 2.1 748 */ 749 public static final String JavaDoc CORE_CIRCULAR_CLASSPATH = PLUGIN_ID + ".circularClasspath"; //$NON-NLS-1$ 750 /** 751 * Possible configurable option ID. 752 * @see #getDefaultOptions() 753 * @since 3.0 754 */ 755 public static final String JavaDoc CORE_INCOMPATIBLE_JDK_LEVEL = PLUGIN_ID + ".incompatibleJDKLevel"; //$NON-NLS-1$ 756 /** 757 * Possible configurable option ID. 758 * @see #getDefaultOptions() 759 * @since 2.0 760 */ 761 public static final String JavaDoc CORE_JAVA_BUILD_INVALID_CLASSPATH = PLUGIN_ID + ".builder.invalidClasspath"; //$NON-NLS-1$ 762 /** 763 * Possible configurable option ID. 764 * @see #getDefaultOptions() 765 * @since 2.0 766 */ 767 public static final String JavaDoc CORE_ENCODING = PLUGIN_ID + ".encoding"; //$NON-NLS-1$ 768 /** 769 * Possible configurable option ID. 770 * @see #getDefaultOptions() 771 * @since 2.1 772 */ 773 public static final String JavaDoc CORE_ENABLE_CLASSPATH_EXCLUSION_PATTERNS = PLUGIN_ID + ".classpath.exclusionPatterns"; //$NON-NLS-1$ 774 /** 775 * Possible configurable option ID. 776 * @see #getDefaultOptions() 777 * @since 2.1 778 */ 779 public static final String JavaDoc CORE_ENABLE_CLASSPATH_MULTIPLE_OUTPUT_LOCATIONS = PLUGIN_ID + ".classpath.multipleOutputLocations"; //$NON-NLS-1$ 780 /** 781 * Default task tag 782 * @deprecated Use {@link #DEFAULT_TASK_TAGS} instead 783 * @since 2.1 784 */ 785 public static final String JavaDoc DEFAULT_TASK_TAG = "TODO"; //$NON-NLS-1$ 786 /** 787 * Default task priority 788 * @deprecated Use {@link #DEFAULT_TASK_PRIORITIES} instead 789 * @since 2.1 790 */ 791 public static final String JavaDoc DEFAULT_TASK_PRIORITY = "NORMAL"; //$NON-NLS-1$ 792 /** 793 * Default task tag 794 * @since 3.0 795 */ 796 public static final String JavaDoc DEFAULT_TASK_TAGS = "TODO,FIXME,XXX"; //$NON-NLS-1$ 797 /** 798 * Default task priority 799 * @since 3.0 800 */ 801 public static final String JavaDoc DEFAULT_TASK_PRIORITIES = "NORMAL,HIGH,NORMAL"; //$NON-NLS-1$ 802 /** 803 * Possible configurable option ID. 804 * @see #getDefaultOptions() 805 * @since 2.0 806 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_BRACE_POSITION_FOR_ANONYMOUS_TYPE_DECLARATION}, 807 * {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_BRACE_POSITION_FOR_BLOCK} , 808 * {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_BRACE_POSITION_FOR_CONSTRUCTOR_DECLARATION}, 809 * {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_BRACE_POSITION_FOR_METHOD_DECLARATION}, 810 * {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_BRACE_POSITION_FOR_SWITCH}, 811 * {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_BRACE_POSITION_FOR_TYPE_DECLARATION} instead 812 */ 813 public static final String JavaDoc FORMATTER_NEWLINE_OPENING_BRACE = PLUGIN_ID + ".formatter.newline.openingBrace"; //$NON-NLS-1$ 814 /** 815 * Possible configurable option ID. 816 * @see #getDefaultOptions() 817 * @since 2.0 818 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_INSERT_NEW_LINE_BEFORE_CATCH_IN_TRY_STATEMENT}, 819 * {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_INSERT_NEW_LINE_BEFORE_ELSE_IN_IF_STATEMENT}, 820 * {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_INSERT_NEW_LINE_BEFORE_FINALLY_IN_TRY_STATEMENT}, 821 * {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_INSERT_NEW_LINE_BEFORE_WHILE_IN_DO_STATEMENT} instead. 822 */ 823 public static final String JavaDoc FORMATTER_NEWLINE_CONTROL = PLUGIN_ID + ".formatter.newline.controlStatement"; //$NON-NLS-1$ 824 /** 825 * Possible configurable option ID. 826 * @see #getDefaultOptions() 827 * @since 2.0 828 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_COMPACT_ELSE_IF} instead 829 */ 830 public static final String JavaDoc FORMATTER_NEWLINE_ELSE_IF = PLUGIN_ID + ".formatter.newline.elseIf"; //$NON-NLS-1$ 831 /** 832 * Possible configurable option ID. 833 * @see #getDefaultOptions() 834 * @since 2.0 835 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_INSERT_NEW_LINE_IN_EMPTY_BLOCK} instead 836 */ 837 public static final String JavaDoc FORMATTER_NEWLINE_EMPTY_BLOCK = PLUGIN_ID + ".formatter.newline.emptyBlock"; //$NON-NLS-1$ 838 /** 839 * Possible configurable option ID. 840 * @see #getDefaultOptions() 841 * @since 2.0 842 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_NUMBER_OF_EMPTY_LINES_TO_PRESERVE} instead 843 */ 844 public static final String JavaDoc FORMATTER_CLEAR_BLANK_LINES = PLUGIN_ID + ".formatter.newline.clearAll"; //$NON-NLS-1$ 845 /** 846 * Possible configurable option ID. 847 * @see #getDefaultOptions() 848 * @since 2.0 849 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_LINE_SPLIT} instead 850 */ 851 public static final String JavaDoc FORMATTER_LINE_SPLIT = PLUGIN_ID + ".formatter.lineSplit"; //$NON-NLS-1$ 852 /** 853 * Possible configurable option ID. 854 * @see #getDefaultOptions() 855 * @since 2.0 856 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_INSERT_SPACE_BEFORE_ASSIGNMENT_OPERATOR} instead 857 */ 858 public static final String JavaDoc FORMATTER_COMPACT_ASSIGNMENT = PLUGIN_ID + ".formatter.style.assignment"; //$NON-NLS-1$ 859 /** 860 * Possible configurable option ID. 861 * @see #getDefaultOptions() 862 * @since 2.0 863 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_TAB_CHAR}} instead 864 */ 865 public static final String JavaDoc FORMATTER_TAB_CHAR = PLUGIN_ID + ".formatter.tabulation.char"; //$NON-NLS-1$ 866 /** 867 * Possible configurable option ID. 868 * @see #getDefaultOptions() 869 * @since 2.0 870 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_TAB_SIZE} instead 871 */ 872 public static final String JavaDoc FORMATTER_TAB_SIZE = PLUGIN_ID + ".formatter.tabulation.size"; //$NON-NLS-1$ 873 /** 874 * Possible configurable option ID 875 * @see #getDefaultOptions() 876 * @since 2.1 877 * @deprecated Use {@link org.eclipse.jdt.core.formatter.DefaultCodeFormatterConstants#FORMATTER_INSERT_SPACE_AFTER_CLOSING_PAREN_IN_CAST} instead 878 */ 879 public static final String JavaDoc FORMATTER_SPACE_CASTEXPRESSION = PLUGIN_ID + ".formatter.space.castexpression"; //$NON-NLS-1$ 880 /** 881 * Possible configurable option ID. 882 * @see #getDefaultOptions() 883 * @since 2.0 884 */ 885 public static final String JavaDoc CODEASSIST_VISIBILITY_CHECK = PLUGIN_ID + ".codeComplete.visibilityCheck"; //$NON-NLS-1$ 886 /** 887 * Possible configurable option ID. 888 * @see #getDefaultOptions() 889 * @since 3.2 890 */ 891 public static final String JavaDoc CODEASSIST_DEPRECATION_CHECK = PLUGIN_ID + ".codeComplete.deprecationCheck"; //$NON-NLS-1$ 892 /** 893 * Possible configurable option ID. 894 * @see #getDefaultOptions() 895 * @since 3.2 896 */ 897 public static final String JavaDoc CODEASSIST_CAMEL_CASE_MATCH = PLUGIN_ID + ".codeComplete.camelCaseMatch"; //$NON-NLS-1$ 898 /** 899 * Possible configurable option ID. 900 * @see #getDefaultOptions() 901 * @since 2.0 902 */ 903 public static final String JavaDoc CODEASSIST_IMPLICIT_QUALIFICATION = PLUGIN_ID + ".codeComplete.forceImplicitQualification"; //$NON-NLS-1$ 904 /** 905 * Possible configurable option ID. 906 * @see #getDefaultOptions() 907 * @since 2.1 908 */ 909 public static final String JavaDoc CODEASSIST_FIELD_PREFIXES = PLUGIN_ID + ".codeComplete.fieldPrefixes"; //$NON-NLS-1$ 910 /** 911 * Possible configurable option ID. 912 * @see #getDefaultOptions() 913 * @since 2.1 914 */ 915 public static final String JavaDoc CODEASSIST_STATIC_FIELD_PREFIXES = PLUGIN_ID + ".codeComplete.staticFieldPrefixes"; //$NON-NLS-1$ 916 /** 917 * Possible configurable option ID. 918 * @see #getDefaultOptions() 919 * @since 2.1 920 */ 921 public static final String JavaDoc CODEASSIST_LOCAL_PREFIXES = PLUGIN_ID + ".codeComplete.localPrefixes"; //$NON-NLS-1$ 922 /** 923 * Possible configurable option ID. 924 * @see #getDefaultOptions() 925 * @since 2.1 926 */ 927 public static final String JavaDoc CODEASSIST_ARGUMENT_PREFIXES = PLUGIN_ID + ".codeComplete.argumentPrefixes"; //$NON-NLS-1$ 928 /** 929 * Possible configurable option ID. 930 * @see #getDefaultOptions() 931 * @since 2.1 932 */ 933 public static final String JavaDoc CODEASSIST_FIELD_SUFFIXES = PLUGIN_ID + ".codeComplete.fieldSuffixes"; //$NON-NLS-1$ 934 /** 935 * Possible configurable option ID. 936 * @see #getDefaultOptions() 937 * @since 2.1 938 */ 939 public static final String JavaDoc CODEASSIST_STATIC_FIELD_SUFFIXES = PLUGIN_ID + ".codeComplete.staticFieldSuffixes"; //$NON-NLS-1$ 940 /** 941 * Possible configurable option ID. 942 * @see #getDefaultOptions() 943 * @since 2.1 944 */ 945 public static final String JavaDoc CODEASSIST_LOCAL_SUFFIXES = PLUGIN_ID + ".codeComplete.localSuffixes"; //$NON-NLS-1$ 946 /** 947 * Possible configurable option ID. 948 * @see #getDefaultOptions() 949 * @since 2.1 950 */ 951 public static final String JavaDoc CODEASSIST_ARGUMENT_SUFFIXES = PLUGIN_ID + ".codeComplete.argumentSuffixes"; //$NON-NLS-1$ 952 /** 953 * Possible configurable option ID. 954 * @see #getDefaultOptions() 955 * @since 3.1 956 */ 957 public static final String JavaDoc CODEASSIST_FORBIDDEN_REFERENCE_CHECK= PLUGIN_ID + ".codeComplete.forbiddenReferenceCheck"; //$NON-NLS-1$ 958 /** 959 * Possible configurable option ID. 960 * @see #getDefaultOptions() 961 * @since 3.1 962 */ 963 public static final String JavaDoc CODEASSIST_DISCOURAGED_REFERENCE_CHECK= PLUGIN_ID + ".codeComplete.discouragedReferenceCheck"; //$NON-NLS-1$ 964 /** 965 * Possible configurable option ID. 966 * @see #getDefaultOptions() 967 * @since 3.3 968 */ 969 public static final String JavaDoc CODEASSIST_SUGGEST_STATIC_IMPORTS= PLUGIN_ID + ".codeComplete.suggestStaticImports"; //$NON-NLS-1$ 970 /** 971 * Possible configurable option ID. 972 * @see #getDefaultOptions() 973 * @since 3.2 974 */ 975 public static final String JavaDoc TIMEOUT_FOR_PARAMETER_NAME_FROM_ATTACHED_JAVADOC = PLUGIN_ID + ".timeoutForParameterNameFromAttachedJavadoc"; //$NON-NLS-1$ 976 977 /** 978 * Possible configurable option value. 979 * @see #getDefaultOptions() 980 */ 981 public static final String JavaDoc GENERATE = "generate"; //$NON-NLS-1$ 982 /** 983 * Possible configurable option value. 984 * @see #getDefaultOptions() 985 */ 986 public static final String JavaDoc DO_NOT_GENERATE = "do not generate"; //$NON-NLS-1$ 987 /** 988 * Possible configurable option value. 989 * @see #getDefaultOptions() 990 */ 991 public static final String JavaDoc PRESERVE = "preserve"; //$NON-NLS-1$ 992 /** 993 * Possible configurable option value. 994 * @see #getDefaultOptions() 995 */ 996 public static final String JavaDoc OPTIMIZE_OUT = "optimize out"; //$NON-NLS-1$ 997 /** 998 * Possible configurable option value. 999 * @see #getDefaultOptions() 1000 */ 1001 public static final String JavaDoc VERSION_1_1 = "1.1"; //$NON-NLS-1$ 1002 /** 1003 * Possible configurable option value. 1004 * @see #getDefaultOptions() 1005 */ 1006 public static final String JavaDoc VERSION_1_2 = "1.2"; //$NON-NLS-1$ 1007 /** 1008 * Possible configurable option value. 1009 * @see #getDefaultOptions() 1010 * @since 2.0 1011 */ 1012 public static final String JavaDoc VERSION_1_3 = "1.3"; //$NON-NLS-1$ 1013 /** 1014 * Possible configurable option value. 1015 * @see #getDefaultOptions() 1016 * @since 2.0 1017 */ 1018 public static final String JavaDoc VERSION_1_4 = "1.4"; //$NON-NLS-1$ 1019 /** 1020 * Possible configurable option value. 1021 * @see #getDefaultOptions() 1022 * @since 3.0 1023 */ 1024 public static final String JavaDoc VERSION_1_5 = "1.5"; //$NON-NLS-1$ 1025 /** 1026 * Possible configurable option value. 1027 * @see #getDefaultOptions() 1028 * @since 3.2 1029 */ 1030 public static final String JavaDoc VERSION_1_6 = "1.6"; //$NON-NLS-1$ 1031 /** 1032 * Possible configurable option value. 1033 * @see #getDefaultOptions() 1034 * @since 3.3 1035 */ 1036 public static final String JavaDoc VERSION_1_7 = "1.7"; //$NON-NLS-1$ 1037 /** 1038 * Possible configurable option value. 1039 * @see #getDefaultOptions() 1040 * @since 2.0 1041 */ 1042 public static final String JavaDoc ABORT = "abort"; //$NON-NLS-1$ 1043 /** 1044 * Possible configurable option value. 1045 * @see #getDefaultOptions() 1046 */ 1047 public static final String JavaDoc ERROR = "error"; //$NON-NLS-1$ 1048 /** 1049 * Possible configurable option value. 1050 * @see #getDefaultOptions() 1051 */ 1052 public static final String JavaDoc WARNING = "warning"; //$NON-NLS-1$ 1053 /** 1054 * Possible configurable option value. 1055 * @see #getDefaultOptions() 1056 */ 1057 public static final String JavaDoc IGNORE = "ignore"; //$NON-NLS-1$ 1058 /** 1059 * Possible configurable option value. 1060 * @see #getDefaultOptions() 1061 */ 1062 public static final String JavaDoc COMPUTE = "compute"; //$NON-NLS-1$ 1063 /** 1064 * Possible configurable option value. 1065 * @see #getDefaultOptions() 1066 * @since 2.0 1067 */ 1068 public static final String JavaDoc INSERT = "insert"; //$NON-NLS-1$ 1069 /** 1070 * Possible configurable option value. 1071 * @see #getDefaultOptions() 1072 * @since 2.0 1073 */ 1074 public static final String JavaDoc DO_NOT_INSERT = "do not insert"; //$NON-NLS-1$ 1075 /** 1076 * Possible configurable option value. 1077 * @see #getDefaultOptions() 1078 * @since 2.0 1079 */ 1080 public static final String JavaDoc PRESERVE_ONE = "preserve one"; //$NON-NLS-1$ 1081 /** 1082 * Possible configurable option value. 1083 * @see #getDefaultOptions() 1084 * @since 2.0 1085 */ 1086 public static final String JavaDoc CLEAR_ALL = "clear all"; //$NON-NLS-1$ 1087 /** 1088 * Possible configurable option value. 1089 * @see #getDefaultOptions() 1090 * @since 2.0 1091 */ 1092 public static final String JavaDoc NORMAL = "normal"; //$NON-NLS-1$ 1093 /** 1094 * Possible configurable option value. 1095 * @see #getDefaultOptions() 1096 * @since 2.0 1097 */ 1098 public static final String JavaDoc COMPACT = "compact"; //$NON-NLS-1$ 1099 /** 1100 * Possible configurable option value. 1101 * @see #getDefaultOptions() 1102 * @since 2.0 1103 */ 1104 public static final String JavaDoc TAB = "tab"; //$NON-NLS-1$ 1105 /** 1106 * Possible configurable option value. 1107 * @see #getDefaultOptions() 1108 * @since 2.0 1109 */ 1110 public static final String JavaDoc SPACE = "space"; //$NON-NLS-1$ 1111 /** 1112 * Possible configurable option value. 1113 * @see #getDefaultOptions() 1114 * @since 2.0 1115 */ 1116 public static final String JavaDoc ENABLED = "enabled"; //$NON-NLS-1$ 1117 /** 1118 * Possible configurable option value. 1119 * @see #getDefaultOptions() 1120 * @since 2.0 1121 */ 1122 public static final String JavaDoc DISABLED = "disabled"; //$NON-NLS-1$ 1123 /** 1124 * Possible configurable option value. 1125 * @see #getDefaultOptions() 1126 * @since 2.1 1127 */ 1128 public static final String JavaDoc CLEAN = "clean"; //$NON-NLS-1$ 1129 /** 1130 * Possible configurable option value. 1131 * @see #getDefaultOptions() 1132 * @since 3.0 1133 */ 1134 public static final String JavaDoc PUBLIC = "public"; //$NON-NLS-1$ 1135 /** 1136 * Possible configurable option value. 1137 * @see #getDefaultOptions() 1138 * @since 3.0 1139 */ 1140 public static final String JavaDoc PROTECTED = "protected"; //$NON-NLS-1$ 1141 /** 1142 * Possible configurable option value. 1143 * @see #getDefaultOptions() 1144 * @since 3.0 1145 */ 1146 public static final String JavaDoc DEFAULT = "default"; //$NON-NLS-1$ 1147 /** 1148 * Possible configurable option value. 1149 * @see #getDefaultOptions() 1150 * @since 3.0 1151 */ 1152 public static final String JavaDoc PRIVATE = "private"; //$NON-NLS-1$ 1153 /** 1154 * Possible configurable option value. 1155 * @see #getDefaultOptions() 1156 * @since 3.1 1157 */ 1158 public static final String JavaDoc NEVER = "never"; //$NON-NLS-1$ 1159 1160 /** 1161 * Value of the content-type for Java source files. Use this value to retrieve the Java content type 1162 * from the content type manager, and to add new Java-like extensions to this content type. 1163 * 1164 * @see org.eclipse.core.runtime.content.IContentTypeManager#getContentType(String) 1165 * @see #getJavaLikeExtensions() 1166 * @since 3.2 1167 */ 1168 public static final String JavaDoc JAVA_SOURCE_CONTENT_TYPE = JavaCore.PLUGIN_ID+".javaSource" ; //$NON-NLS-1$ 1169 1170 /** 1171 * Creates the Java core plug-in. 1172 * <p> 1173 * The plug-in instance is created automatically by the 1174 * Eclipse platform. Clients must not call. 1175 * </p> 1176 * 1177 * @since 3.0 1178 */ 1179 public JavaCore() { 1180 super(); 1181 JAVA_CORE_PLUGIN = this; 1182 } 1183 1184 /** 1185 * Adds the given listener for changes to Java elements. 1186 * Has no effect if an identical listener is already registered. 1187 * 1188 * This listener will only be notified during the POST_CHANGE resource change notification 1189 * and any reconcile operation (POST_RECONCILE). 1190 * For finer control of the notification, use <code>addElementChangedListener(IElementChangedListener,int)</code>, 1191 * which allows to specify a different eventMask. 1192 * 1193 * @param listener the listener 1194 * @see ElementChangedEvent 1195 */ 1196 public static void addElementChangedListener(IElementChangedListener listener) { 1197 addElementChangedListener(listener, ElementChangedEvent.POST_CHANGE | ElementChangedEvent.POST_RECONCILE); 1198 } 1199 1200 /** 1201 * Adds the given listener for changes to Java elements. 1202 * Has no effect if an identical listener is already registered. 1203 * After completion of this method, the given listener will be registered for exactly 1204 * the specified events. If they were previously registered for other events, they 1205 * will be deregistered. 1206 * <p> 1207 * Once registered, a listener starts receiving notification of changes to 1208 * java elements in the model. The listener continues to receive 1209 * notifications until it is replaced or removed. 1210 * </p> 1211 * <p> 1212 * Listeners can listen for several types of event as defined in <code>ElementChangeEvent</code>. 1213 * Clients are free to register for any number of event types however if they register 1214 * for more than one, it is their responsibility to ensure they correctly handle the 1215 * case where the same java element change shows up in multiple notifications. 1216 * Clients are guaranteed to receive only the events for which they are registered. 1217 * </p> 1218 * 1219 * @param listener the listener 1220 * @param eventMask the bit-wise OR of all event types of interest to the listener 1221 * @see IElementChangedListener 1222 * @see ElementChangedEvent 1223 * @see #removeElementChangedListener(IElementChangedListener) 1224 * @since 2.0 1225 */ 1226 public static void addElementChangedListener(IElementChangedListener listener, int eventMask) { 1227 JavaModelManager.getJavaModelManager().deltaState.addElementChangedListener(listener, eventMask); 1228 } 1229 1230 /** 1231 * Configures the given marker attribute map for the given Java element. 1232 * Used for markers, which denote a Java element rather than a resource. 1233 * 1234 * @param attributes the mutable marker attribute map (key type: <code>String</code>, 1235 * value type: <code>String</code>) 1236 * @param element the Java element for which the marker needs to be configured 1237 */ 1238 public static void addJavaElementMarkerAttributes( 1239 Map JavaDoc attributes, 1240 IJavaElement element) { 1241 if (element instanceof IMember) 1242 element = ((IMember) element).getClassFile(); 1243 if (attributes != null && element != null) 1244 attributes.put(ATT_HANDLE_ID, element.getHandleIdentifier()); 1245 } 1246 1247 private static void addNonJavaResources(Object JavaDoc[] nonJavaResources, 1248 IContainer container, 1249 int rootPathSegmentCounts, 1250 ArrayList JavaDoc collector) { 1251 for (int i = 0, max = nonJavaResources.length; i < max; i++) { 1252 Object JavaDoc nonJavaResource = nonJavaResources[i]; 1253 if (nonJavaResource instanceof IFile) { 1254 IFile file = (IFile) nonJavaResource; 1255 IPath path = file.getFullPath().removeFirstSegments(rootPathSegmentCounts); 1256 IResource member = container.findMember(path); 1257 if (member != null && member.exists()) { 1258 collector.add(member); 1259 } 1260 } else if (nonJavaResource instanceof IFolder) { 1261 IFolder folder = (IFolder) nonJavaResource; 1262 IResource[] members = null; 1263 try { 1264 members = folder.members(); 1265 } catch (CoreException e) { 1266 // ignore 1267 } 1268 if (members != null) { 1269 addNonJavaResources(members, container, rootPathSegmentCounts, collector); 1270 } 1271 } 1272 } 1273 } 1274 1275 /** 1276 * Adds the given listener for POST_CHANGE resource change events to the Java core. 1277 * The listener is guaranteed to be notified of the POST_CHANGE resource change event before 1278 * the Java core starts processing the resource change event itself. 1279 * <p> 1280 * Has no effect if an identical listener is already registered. 1281 * </p> 1282 * 1283 * @param listener the listener 1284 * @see #removePreProcessingResourceChangedListener(IResourceChangeListener) 1285 * @since 3.0 1286 * @deprecated use addPreProcessingResourceChangedListener(listener, IResourceChangeEvent.POST_CHANGE) instead 1287 */ 1288 public static void addPreProcessingResourceChangedListener(IResourceChangeListener listener) { 1289 addPreProcessingResourceChangedListener(listener, IResourceChangeEvent.POST_CHANGE); 1290 } 1291 1292 /** 1293 * Adds the given listener for resource change events of the given types to the Java core. 1294 * The listener is guaranteed to be notified of the resource change event before 1295 * the Java core starts processing the resource change event itself. 1296 * <p> 1297 * If an identical listener is already registered, the given event types are added to the event types 1298 * of interest to the listener. 1299 * </p> 1300 * <p> 1301 * Supported event types are: 1302 * <ul> 1303 * <li>{@link IResourceChangeEvent#PRE_BUILD}</li> 1304 * <li>{@link IResourceChangeEvent#POST_BUILD}</li> 1305 * <li>{@link IResourceChangeEvent#POST_CHANGE}</li> 1306 * <li>{@link IResourceChangeEvent#PRE_DELETE}</li> 1307 * <li>{@link IResourceChangeEvent#PRE_CLOSE}</li> 1308 * </ul> 1309 * This list may increase in the future. 1310 * </p> 1311 * 1312 * @param listener the listener 1313 * @param eventMask the bit-wise OR of all event types of interest to the 1314 * listener 1315 * @see #removePreProcessingResourceChangedListener(IResourceChangeListener) 1316 * @see IResourceChangeEvent 1317 * @since 3.2 1318 */ 1319 public static void addPreProcessingResourceChangedListener(IResourceChangeListener listener, int eventMask) { 1320 JavaModelManager.getJavaModelManager().deltaState.addPreResourceChangedListener(listener, eventMask); 1321 } 1322 1323 /** 1324 * Configures the given marker for the given Java element. 1325 * Used for markers, which denote a Java element rather than a resource. 1326 * 1327 * @param marker the marker to be configured 1328 * @param element the Java element for which the marker needs to be configured 1329 * @exception CoreException if the <code>IMarker.setAttribute</code> on the marker fails 1330 */ 1331 public void configureJavaElementMarker(IMarker marker, IJavaElement element) 1332 throws CoreException { 1333 if (element instanceof IMember) 1334 element = ((IMember) element).getClassFile(); 1335 if (marker != null && element != null) 1336 marker.setAttribute(ATT_HANDLE_ID, element.getHandleIdentifier()); 1337 } 1338 1339 /** 1340 * Returns the Java model element corresponding to the given handle identifier 1341 * generated by <code>IJavaElement.getHandleIdentifier()</code>, or 1342 * <code>null</code> if unable to create the associated element. 1343 * 1344 * @param handleIdentifier the given handle identifier 1345 * @return the Java element corresponding to the handle identifier 1346 */ 1347 public static IJavaElement create(String JavaDoc handleIdentifier) { 1348 return create(handleIdentifier, DefaultWorkingCopyOwner.PRIMARY); 1349 } 1350 1351 /** 1352 * Returns the Java model element corresponding to the given handle identifier 1353 * generated by <code>IJavaElement.getHandleIdentifier()</code>, or 1354 * <code>null</code> if unable to create the associated element. 1355 * If the returned Java element is an <code>ICompilationUnit</code>, its owner 1356 * is the given owner if such a working copy exists, otherwise the compilation unit 1357 * is a primary compilation unit. 1358 * 1359 * @param handleIdentifier the given handle identifier 1360 * @param owner the owner of the returned compilation unit, ignored if the returned 1361 * element is not a compilation unit 1362 * @return the Java element corresponding to the handle identifier 1363 * @since 3.0 1364 */ 1365 public static IJavaElement create(String JavaDoc handleIdentifier, WorkingCopyOwner owner) { 1366 if (handleIdentifier == null) { 1367 return null; 1368 } 1369 MementoTokenizer memento = new MementoTokenizer(handleIdentifier); 1370 JavaModel model = JavaModelManager.getJavaModelManager().getJavaModel(); 1371 return model.getHandleFromMemento(memento, owner); 1372 } 1373 1374 /** 1375 * Returns the Java element corresponding to the given file, or 1376 * <code>null</code> if unable to associate the given file 1377 * with a Java element. 1378 * 1379 * <p>The file must be one of:<ul> 1380 * <li>a file with one of the {@link JavaCore#getJavaLikeExtensions() 1381 * Java-like extensions} - the element returned is the corresponding <code>ICompilationUnit</code></li> 1382 * <li>a <code>.class</code> file - the element returned is the corresponding <code>IClassFile</code></li> 1383 * <li>a <code>.jar</code> file - the element returned is the corresponding <code>IPackageFragmentRoot</code></li> 1384 * </ul> 1385 * <p> 1386 * Creating a Java element has the side effect of creating and opening all of the 1387 * element's parents if they are not yet open. 1388 * 1389 * @param file the given file 1390 * @return the Java element corresponding to the given file, or 1391 * <code>null</code> if unable to associate the given file 1392 * with a Java element 1393 */ 1394 public static IJavaElement create(IFile file) { 1395 return JavaModelManager.create(file, null/*unknown java project*/); 1396 } 1397 /** 1398 * Returns the package fragment or package fragment root corresponding to the given folder, or 1399 * <code>null</code> if unable to associate the given folder with a Java element. 1400 * <p> 1401 * Note that a package fragment root is returned rather than a default package. 1402 * <p> 1403 * Creating a Java element has the side effect of creating and opening all of the 1404 * element's parents if they are not yet open. 1405 * 1406 * @param folder the given folder 1407 * @return the package fragment or package fragment root corresponding to the given folder, or 1408 * <code>null</code> if unable to associate the given folder with a Java element 1409 */ 1410 public static IJavaElement create(IFolder folder) { 1411 return JavaModelManager.create(folder, null/*unknown java project*/); 1412 } 1413 /** 1414 * Returns the Java project corresponding to the given project. 1415 * <p> 1416 * Creating a Java Project has the side effect of creating and opening all of th最后更新:2017-04-03 12:55:09
上一篇:
C# 系统应用之TreeView控件 (一).显示树状磁盘文件目录及加载图标
下一篇:
android顶部导航条