org.apache.droids.protocol.file
Class FileProtocol

java.lang.Object
  extended by org.apache.droids.protocol.file.FileProtocol
All Implemented Interfaces:
Protocol

public class FileProtocol
extends java.lang.Object
implements Protocol


Constructor Summary
FileProtocol()
           
 
Method Summary
 boolean isAllowed(java.net.URI uri)
          Some protocols (like http) offer a mechanism to evaluate whether the client can request a given url (in http this is the robots.txt configuration)
 ManagedContentEntity load(java.net.URI uri)
          Return the content entity represent of the url
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileProtocol

public FileProtocol()
Method Detail

isAllowed

public boolean isAllowed(java.net.URI uri)
Description copied from interface: Protocol
Some protocols (like http) offer a mechanism to evaluate whether the client can request a given url (in http this is the robots.txt configuration)

Specified by:
isAllowed in interface Protocol
Parameters:
uri - the url to evaluate
Returns:
true if we can request the url. false if we are forbidden.

load

public ManagedContentEntity load(java.net.URI uri)
                          throws java.io.IOException
Description copied from interface: Protocol
Return the content entity represent of the url

Specified by:
load in interface Protocol
Returns:
the content of the given url
Throws:
java.io.IOException


Copyright © 2007-2009. All Rights Reserved.