Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.1.0)

E17493-02

oracle.ide.panels
Class Navigable.NavigableComparator

java.lang.Object
  extended by oracle.ide.panels.Navigable.NavigableComparator
All Implemented Interfaces:
java.util.Comparator
Enclosing class:
Navigable

public static class Navigable.NavigableComparator
extends java.lang.Object
implements java.util.Comparator

Comparator implementation used for sorting child Navigable instances by label. This Comparator has a provision for optionally specifying one item that is to appear first in the sorting order, regardless of its sorting position lexicographically.


Field Summary
protected static java.text.Collator COLLATOR
           
 
Constructor Summary
Navigable.NavigableComparator()
          Constructs a default NavigableComparator.
Navigable.NavigableComparator(java.lang.String firstItemLabel)
          Constructs a NavigableComparator using the specified label for the Navigable that is to appear first in the sorting order.
 
Method Summary
 int compare(java.lang.Object o1, java.lang.Object o2)
           
 java.lang.String getFirstItemLabel()
          Returns the label of the item that should appear first in the sorting order; returns null if all Navigable instances are sorted lexicographically.
 void setFirstItemLabel(java.lang.String firstItemLabel)
          Sets the label of the item that is to appear first in the sorting order; if null, then all Navigable instances are sorted lexicographically.
 
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
 

Field Detail

COLLATOR

protected static final java.text.Collator COLLATOR
Constructor Detail

Navigable.NavigableComparator

public Navigable.NavigableComparator()
Constructs a default NavigableComparator.


Navigable.NavigableComparator

public Navigable.NavigableComparator(java.lang.String firstItemLabel)
Constructs a NavigableComparator using the specified label for the Navigable that is to appear first in the sorting order.

Method Detail

setFirstItemLabel

public void setFirstItemLabel(java.lang.String firstItemLabel)
Sets the label of the item that is to appear first in the sorting order; if null, then all Navigable instances are sorted lexicographically.


getFirstItemLabel

public java.lang.String getFirstItemLabel()
Returns the label of the item that should appear first in the sorting order; returns null if all Navigable instances are sorted lexicographically.


compare

public int compare(java.lang.Object o1,
                   java.lang.Object o2)
Specified by:
compare in interface java.util.Comparator

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.1.0)

E17493-02

Copyright © 1997, 2011, Oracle. All rights reserved.