public class POP3BeforeSMTPHelper extends Object
Modifier and Type | Field and Description |
---|---|
static long |
EXPIRE_TIME
Default expire time in ms (1 hour)
|
static Map<String,Long> |
ipMap
The map in which the ipAddresses and timestamp stored
|
Modifier and Type | Method and Description |
---|---|
static void |
addIPAddress(String ipAddress)
Add the ipAddress to the authorized ipAddresses
|
static void |
clearIP()
Remove all ipAddresses from the authorized map
|
static boolean |
isAuthorized(String ipAddress)
Return true if the ip is authorized to relay
|
static void |
removeExpiredIP() |
static void |
removeExpiredIP(long clearTime)
Remove all ipAddress from the authorized map which are older then the
given time
|
public static final long EXPIRE_TIME
public static boolean isAuthorized(String ipAddress)
ipAddress
- The ipAddresspublic static void addIPAddress(String ipAddress)
ipAddress
- The ipAddresspublic static void removeExpiredIP()
removeExpiredIP(long)
public static void removeExpiredIP(long clearTime)
clearTime
- The time in milliseconds after which an ipAddress should be
handled as expiredpublic static void clearIP()
Copyright © 2002-2012 The Apache Software Foundation. All Rights Reserved.