org.apache.ftpserver.remote
Class IpRestrictor

java.lang.Object
  extended byorg.apache.ftpserver.remote.IpRestrictor
All Implemented Interfaces:
IpRestrictorInterface, java.rmi.Remote

public class IpRestrictor
extends java.lang.Object
implements IpRestrictorInterface

IP Restrictor remotr adapter class. Used by admin GUI.

Author:
Rana Bhattacharyya

Constructor Summary
IpRestrictor(IpRestrictorInterface ipRestrictor)
          Constructor - sets the actual ip restrictor object
 
Method Summary
 void addEntry(java.lang.String str)
          Add new entry
 void clear()
          Clear all entries.
 IpRestrictorInterface getActualObject()
          Get the actual object.
 java.util.Collection getAllEntries()
          Get all entries
 boolean hasPermission(java.net.InetAddress addr)
          Check IP permission.
 boolean isAllowIp()
          Allow/ban IP flag
 void reload()
          Reload data from store.
 void removeEntry(java.lang.String str)
          Remove entry
 void save()
          Save data into store.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IpRestrictor

public IpRestrictor(IpRestrictorInterface ipRestrictor)
             throws java.rmi.RemoteException
Constructor - sets the actual ip restrictor object

Method Detail

getActualObject

public IpRestrictorInterface getActualObject()
Get the actual object.


isAllowIp

public boolean isAllowIp()
Allow/ban IP flag

Specified by:
isAllowIp in interface IpRestrictorInterface

reload

public void reload()
            throws java.io.IOException
Reload data from store.

Specified by:
reload in interface IpRestrictorInterface
Throws:
java.io.IOException

save

public void save()
          throws java.io.IOException
Save data into store.

Specified by:
save in interface IpRestrictorInterface
Throws:
java.io.IOException

hasPermission

public boolean hasPermission(java.net.InetAddress addr)
Check IP permission.

Specified by:
hasPermission in interface IpRestrictorInterface

clear

public void clear()
Clear all entries.

Specified by:
clear in interface IpRestrictorInterface

addEntry

public void addEntry(java.lang.String str)
Add new entry

Specified by:
addEntry in interface IpRestrictorInterface

removeEntry

public void removeEntry(java.lang.String str)
Remove entry

Specified by:
removeEntry in interface IpRestrictorInterface

getAllEntries

public java.util.Collection getAllEntries()
Get all entries

Specified by:
getAllEntries in interface IpRestrictorInterface


Copyright © 2001-2007 Codehaus. All Rights Reserved.