Class DefaultVectorComplexLegend

java.lang.Object
org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractLegend
org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
org.gvsig.complexlegend.impl.DefaultVectorComplexLegend
All Implemented Interfaces:
Cloneable, VectorComplexLegend, org.gvsig.fmap.mapcontext.rendering.legend.DrawingObservable, org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedLegend, org.gvsig.fmap.mapcontext.rendering.legend.ILegend, org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend, org.gvsig.fmap.mapcontext.rendering.legend.Legend, org.gvsig.tools.lang.Cloneable, org.gvsig.tools.persistence.Persistent

public class DefaultVectorComplexLegend extends org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend implements VectorComplexLegend, org.gvsig.tools.persistence.Persistent
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
     
    static class 
     
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
    static final String
     
    static final String
     

    Fields inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend

    LOG, VECTORIAL_LEGEND_PERSISTENCE_DEFINITION_NAME, zSort

    Fields inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractLegend

    LEGEND_PERSISTENCE_DEFINITION_NAME
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
     
    void
    draw(BufferedImage image, Graphics2D g, org.gvsig.fmap.mapcontext.ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore)
     
    protected void
    draw(BufferedImage image, Graphics2D g, org.gvsig.fmap.mapcontext.ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.fmap.dal.feature.FeatureQuery featureQuery, double dpi)
     
    boolean
     
    org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol
     
     
     
    getLegend(double scale)
     
     
    getLegendsInScale(double scale)
     
    protected String[]
    getRequiredFeatureAttributeNames(org.gvsig.fmap.dal.feature.FeatureStore featureStore)
     
    int
     
    org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol
    getSymbolByFeature(org.gvsig.fmap.dal.feature.Feature feat)
     
    org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol[]
     
     
    boolean
     
    boolean
    isSuitableForShapeType(int shapeType)
     
    boolean
     
    void
    loadFromState(org.gvsig.tools.persistence.PersistentState state)
     
    void
    print(Graphics2D g, org.gvsig.fmap.mapcontext.ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.compat.print.PrintAttributes properties)
     
    void
    print(Graphics2D g, org.gvsig.fmap.mapcontext.ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.fmap.dal.feature.FeatureQuery fquery, org.gvsig.compat.print.PrintAttributes properties)
     
    boolean
     
    void
    saveToState(org.gvsig.tools.persistence.PersistentState state)
     
    void
    setAllowOverlap(boolean allowOverlap)
     
    void
    setDefaultSymbol(org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol s)
     
    void
    setShapeType(int shapeType)
     
    void
    useDefaultSymbol(boolean b)
     

    Methods inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend

    draw, drawFeatures, getZSort, internalDraw, isDrawSymbolInEeachPrimitive, setDrawSymbolInEeachPrimitive, setZSort

    Methods inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractLegend

    addDrawingObserver, addLegendListener, addObserver, beginComplexNotification, cloneLegend, countObservers, deleteDrawingObserver, deleteDrawingObservers, deleteObserver, disableNotifications, enableNotifications, endComplexNotification, fireDefaultSymbolChangedEvent, getListeners, getManager, getSymbolManager, inComplex, isEnabledNotifications, notifyObservers, notifyObservers, removeLegendListener

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.DrawingObservable

    addDrawingObserver, deleteDrawingObserver, deleteDrawingObservers

    Methods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.ILegend

    addLegendListener, cloneLegend, fireDefaultSymbolChangedEvent, getListeners, removeLegendListener

    Methods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend

    draw
  • Field Details

  • Constructor Details

    • DefaultVectorComplexLegend

      public DefaultVectorComplexLegend()
  • Method Details

    • getLegends

      public List<ComplexLegendItem> getLegends()
      Specified by:
      getLegends in interface VectorComplexLegend
    • getEditedLegends

      public List<ComplexLegendItem> getEditedLegends()
    • isOverlapped

      public boolean isOverlapped(ComplexLegendItem legend)
      Specified by:
      isOverlapped in interface VectorComplexLegend
    • clone

      public Object clone() throws CloneNotSupportedException
      Specified by:
      clone in interface org.gvsig.tools.lang.Cloneable
      Overrides:
      clone in class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
      Throws:
      CloneNotSupportedException
    • add

      public boolean add(ComplexLegendItem legend)
      Specified by:
      add in interface VectorComplexLegend
    • remove

      public boolean remove(ComplexLegendItem legend)
      Specified by:
      remove in interface VectorComplexLegend
    • getLegend

      public ComplexLegendItem getLegend(double scale)
      Specified by:
      getLegend in interface VectorComplexLegend
    • getLegendsInScale

      public List<ComplexLegendItem> getLegendsInScale(double scale)
    • print

      public void print(Graphics2D g, org.gvsig.fmap.mapcontext.ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.fmap.dal.feature.FeatureQuery fquery, org.gvsig.compat.print.PrintAttributes properties) throws org.gvsig.fmap.mapcontext.rendering.legend.LegendException
      Specified by:
      print in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
      Overrides:
      print in class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
      Throws:
      org.gvsig.fmap.mapcontext.rendering.legend.LegendException
    • print

      public void print(Graphics2D g, org.gvsig.fmap.mapcontext.ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.compat.print.PrintAttributes properties) throws org.gvsig.fmap.mapcontext.rendering.legend.LegendException
      Specified by:
      print in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
      Overrides:
      print in class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
      Throws:
      org.gvsig.fmap.mapcontext.rendering.legend.LegendException
    • draw

      public void draw(BufferedImage image, Graphics2D g, org.gvsig.fmap.mapcontext.ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore) throws org.gvsig.fmap.mapcontext.rendering.legend.LegendException
      Specified by:
      draw in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
      Overrides:
      draw in class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
      Throws:
      org.gvsig.fmap.mapcontext.rendering.legend.LegendException
    • draw

      protected void draw(BufferedImage image, Graphics2D g, org.gvsig.fmap.mapcontext.ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.fmap.dal.feature.FeatureQuery featureQuery, double dpi) throws org.gvsig.fmap.mapcontext.rendering.legend.LegendException
      Overrides:
      draw in class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
      Throws:
      org.gvsig.fmap.mapcontext.rendering.legend.LegendException
    • getAllowOverlap

      public boolean getAllowOverlap()
      Specified by:
      getAllowOverlap in interface VectorComplexLegend
    • setAllowOverlap

      public void setAllowOverlap(boolean allowOverlap)
      Specified by:
      setAllowOverlap in interface VectorComplexLegend
    • loadFromState

      public void loadFromState(org.gvsig.tools.persistence.PersistentState state) throws org.gvsig.tools.persistence.exception.PersistenceException
      Specified by:
      loadFromState in interface org.gvsig.tools.persistence.Persistent
      Overrides:
      loadFromState in class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
      Throws:
      org.gvsig.tools.persistence.exception.PersistenceException
    • saveToState

      public void saveToState(org.gvsig.tools.persistence.PersistentState state) throws org.gvsig.tools.persistence.exception.PersistenceException
      Specified by:
      saveToState in interface org.gvsig.tools.persistence.Persistent
      Overrides:
      saveToState in class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
      Throws:
      org.gvsig.tools.persistence.exception.PersistenceException
    • getSymbolByFeature

      public org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol getSymbolByFeature(org.gvsig.fmap.dal.feature.Feature feat) throws org.gvsig.fmap.mapcontext.MapContextException
      Specified by:
      getSymbolByFeature in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
      Throws:
      org.gvsig.fmap.mapcontext.MapContextException
    • getShapeType

      public int getShapeType()
      Specified by:
      getShapeType in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
    • setShapeType

      public void setShapeType(int shapeType)
      Specified by:
      setShapeType in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
    • setDefaultSymbol

      public void setDefaultSymbol(org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol s)
      Specified by:
      setDefaultSymbol in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
    • isUseDefaultSymbol

      public boolean isUseDefaultSymbol()
      Specified by:
      isUseDefaultSymbol in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
    • useDefaultSymbol

      public void useDefaultSymbol(boolean b)
      Specified by:
      useDefaultSymbol in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
    • isSuitableForShapeType

      public boolean isSuitableForShapeType(int shapeType)
      Specified by:
      isSuitableForShapeType in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
    • getDefaultSymbol

      public org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol getDefaultSymbol()
      Specified by:
      getDefaultSymbol in interface org.gvsig.fmap.mapcontext.rendering.legend.ILegend
      Specified by:
      getDefaultSymbol in interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
    • getRequiredFeatureAttributeNames

      protected String[] getRequiredFeatureAttributeNames(org.gvsig.fmap.dal.feature.FeatureStore featureStore) throws org.gvsig.fmap.dal.exception.DataException
      Specified by:
      getRequiredFeatureAttributeNames in class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
      Throws:
      org.gvsig.fmap.dal.exception.DataException
    • getDescriptions

      public String[] getDescriptions()
      Specified by:
      getDescriptions in interface org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedLegend
    • getSymbols

      public org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol[] getSymbols()
      Specified by:
      getSymbols in interface org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedLegend
    • getValues

      public Object[] getValues()
      Specified by:
      getValues in interface org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedLegend