blob: b5a6fe1d8367b0a19a5b60dc13abeea0e7712168 [file] [log] [blame]
Umesh Krishnaswamy345ee992012-12-13 20:29:48 -08001package net.floodlightcontroller.staticflowentry.web;
2
3import net.floodlightcontroller.restserver.RestletRoutable;
4
5import org.restlet.Context;
6import org.restlet.Restlet;
7import org.restlet.routing.Router;
8
9public class StaticFlowEntryWebRoutable implements RestletRoutable {
10 /**
11 * Create the Restlet router and bind to the proper resources.
12 */
13 @Override
14 public Restlet getRestlet(Context context) {
15 Router router = new Router(context);
16 router.attach("/json", StaticFlowEntryPusherResource.class);
17 router.attach("/clear/{switch}/json", ClearStaticFlowEntriesResource.class);
18 router.attach("/list/{switch}/json", ListStaticFlowEntriesResource.class);
19 return router;
20 }
21
22 /**
23 * Set the base path for the Topology
24 */
25 @Override
26 public String basePath() {
27 return "/wm/staticflowentrypusher";
28 }
29}