Class StyleVisitorCoverageProcessingNodeAdapter
- Object
-
- StyleVisitorAdapter
-
- StyleVisitorCoverageProcessingNodeAdapter
-
- All Implemented Interfaces:
StyleVisitor
,CoverageProcessingNode
- Direct Known Subclasses:
SubchainStyleVisitorCoverageProcessingAdapter
public abstract class StyleVisitorCoverageProcessingNodeAdapter extends StyleVisitorAdapter implements StyleVisitor, CoverageProcessingNode
This class implements an adapter to allow aCoverageProcessingNode
to feed itself by visiting an SLDStyle
.This class can be used to tie together
CoverageProcessingNode
s built from a chains as specified by theRasterSymbolizer
SLd element.- Author:
- Simone Giannecchini, GeoSolutions
-
-
Constructor Summary
Constructors Constructor Description StyleVisitorCoverageProcessingNodeAdapter(int maxSources, InternationalString name, InternationalString description)
Default constructor that gives users the possibilityStyleVisitorCoverageProcessingNodeAdapter(int maxSources, Hints hints, InternationalString name, InternationalString description)
Default constructor that gives users the possibilityStyleVisitorCoverageProcessingNodeAdapter(InternationalString name, InternationalString description)
Default constructor forStyleVisitorCoverageProcessingNodeAdapter
StyleVisitorCoverageProcessingNodeAdapter(CoverageProcessingNode adaptee)
-
Method Summary
-
Methods inherited from class StyleVisitorAdapter
visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit
-
-
-
-
Constructor Detail
-
StyleVisitorCoverageProcessingNodeAdapter
public StyleVisitorCoverageProcessingNodeAdapter(CoverageProcessingNode adaptee)
- Parameters:
adaptee
-
-
StyleVisitorCoverageProcessingNodeAdapter
public StyleVisitorCoverageProcessingNodeAdapter(InternationalString name, InternationalString description)
Default constructor forStyleVisitorCoverageProcessingNodeAdapter
-
StyleVisitorCoverageProcessingNodeAdapter
public StyleVisitorCoverageProcessingNodeAdapter(int maxSources, InternationalString name, InternationalString description)
Default constructor that gives users the possibility- Parameters:
maxSources
- maximum number of sources allowed for this node.
-
StyleVisitorCoverageProcessingNodeAdapter
public StyleVisitorCoverageProcessingNodeAdapter(int maxSources, Hints hints, InternationalString name, InternationalString description)
Default constructor that gives users the possibility- Parameters:
maxSources
- maximum number of sources allowed for this node.hints
- instance ofHints
class to control creation of internal factories. It can benull
.
-
-
Method Detail
-
getAdaptee
protected CoverageProcessingNode getAdaptee()
Allows subclasses to access theCoverageProcessingNode
we are adapting.- Returns:
- the adaptee
- UML property:
- name="adaptee"
-
execute
protected abstract GridCoverage execute()
- See Also:
BaseCoverageProcessingNode.execute()
-
addSink
public void addSink(CoverageProcessingNode sink)
Description copied from interface:CoverageProcessingNode
Adds a sinkCoverageProcessingNode
to the list of sinks for thisCoverageProcessingNode
.- Specified by:
addSink
in interfaceCoverageProcessingNode
- Parameters:
sink
- theCoverageProcessingNode
to add to theList
of sinks for thisCoverageProcessingNode
.
-
addSource
public boolean addSource(CoverageProcessingNode source)
Description copied from interface:CoverageProcessingNode
Adds a sourceCoverageProcessingNode
to the list of sources for thisCoverageProcessingNode
.- Specified by:
addSource
in interfaceCoverageProcessingNode
- Parameters:
source
- theCoverageProcessingNode
to add to theList
of sources for thisCoverageProcessingNode
.- Returns:
true
if everything goes fine,false
otherwise.
-
getOutput
public GridCoverage getOutput()
Description copied from interface:CoverageProcessingNode
Forces this node to create the output coverage for the operation represented by this node.- Specified by:
getOutput
in interfaceCoverageProcessingNode
- Returns:
- the
Coverage
which represents the output for thisCoverageProcessingNode
.
-
getSink
public CoverageProcessingNode getSink(int index)
Description copied from interface:CoverageProcessingNode
- Specified by:
getSink
in interfaceCoverageProcessingNode
- Parameters:
index
- is the zero-based index for the source we want to access.- Returns:
- the
CoverageProcessingNode
which represents the source at indexindex
for thisCoverageProcessingNode
.
-
getSinks
public List<CoverageProcessingNode> getSinks()
Description copied from interface:CoverageProcessingNode
Retrieves theList
of sinks for thisCoverageProcessingNode
. Each sink MUST be aCoverageProcessingNode
.- Specified by:
getSinks
in interfaceCoverageProcessingNode
- Returns:
- a
List
ofCoverageProcessingNode
which represents the sinks for thisCoverageProcessingNode
.
-
getSource
public CoverageProcessingNode getSource(int index)
Description copied from interface:CoverageProcessingNode
- Specified by:
getSource
in interfaceCoverageProcessingNode
- Parameters:
index
- is the zero-based index for the sink we want to get.- Returns:
- the
CoverageProcessingNode
which represents the sink at indexindex
for thisCoverageProcessingNode
.
-
getSources
public List<CoverageProcessingNode> getSources()
Description copied from interface:CoverageProcessingNode
Retrieves theList
of source for thisCoverageProcessingNode
. Each source MUST be aCoverageProcessingNode
.- Specified by:
getSources
in interfaceCoverageProcessingNode
- Returns:
- a
List
ofCoverageProcessingNode
which represents the sources for thisCoverageProcessingNode
.
-
removeSink
public boolean removeSink(CoverageProcessingNode sink)
Description copied from interface:CoverageProcessingNode
Removes a sinkCoverageProcessingNode
from the list of sinks for thisCoverageProcessingNode
.- Specified by:
removeSink
in interfaceCoverageProcessingNode
- Parameters:
sink
- theCoverageProcessingNode
to remove from theList
of sinks for thisCoverageProcessingNode
.- Returns:
true
in case we remove something,false
otherwise.
-
removeSink
public CoverageProcessingNode removeSink(int index)
Description copied from interface:CoverageProcessingNode
Removes a sinkCoverageProcessingNode
from the list of sinks for thisCoverageProcessingNode
.- Specified by:
removeSink
in interfaceCoverageProcessingNode
- Parameters:
index
- the index at which we want to remove a sink from theList
of sinks for thisCoverageProcessingNode
.- Returns:
- the
CoverageProcessingNode
we actually remove from the sinks list.
-
removeSource
public boolean removeSource(CoverageProcessingNode source)
Description copied from interface:CoverageProcessingNode
Removes a sourceCoverageProcessingNode
to the list of sources for thisCoverageProcessingNode
.- Specified by:
removeSource
in interfaceCoverageProcessingNode
- Parameters:
source
- theCoverageProcessingNode
to remove from theList
of sources for thisCoverageProcessingNode
.- Returns:
true
in case we remove something,false
otherwise.
-
removeSource
public CoverageProcessingNode removeSource(int index)
Description copied from interface:CoverageProcessingNode
Removes a sourceCoverageProcessingNode
to the list of sources for thisCoverageProcessingNode
.- Specified by:
removeSource
in interfaceCoverageProcessingNode
- Parameters:
index
- the index at which we want to remove a source from theList
of sources for thisCoverageProcessingNode
.- Returns:
- the
CoverageProcessingNode
we actually remove from the sources list.
-
dispose
public void dispose(boolean force)
Description copied from interface:CoverageProcessingNode
Disposes all the resources used by thisCoverageProcessingNode
.- Specified by:
dispose
in interfaceCoverageProcessingNode
- Parameters:
force
-true
to force disposal,false
to suggest disposal.
-
getHints
public Hints getHints()
Description copied from interface:CoverageProcessingNode
Getter forHints
.- Specified by:
getHints
in interfaceCoverageProcessingNode
- Returns:
Hints
provided at construction time to controlGridCoverageFactory
creation.
-
getNumberOfSinks
public int getNumberOfSinks()
Description copied from interface:CoverageProcessingNode
Returns the number of sinks for thisCoverageProcessingNode
.- Specified by:
getNumberOfSinks
in interfaceCoverageProcessingNode
- Returns:
- the number of sinks for this
CoverageProcessingNode
.
-
getNumberOfSources
public int getNumberOfSources()
Description copied from interface:CoverageProcessingNode
Returns the number of sources for thisCoverageProcessingNode
.- Specified by:
getNumberOfSources
in interfaceCoverageProcessingNode
- Returns:
- the number of sources for this
CoverageProcessingNode
.
-
getDescription
public InternationalString getDescription()
Description copied from interface:CoverageProcessingNode
Retrieves the description for thisCoverageProcessingNode
- Specified by:
getDescription
in interfaceCoverageProcessingNode
- Returns:
- the description for this
CoverageProcessingNode
-
getName
public InternationalString getName()
Description copied from interface:CoverageProcessingNode
Retrieves the name for thisCoverageProcessingNode
- Specified by:
getName
in interfaceCoverageProcessingNode
- Returns:
- the name for this
CoverageProcessingNode
-
toString
public String toString()
Description copied from interface:CoverageProcessingNode
Provides a descriptive description for thisCoverageProcessingNode
.- Specified by:
toString
in interfaceCoverageProcessingNode
- Overrides:
toString
in classObject
- Returns:
- a descriptive description for this
CoverageProcessingNode
-
getCoverageFactory
public GridCoverageFactory getCoverageFactory()
Description copied from interface:CoverageProcessingNode
TheGridCoverageFactory
we will internally use for build intermediate and outputGridCoverage2D
.- Specified by:
getCoverageFactory
in interfaceCoverageProcessingNode
- Returns:
- a
GridCoverageFactory
we will internally use for build intermediate and outputGridCoverage2D
.
-
-