Added method to check for status response.

This commit is contained in:
Apoorv Khatreja 2011-07-17 01:41:14 +05:30
parent 021d5641e5
commit c6a2cb48b1
1 changed files with 9 additions and 0 deletions

View File

@ -488,6 +488,15 @@ public class ImapResponseParser {
}
}
public static boolean isStatusResponse(String symbol) {
return symbol.equalsIgnoreCase("OK") ||
symbol.equalsIgnoreCase("NO") ||
symbol.equalsIgnoreCase("BAD") ||
symbol.equalsIgnoreCase("PREAUTH") ||
symbol.equalsIgnoreCase("BYE");
}
public static boolean equalsIgnoreCase(Object o1, Object o2) {
if (o1 != null && o2 != null && o1 instanceof String && o2 instanceof String) {
String s1 = (String)o1;