org.freehep.jas.plugin.tree
Class SorterAlphabetical
java.lang.Object
org.freehep.jas.plugin.tree.SorterAlphabetical
- All Implemented Interfaces:
- FTreeNodeSorter
public class SorterAlphabetical
- extends Object
- implements FTreeNodeSorter
- Author:
- The FreeHEP team @ SLAC.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SorterAlphabetical
public SorterAlphabetical()
algorithmName
public String algorithmName()
- Description copied from interface:
FTreeNodeSorter
- The name of the sorting algorithm.
- Specified by:
algorithmName
in interface FTreeNodeSorter
- Returns:
- The name of the algorithm.
description
public String description()
- Description copied from interface:
FTreeNodeSorter
- The description of what the algorithm does.
- Specified by:
description
in interface FTreeNodeSorter
- Returns:
- The description.
sort
public int sort(FTreeNode node1,
FTreeNode node2)
- Description copied from interface:
FTreeNodeSorter
- Sort two FTreeNodes.
- Specified by:
sort
in interface FTreeNodeSorter
- Parameters:
node1
- The first node.node2
- The second node.
- Returns:
- -1 if node1 comes before node2
0 if their position is interchengable
+1 if node1 comes after node2
Copyright © 2013. All Rights Reserved.