org.openstreetmap.josm.data.osm.visitor.paint
Class AbstractMapRenderer

java.lang.Object
  extended by org.openstreetmap.josm.data.osm.visitor.paint.AbstractMapRenderer
All Implemented Interfaces:
Rendering
Direct Known Subclasses:
StyledMapRenderer, WireframeMapRenderer

public abstract class AbstractMapRenderer
extends java.lang.Object
implements Rendering

Abstract common superclass for Rendering implementations.


Field Summary
protected  java.awt.Graphics2D g
          the graphics context to which the visitor renders OSM objects
protected  boolean isInactiveMode
          if true, the paint visitor shall render OSM objects such that they look inactive.
protected  NavigatableComponent nc
          the map viewport - provides projection and hit detection functionality
 
Constructor Summary
AbstractMapRenderer(java.awt.Graphics2D g, NavigatableComponent nc, boolean isInactiveMode)
          Creates an abstract paint visitor
 
Method Summary
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.openstreetmap.josm.data.osm.visitor.paint.Rendering
render
 

Field Detail

g

protected java.awt.Graphics2D g
the graphics context to which the visitor renders OSM objects


nc

protected NavigatableComponent nc
the map viewport - provides projection and hit detection functionality


isInactiveMode

protected boolean isInactiveMode
if true, the paint visitor shall render OSM objects such that they look inactive. Example: rendering of data in an inactive layer using light gray as color only.

Constructor Detail

AbstractMapRenderer

public AbstractMapRenderer(java.awt.Graphics2D g,
                           NavigatableComponent nc,
                           boolean isInactiveMode)
                    throws java.lang.IllegalArgumentException

Creates an abstract paint visitor

Parameters:
g - the graphics context. Must not be null.
nc - the map viewport. Must not be null.
isInactiveMode - if true, the paint visitor shall render OSM objects such that they look inactive. Example: rendering of data in an inactive layer using light gray as color only.
Throws:
java.lang.IllegalArgumentException - thrown if g is null
java.lang.IllegalArgumentException - thrown if nc is null


JOSM