Class MarkMergeProposer
Object
org.anchoranalysis.bean.AnchorBean<B>
org.anchoranalysis.bean.initializable.InitializableBean<T,MarksInitialization>
org.anchoranalysis.mpp.bean.MarksBean<T>
org.anchoranalysis.mpp.bean.proposer.ProposerBean<MarkMergeProposer>
org.anchoranalysis.mpp.bean.proposer.MarkMergeProposer
- All Implemented Interfaces:
CompatibleWithMark
public abstract class MarkMergeProposer extends ProposerBean<MarkMergeProposer> implements CompatibleWithMark
An abstract base class for proposing merges between marks.
-
Constructor Summary
Constructors Constructor Description MarkMergeProposer() -
Method Summary
Modifier and Type Method Description Optional<List<org.anchoranalysis.spatial.point.Point3f>>getLastPoints1()Gets the points associated with the first mark from the last proposal.Optional<List<org.anchoranalysis.spatial.point.Point3f>>getLastPoints2()Gets the points associated with the second mark from the last proposal.abstract Optional<Mark>propose(VoxelizedMarkMemo mark1, VoxelizedMarkMemo mark2, ProposerContext context)Proposes a merge between two marks.Methods inherited from class org.anchoranalysis.bean.initializable.InitializableBean
getInitialization, getLogger, getPropertyInitializer, initialize, initializeRecursive, initRecursiveWithInitializer, isInitialized, onInitializationMethods inherited from class org.anchoranalysis.bean.AnchorBean
checkMisconfigured, describeBean, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
-
Constructor Details
-
MarkMergeProposer
public MarkMergeProposer()
-
-
Method Details
-
propose
public abstract Optional<Mark> propose(VoxelizedMarkMemo mark1, VoxelizedMarkMemo mark2, ProposerContext context) throws ProposalAbnormalFailureExceptionProposes a merge between two marks.- Parameters:
mark1- the first mark to mergemark2- the second mark to mergecontext- the context for the proposal- Returns:
- an Optional containing the merged mark, or empty if no merge is proposed
- Throws:
ProposalAbnormalFailureException- if the proposal fails abnormally
-
getLastPoints1
Gets the points associated with the first mark from the last proposal.- Returns:
- an Optional containing a list of points, or empty if no points are available
-
getLastPoints2
Gets the points associated with the second mark from the last proposal.- Returns:
- an Optional containing a list of points, or empty if no points are available
-