project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/netplay/Player.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/netplay/Player.java Mon Jul 16 20:16:03 2012 +0200
@@ -0,0 +1,26 @@
+package org.hedgewars.hedgeroid.netplay;
+
+import java.util.Comparator;
+
+public class Player {
+ public static final ByNameComparator nameComparator = new ByNameComparator();
+
+ public final String name;
+ public final long playerId;
+ public final boolean friend;
+ public final boolean ignored;
+
+ public Player(String name, long playerId, boolean friend, boolean ignored) {
+ super();
+ this.name = name;
+ this.playerId = playerId;
+ this.friend = friend;
+ this.ignored = ignored;
+ }
+
+ private static class ByNameComparator implements Comparator<Player> {
+ public int compare(Player lhs, Player rhs) {
+ return lhs.name.compareToIgnoreCase(rhs.name);
+ }
+ }
+}
\ No newline at end of file