edu.cmu.sei.aadl.modelsupport.errorreporting
Class MarkerAnalysisErrorReporter

java.lang.Object
  extended by edu.cmu.sei.aadl.modelsupport.errorreporting.AbstractErrorReporter
      extended by edu.cmu.sei.aadl.modelsupport.errorreporting.AbstractAnalysisErrorReporter
          extended by edu.cmu.sei.aadl.modelsupport.errorreporting.MarkerAnalysisErrorReporter
All Implemented Interfaces:
AnalysisErrorReporter, ErrorReporter

public final class MarkerAnalysisErrorReporter
extends AbstractAnalysisErrorReporter

An implementation of edu.cmu.sei.aadl.model.pluginsupport.AnalysisErrorReporter that reports errors as markers on the aaxl object models. Internal errors are logged to the Eclipse "error" view. The reporter is parameterized by the name of the marker type to create.

A marker is created when the maximum number of messages has been exceeded that indicates this fact.

The class defines a nested class edu.cmu.sei.aadl.model.pluginsupport.MarkerAnalysisErrorReporter.Factory that implements a factory.

Author:
aarong

Nested Class Summary
static class MarkerAnalysisErrorReporter.Factory
          Factory for creating Marker error reporters.
 
Field Summary
 
Fields inherited from class edu.cmu.sei.aadl.modelsupport.errorreporting.AbstractAnalysisErrorReporter
resource
 
Constructor Summary
MarkerAnalysisErrorReporter(org.eclipse.emf.ecore.resource.Resource rsrc, org.eclipse.core.resources.IResource irsrc, java.lang.String mType)
          Create a new error reporter that uses the given marker types.
 
Method Summary
protected  void deleteMessagesImpl()
           
protected  void errorImpl(Element where, java.lang.String message, java.lang.String[] attrs, java.lang.Object[] values)
          Actual implementation of the error method.
protected  void infoImpl(Element where, java.lang.String message, java.lang.String[] attrs, java.lang.Object[] values)
          Actual implementation of the info method.
protected  void warningImpl(Element where, java.lang.String message, java.lang.String[] attrs, java.lang.Object[] values)
          Actual implementation of the warning method.
 
Methods inherited from class edu.cmu.sei.aadl.modelsupport.errorreporting.AbstractAnalysisErrorReporter
error, info, warning
 
Methods inherited from class edu.cmu.sei.aadl.modelsupport.errorreporting.AbstractErrorReporter
deleteMessages, getNumErrors, getNumInfos, getNumMessages, getNumWarnings, incError, incInfo, incWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface edu.cmu.sei.aadl.modelsupport.errorreporting.ErrorReporter
deleteMessages, getNumErrors, getNumInfos, getNumMessages, getNumWarnings
 

Constructor Detail

MarkerAnalysisErrorReporter

public MarkerAnalysisErrorReporter(org.eclipse.emf.ecore.resource.Resource rsrc,
                                   org.eclipse.core.resources.IResource irsrc,
                                   java.lang.String mType)
Create a new error reporter that uses the given marker types. Assumes that resource is not null.

Method Detail

errorImpl

protected void errorImpl(Element where,
                         java.lang.String message,
                         java.lang.String[] attrs,
                         java.lang.Object[] values)
Description copied from class: AbstractAnalysisErrorReporter
Actual implementation of the error method. It is guaranteed that

warningImpl

protected void warningImpl(Element where,
                           java.lang.String message,
                           java.lang.String[] attrs,
                           java.lang.Object[] values)
Description copied from class: AbstractAnalysisErrorReporter
Actual implementation of the warning method. It is guaranteed that

infoImpl

protected void infoImpl(Element where,
                        java.lang.String message,
                        java.lang.String[] attrs,
                        java.lang.Object[] values)
Description copied from class: AbstractAnalysisErrorReporter
Actual implementation of the info method. It is guaranteed that

deleteMessagesImpl

protected void deleteMessagesImpl()
Specified by:
deleteMessagesImpl in class AbstractErrorReporter