KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > jdt > internal > compiler > apt > dispatch > AptProblem


1 /*******************************************************************************
2  * Copyright (c) 2001, 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  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.jdt.internal.compiler.apt.dispatch;
12
13 import org.eclipse.jdt.internal.compiler.impl.ReferenceContext;
14 import org.eclipse.jdt.internal.compiler.problem.DefaultProblem;
15
16 public class AptProblem extends DefaultProblem {
17     
18     // The batch compiler does not depend on org.eclipse.jdt.apt.pluggable.core; this
19
// is just an arbitrary string to it, namespace notwithstanding. However, the IDE
20
// cares about the fact that this string is registered as a marker ID by the
21
// org.eclipse.jdt.apt.pluggable.core plug-in.
22
private static final String JavaDoc MARKER_ID = "org.eclipse.jdt.apt.pluggable.core.compileProblem"; //$NON-NLS-1$
23

24     /** May be null, if it was not possible to identify problem context */
25     public final ReferenceContext _referenceContext;
26     
27     public AptProblem(
28             ReferenceContext referenceContext,
29             char[] originatingFileName,
30             String JavaDoc message,
31             int id,
32             String JavaDoc[] stringArguments,
33             int severity,
34             int startPosition,
35             int endPosition,
36             int line,
37             int column)
38     {
39         super(originatingFileName,
40             message,
41             id,
42             stringArguments,
43             severity,
44             startPosition,
45             endPosition,
46             line,
47             column);
48         _referenceContext = referenceContext;
49     }
50     
51     @Override JavaDoc
52     public int getCategoryID() {
53         return CAT_UNSPECIFIED;
54     }
55
56     @Override JavaDoc
57     public String JavaDoc getMarkerType() {
58         return MARKER_ID;
59     }
60 }
61
Popular Tags