Hi Tim, Thank for the insight and so I am working on adding more complexity. So here is a simple code that should work, but for some reason I get this error: The filter org.restlet.engine.application.RangeFilter@24f2f2 was executed without a next Restlet attached to it. 2014-08-07 15:37:47 0:0:0:0:0:0:0:1 - - 8400 GET / - 500 486 0
The full code is as follows: package org.simpler.test; import org.restlet.Application; import org.restlet.Component; import org.restlet.Request; import org.restlet.Response; import org.restlet.Restlet; import org.restlet.data.MediaType; import org.restlet.data.Protocol; import org.restlet.representation.StringRepresentation; import org.restlet.routing.Router; public class PageTest extends Application { public static void main(String[] args) throws Exception { Component component = new Component(); component.getServers().add(Protocol.HTTP, 8400); Application application = new Application(); component.getDefaultHost().attach(application); component.start(); } @Override public Restlet createInboundRoot(){ Router router = new Router(this.getContext()); Restlet mainpage = new Restlet(){ @Override public void handle(Request request, Response response){ StringBuilder stringBuilder = new StringBuilder(); stringBuilder.append("<html>"); stringBuilder.append("<head><title>Default Page of my TEST application</title></head>"); stringBuilder.append(" Click on link "); //stringBuilder.append(" "); stringBuilder.append(" <\"/file\"> </html>"); response.setEntity(new StringRepresentation(stringBuilder.toString(), MediaType.TEXT_HTML)); } }; router.attach("", mainpage); return router; } } -- View this message in context: http://restlet-discuss.1400322.n2.nabble.com/Complexity-in-understanding-tp7579254p7579256.html Sent from the Restlet Discuss mailing list archive at Nabble.com. ------------------------------------------------------ http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=3086393