Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.1.0)

E17493-02

oracle.jdevimpl.audit.core
Class DefaultAuditTaskContext

java.lang.Object
  extended by oracle.jdevimpl.audit.core.DefaultAuditTaskContext
All Implemented Interfaces:
AuditTaskContext

public class DefaultAuditTaskContext
extends java.lang.Object
implements AuditTaskContext


Constructor Summary
DefaultAuditTaskContext(DefaultAuditor auditor, Analyzer analyzer, ModelFactory factory, java.util.concurrent.BlockingQueue<Violation> queue)
           
 
Method Summary
<T extends ModelAdapter>
ModelAdapter
getModelAdapter(java.lang.Class<T> type, java.net.URL url, Project project, Workspace workspace)
          Gets the adapter for the model corresponding to a workspace, project, and url.
 boolean isCancelled()
          Gets whether the invoking audit has been cancelled.
 ViolationReport report(Rule rule, Location location)
          Reports a rule violation for a construct.
 ViolationReport report(Rule rule, ModelAdapter model, java.lang.Object construct)
          Reports a rule violation for a construct.
 void taskCompleted()
          Reports that this task has completed or cancelled.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultAuditTaskContext

public DefaultAuditTaskContext(DefaultAuditor auditor,
                               Analyzer analyzer,
                               ModelFactory factory,
                               java.util.concurrent.BlockingQueue<Violation> queue)
Method Detail

isCancelled

public boolean isCancelled()
Description copied from interface: AuditTaskContext
Gets whether the invoking audit has been cancelled.

Specified by:
isCancelled in interface AuditTaskContext

getModelAdapter

public <T extends ModelAdapter> ModelAdapter getModelAdapter(java.lang.Class<T> type,
                                                             java.net.URL url,
                                                             Project project,
                                                             Workspace workspace)
Description copied from interface: AuditTaskContext
Gets the adapter for the model corresponding to a workspace, project, and url. This method provides the argument required to specify the location of a violation.

Specified by:
getModelAdapter in interface AuditTaskContext

report

public ViolationReport report(Rule rule,
                              Location location)
Description copied from interface: AuditTaskContext
Reports a rule violation for a construct. report returns a ViolationReport which allows parameters and other attributes to be added to the violation. See the class overview for more information.

Specified by:
report in interface AuditTaskContext
Parameters:
rule - The rule violated.
location - The Location of the the violating construct.

report

public ViolationReport report(Rule rule,
                              ModelAdapter model,
                              java.lang.Object construct)
Description copied from interface: AuditTaskContext
Reports a rule violation for a construct. report returns a ViolationReport which allows parameters and other attributes to be added to the violation. See AuditTaskContext.getModelAdapter(Class,java.net.URL,oracle.ide.model.Project,oracle.ide.model.Workspace), and Location.getModel() to obtain a model.

See the class overview for more information.

Specified by:
report in interface AuditTaskContext
Parameters:
rule - The rule violated.
model - The model containing the violationg construct.
construct - The violating construct.

taskCompleted

public void taskCompleted()
Description copied from interface: AuditTaskContext
Reports that this task has completed or cancelled.

Specified by:
taskCompleted in interface AuditTaskContext

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.1.0)

E17493-02

Copyright © 1997, 2011, Oracle. All rights reserved.