Oracle Fusion Middleware extensions for Applications Core API Reference
11g Release 1 (11.1.1.6)

E22562-03

oracle.apps.fnd.applcore.trees.uiModel.util
Class TreeNodeComparator

java.lang.Object
  extended by oracle.apps.fnd.applcore.trees.uiModel.util.TreeNodeComparator
All Implemented Interfaces:
java.util.Comparator

public final class TreeNodeComparator
extends java.lang.Object
implements java.util.Comparator

Compares the Tree Node Dyna Bean based on values of Primary Key.

Author:
Abhay K Kumar <abhay.k.kumar.@oracle.com>

Constructor Summary
TreeNodeComparator()
           
 
Method Summary
 int compare(java.lang.Object obj1, java.lang.Object obj2)
          Compares the values for Two objects.
 int compare(java.lang.Object obj1, java.lang.Object obj2, java.util.List<Attribute> pkAttrs)
          Comapres the Two Tree Node based on the values for Primary Key fields.
 int compareLong(java.lang.Long treeNode1PkValue, java.lang.Long treeNode2PkValue)
          Compares the values for Two objects of Long datatype.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Constructor Detail

TreeNodeComparator

public TreeNodeComparator()
Method Detail

compare

public int compare(java.lang.Object obj1,
                   java.lang.Object obj2,
                   java.util.List<Attribute> pkAttrs)
Comapres the Two Tree Node based on the values for Primary Key fields.

Parameters:
obj1 - Tree Node
obj2 - Tree Node
pkAttrs - List of Primary Key attributes
Returns:
negative value if obj1 has less precedence than obj2 ,positive value if obj1 has precedence greater than obj2 and 0 for same precedence

compareLong

public int compareLong(java.lang.Long treeNode1PkValue,
                       java.lang.Long treeNode2PkValue)
Compares the values for Two objects of Long datatype.

Parameters:
treeNode1PkValue - Long value for Attribute
treeNode2PkValue - Long value for Attribute
Returns:
negative value if treeNode1PkValue is less than treeNode2PkValue positive value if treeNode1PkValue is more than treeNode2PkValue and 0 if both are equal

compare

public int compare(java.lang.Object obj1,
                   java.lang.Object obj2)
Compares the values for Two objects.

Specified by:
compare in interface java.util.Comparator
Parameters:
obj1 - Object1
obj2 - Object1
Returns:
negative value if obj1 is less than obj2 positive value if obj1 is more than obj2 and 0 if both are equal

Oracle Fusion Middleware extensions for Applications Core API Reference
11g Release 1 (11.1.1.6)

E22562-03

Copyright © 2012 Oracle. All Rights Reserved.