keke <iamkeke <at> gmail.com> writes:
>
>
> Have you add FILE protocol into your Component? Like
> component.getClients.add(Protocol.FILE)
>
> On Sun, Nov 16, 2008 at 12:54 PM, Matt <restdev <at> randomcreation.com>
> wrote:
> "WARNING: No available server connector supports the required protocols: FILE
> .
> Please add the JAR of a matching connector to your classpath."
> Which jar file contains the connector implementation for the FILE protocol?
> Here is what I'm including:
> org.restlet.jar
> com.noelios.restlet.jar
> com.noelios.restlet.ext.simple_3.1.jar
> org.simpleframework_3.1/org.simpleframework.jar
>
>
> -- Cheers,Keke-----------------We paranoid love life
>
Yes, here is my Component initialization:
public class HTTPServer
{
public static final String ROOT_URI =
"file:///Users/matt/Workspace/devster/src/client/js/";
public static void main( String[] args ) throws Exception
{
Component component = new Component();
component.getServers().add( Protocol.HTTP, 8182 );
component.getServers().add( Protocol.FILE );
component.getDefaultHost().attach( "/app", new App() );
component.getDefaultHost().attach( "/files",
new
Application(component.getServers().getContext().createChildContext()) {
public Restlet createRoot()
{
Directory path = new Directory(getContext(), ROOT_URI);
path.setListingAllowed( true );
return path;
}
} );
component.start();
}
}