Class IfNotEmpty

Object
AnchorBean<MaskProvider>
InitializableBean<MaskProvider, ImageInitialization>
ImageBean<MaskProvider>
BeanProviderAsStackBase<MaskProvider, Mask>
MaskProvider
MaskProviderUnary
IfPredicateBase
IfNotEmpty
All Implemented Interfaces:
Provider<Mask>, ProviderAsStack

public class IfNotEmpty extends IfPredicateBase
The current mask is returned if it's non-empty (at least one on voxel) otherwise maskElse is returned.
Author:
Owen Feehan
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected boolean
    predicate(Mask mask)
    Evaluates a predicate condition on the input mask.

    Methods inherited from class org.anchoranalysis.plugin.image.bean.mask.provider.predicate.IfPredicateBase

    createFromMask, getMaskElse, setMaskElse

    Methods inherited from class org.anchoranalysis.image.bean.provider.MaskProviderUnary

    get, getMask, setMask

    Methods inherited from class org.anchoranalysis.image.bean.provider.MaskProvider

    getAsStack

    Methods inherited from class org.anchoranalysis.bean.initializable.InitializableBean

    getInitialization, getLogger, getPropertyInitializer, initialize, initializeRecursive, initRecursiveWithInitializer, isInitialized, onInitialization

    Methods inherited from class org.anchoranalysis.bean.AnchorBean

    checkMisconfigured, describeBean, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • IfNotEmpty

      public IfNotEmpty()
  • Method Details

    • predicate

      protected boolean predicate(Mask mask)
      Description copied from class: IfPredicateBase
      Evaluates a predicate condition on the input mask.
      Specified by:
      predicate in class IfPredicateBase
      Parameters:
      mask - the input Mask to evaluate
      Returns:
      true if the predicate condition is satisfied, false otherwise