|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.sonar.batch.DefaultDecoratorContext
public class DefaultDecoratorContext
| Constructor Summary | |
|---|---|
DefaultDecoratorContext(Resource resource,
SonarIndex index,
List<DecoratorContext> childrenContexts)
|
|
| Method Summary | ||
|---|---|---|
Event |
createEvent(String name,
String description,
String category,
Date date)
Creates an event for a given date |
|
void |
deleteEvent(Event event)
Deletes an event |
|
List<DecoratorContext> |
getChildren()
Child contexts are read only |
|
Collection<Measure> |
getChildrenMeasures(MeasuresFilter filter)
Never return null. |
|
Collection<Measure> |
getChildrenMeasures(Metric metric)
|
|
Set<Dependency> |
getDependencies()
|
|
List<Event> |
getEvents()
|
|
Collection<Dependency> |
getIncomingDependencies()
|
|
Measure |
getMeasure(Metric metric)
Find a measure for the resource |
|
|
getMeasures(MeasuresFilter<M> filter)
Never return null. |
|
Collection<Dependency> |
getOutgoingDependencies()
|
|
Project |
getProject()
|
|
Resource |
getResource()
|
|
List<Violation> |
getViolations()
Returns all the active (= non switched-off) violations found on the current resource. |
|
List<Violation> |
getViolations(ViolationQuery violationQuery)
Returns the violations that match the ViolationQuery parameters. |
|
Dependency |
saveDependency(Dependency dependency)
|
|
DecoratorContext |
saveMeasure(Measure measure)
Add a measure on the current resource. |
|
DecoratorContext |
saveMeasure(Metric metric,
Double value)
Add a measure on the current resource. |
|
DefaultDecoratorContext |
saveViolation(Violation violation)
Save a coding rule violation. |
|
DefaultDecoratorContext |
saveViolation(Violation violation,
boolean force)
Save a coding rule violation. |
|
DefaultDecoratorContext |
setReadOnly(boolean b)
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultDecoratorContext(Resource resource,
SonarIndex index,
List<DecoratorContext> childrenContexts)
| Method Detail |
|---|
public DefaultDecoratorContext setReadOnly(boolean b)
public Project getProject()
getProject in interface DecoratorContextpublic List<DecoratorContext> getChildren()
DecoratorContext
getChildren in interface DecoratorContextpublic <M> M getMeasures(MeasuresFilter<M> filter)
DecoratorContext
getMeasures in interface DecoratorContextpublic Measure getMeasure(Metric metric)
DecoratorContext
getMeasure in interface DecoratorContextpublic Collection<Measure> getChildrenMeasures(MeasuresFilter filter)
DecoratorContext
getChildrenMeasures in interface DecoratorContextpublic Collection<Measure> getChildrenMeasures(Metric metric)
getChildrenMeasures in interface DecoratorContextpublic Resource getResource()
getResource in interface DecoratorContextpublic DecoratorContext saveMeasure(Measure measure)
DecoratorContext
saveMeasure in interface DecoratorContext
public DecoratorContext saveMeasure(Metric metric,
Double value)
DecoratorContext
saveMeasure in interface DecoratorContextpublic List<Violation> getViolations(ViolationQuery violationQuery)
ViolationQuery parameters.
getViolations in interface DecoratorContextviolationQuery - the request parameters specified as a ViolationQuery
public List<Violation> getViolations()
getViolations in interface DecoratorContextpublic Dependency saveDependency(Dependency dependency)
saveDependency in interface DecoratorContextpublic Set<Dependency> getDependencies()
getDependencies in interface DecoratorContextpublic Collection<Dependency> getIncomingDependencies()
getIncomingDependencies in interface DecoratorContextpublic Collection<Dependency> getOutgoingDependencies()
getOutgoingDependencies in interface DecoratorContextpublic List<Event> getEvents()
getEvents in interface DecoratorContext
public Event createEvent(String name,
String description,
String category,
Date date)
DecoratorContext
createEvent in interface DecoratorContextname - the event namedescription - the event descriptioncategory - the event categorydate - the event date
public void deleteEvent(Event event)
DecoratorContext
deleteEvent in interface DecoratorContextevent - the event to delete
public DefaultDecoratorContext saveViolation(Violation violation,
boolean force)
DecoratorContext
saveViolation in interface DecoratorContextforce - allows to force creation of violation even if it was suppressed by ViolationFilterpublic DefaultDecoratorContext saveViolation(Violation violation)
DecoratorContext
saveViolation in interface DecoratorContext
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||