Advertisement

Results for "Author: lone deranger"

ASP_Volume2 #40005
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

ASP_Volume3 #61244
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

C_Volume2 #81067
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

Java_Volume1 #99611
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

2_2002-2004 #126758
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

3_2004-2005 #145302
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

4_2005-2006 #166541
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

5_2007-2008 #189059
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

6_2008-2009 #211577
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

7_2009-2012 #234095
A simple universal comparator

You can use this class to sort an array of Objects without creating custom Comparators for each field. For example, if you have a class Employee, with methods getName() and getSalary(), you can simply do Arrays.sort(myEmployeeArray, new UniversalComparator("getName", 1)) or Arrays.sort(myEmployeeArray, new UniversalComparator("getSalary", -1)). The first statement would sort your array in ascending order by the value of getName() method, the second would sort it in descending order by the value of getSalary() method. The class uses the reflection API to accomplish this task.

Languages
Top Categories
Global Discovery