Class MergeLayers
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.data.imagesegmentation.filter.AbstractImageSegmentationContainerFilter
-
- adams.data.imagesegmentation.filter.MergeLayers
-
- All Implemented Interfaces:
Destroyable,GlobalInfoSupporter,LoggingLevelHandler,LoggingSupporter,OptionHandler,SizeOfHandler,Serializable
public class MergeLayers extends AbstractImageSegmentationContainerFilter
Merges two or more layers into a new one (or replacing an existing one).- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanm_DeleteOldLayerswhether to delete the layers used for merging.protected BaseString[]m_LayersToMergethe layers to merge.protected Stringm_NewLayerthe new layer to generate.-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description MergeLayers()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddefineOptions()Adds options to the internal list of options.StringdeleteOldLayersTipText()Returns the tip text for this property.protected ImageSegmentationContainerdoFilter(ImageSegmentationContainer cont)Performs the filtering of the container.booleangetDeleteOldLayers()Returns whether to remove the old layers that are no longer needed.BaseString[]getLayersToMerge()Returns the names of the layers to merge.StringgetNewLayer()Returns the name of the layer generated from the merge, can replace an existing one.StringglobalInfo()Returns a string describing the object.StringlayersToMergeTipText()Returns the tip text for this property.StringnewLayerTipText()Returns the tip text for this property.voidsetDeleteOldLayers(boolean value)Sets whether to remove the old layers that are no longer needed.voidsetLayersToMerge(BaseString[] value)Sets the names of the layers to merge.voidsetNewLayer(String value)Sets the name of the layer generated from the merge, can replace an existing one.-
Methods inherited from class adams.data.imagesegmentation.filter.AbstractImageSegmentationContainerFilter
check, filter
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_LayersToMerge
protected BaseString[] m_LayersToMerge
the layers to merge.
-
m_NewLayer
protected String m_NewLayer
the new layer to generate.
-
m_DeleteOldLayers
protected boolean m_DeleteOldLayers
whether to delete the layers used for merging.
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfoin interfaceGlobalInfoSupporter- Specified by:
globalInfoin classAbstractOptionHandler- Returns:
- a description suitable for displaying in the gui
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptionsin interfaceOptionHandler- Overrides:
defineOptionsin classAbstractOptionHandler
-
setLayersToMerge
public void setLayersToMerge(BaseString[] value)
Sets the names of the layers to merge.- Parameters:
value- the names
-
getLayersToMerge
public BaseString[] getLayersToMerge()
Returns the names of the layers to merge.- Returns:
- the names
-
layersToMergeTipText
public String layersToMergeTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the gui
-
setNewLayer
public void setNewLayer(String value)
Sets the name of the layer generated from the merge, can replace an existing one.- Parameters:
value- the name
-
getNewLayer
public String getNewLayer()
Returns the name of the layer generated from the merge, can replace an existing one.- Returns:
- the name
-
newLayerTipText
public String newLayerTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the gui
-
setDeleteOldLayers
public void setDeleteOldLayers(boolean value)
Sets whether to remove the old layers that are no longer needed.- Parameters:
value- true if to delete
-
getDeleteOldLayers
public boolean getDeleteOldLayers()
Returns whether to remove the old layers that are no longer needed.- Returns:
- true if to delete
-
deleteOldLayersTipText
public String deleteOldLayersTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the gui
-
doFilter
protected ImageSegmentationContainer doFilter(ImageSegmentationContainer cont)
Performs the filtering of the container.- Specified by:
doFilterin classAbstractImageSegmentationContainerFilter- Parameters:
cont- the container to filter- Returns:
- the filtered container
-
-