2 * Copyright (c) 2003-2004 Christopher Lenz and others.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Common Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/cpl-v10.html
9 * Christopher Lenz - initial API and implementation
11 * $Id: DefaultProblem.java,v 1.2 2006-10-21 23:13:43 pombredanne Exp $
14 package net.sourceforge.phpeclipse.xml.core.internal.parser;
16 import net.sourceforge.phpeclipse.xml.core.parser.IProblem;
18 public class DefaultProblem implements IProblem {
20 // Instance Variables ------------------------------------------------------
22 private String message;
24 private int sourceStart;
26 private int sourceEnd;
28 private int sourceLineNumber;
30 private boolean error;
32 // Constructors ------------------------------------------------------------
34 public DefaultProblem(String message, int sourceStart, int sourceEnd,
35 int sourceLineNumber, boolean error) {
36 this.message = message;
37 this.sourceStart = sourceStart;
38 this.sourceEnd = sourceEnd;
39 this.sourceLineNumber = sourceLineNumber;
43 // IProblem Implementation -------------------------------------------------
46 * @see IProblem#getMessage()
48 public String getMessage() {
53 * @see IProblem#getSourceStart()
55 public int getSourceStart() {
60 * @see IProblem#getSourceEnd()
62 public int getSourceEnd() {
67 * @see IProblem#getSourceLineNumber()
69 public int getSourceLineNumber() {
70 return sourceLineNumber;
74 * @see IProblem#isError()
76 public boolean isError() {
81 * @see IProblem#isWarning()
83 public boolean isWarning() {