com.alachisoft.ncache.serialization.util.CookieList Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of nc-serialization Show documentation
Show all versions of nc-serialization Show documentation
Internal package of Alachisoft.
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.alachisoft.ncache.serialization.util;
import java.util.ArrayList;
/**
* @author Basit Anwer
*/
public class CookieList
extends ArrayList {
@Override
public int indexOf(Object o) {
if (o == null) {
for (int i = 0; i < size(); i++) {
if (get(i) == null) {
return i;
}
}
} else {
for (int i = 0; i < size(); i++) {
if (o == (get(i))) {
return i;
}
}
}
return -1;
}
}