Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

LolayPair no longer extends android.util.Pair.

  • Loading branch information...
commit 24498f38d3cae8628a92fe5c29ac0859bba6681a 1 parent f644288
@gjritter gjritter authored
View
11 src/main/java/com/lolay/android/util/LolayPair.java
@@ -6,6 +6,8 @@
import java.io.IOException;
import java.io.InputStream;
+import java.io.ObjectInputStream;
+import java.io.ObjectOutputStream;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
@@ -16,12 +18,15 @@
import android.util.Log;
import android.util.Pair;
-public class LolayPair<F, S> extends Pair<F, S> implements Serializable {
+public class LolayPair<F, S> implements Serializable {
private static final String TAG = LolayPair.class.getSimpleName();
private static final long serialVersionUID = 1L;
-
+ public F first;
+ public S second;
+
public LolayPair(F first, S second) {
- super(first, second);
+ this.first = first;
+ this.second = second;
}
public static List<LolayPair<String,String>> loadStream(InputStream stream) {
View
4 src/main/java/com/lolay/android/util/SpinnerPair.java
@@ -9,10 +9,10 @@
* This class is intended to be used with {@link android.widget.Spinner} where {@code Pair.second} will be
* used for spinner display value, and {@code Pair.first} will be used as the actual value to be saved.
*/
-public class SpinnerPair extends LolayPair<Object, String>{
+public class SpinnerPair<F> extends LolayPair<F, String>{
private static final long serialVersionUID = 1L;
- public SpinnerPair(Object first, String second) {
+ public SpinnerPair(F first, String second) {
super(first, second);
}
Please sign in to comment.
Something went wrong with that request. Please try again.