Package ghidra.util.datastruct

# Class CaseInsensitiveDuplicateStringComparator

java.lang.Object
ghidra.util.datastruct.CaseInsensitiveDuplicateStringComparator

All Implemented Interfaces:
  `Comparator<String>`

public class CaseInsensitiveDuplicateStringComparator extends Object implements Comparator<String>
Comparator for sorting Strings in a case insensitive way except that case insensitive duplicates are then sub-sorted by reverse case so that lower case is before upper case. Example: the strings "abc", "bob", "Bob", "zzz" would always sort as shown. In a normal case insensitive sort, the "bob" and "Bob" order would be arbitrary.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `CaseInsensitiveDuplicateStringComparator()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `compare(String name1, String name2)`

  ### 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, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong`

- ## Constructor Details

  - ### CaseInsensitiveDuplicateStringComparator

    public CaseInsensitiveDuplicateStringComparator()

- ## Method Details

  - ### compare

    public int compare(String name1, String name2)
    Specified by:
      `compare` in interface `Comparator<String>`