Package viewer.base

Class Layer

java.lang.Object
viewer.base.Layer
Direct Known Subclasses:
DatabaseLayer, ListLayer, TreeLayer

public abstract class Layer
extends java.lang.Object
A layer that can be added to a map.
Author:
haunert
  • Field Summary

    Fields 
    Modifier and Type Field Description
    protected Envelope extent
    the total extent of this layer
    protected SymbolFactory mySymbolFactory
    the factory used to transform features to drawable map objects
  • Constructor Summary

    Constructors 
    Constructor Description
    Layer()  
    Layer​(SymbolFactory symbolFactory)  
  • Method Summary

    Modifier and Type Method Description
    Envelope getExtent()
    Returns the extent of this layer as an envelope
    abstract java.util.List<Symbol> query​(Envelope searchEnv)
    Queries all symbols whose bounding boxes intersect the search envelope
    void setExtent​(Envelope extent)
    Sets the extent of this layer as an envelope.
    ListLayer toCachedLayer()
    creates a new layer in which all symbols are stored in a list, based on this layer

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

  • Method Details

    • getExtent

      public Envelope getExtent()
      Returns the extent of this layer as an envelope
      Returns:
      extent to return
    • setExtent

      public void setExtent​(Envelope extent)
      Sets the extent of this layer as an envelope. Use with care!
      Parameters:
      extent - extent to set
    • query

      public abstract java.util.List<Symbol> query​(Envelope searchEnv)
      Queries all symbols whose bounding boxes intersect the search envelope
      Parameters:
      searchEnv - the search envelope
      Returns:
      found objects
    • toCachedLayer

      public ListLayer toCachedLayer()
      creates a new layer in which all symbols are stored in a list, based on this layer
      Returns:
      created layer