blob: bf223c70cb7bbe8671bc1ea175b94e43ffbc84cb [file] [log] [blame]
Jonathan Hart23701d12014-04-03 10:45:48 -07001package net.onrc.onos.core.linkdiscovery.web;
Umesh Krishnaswamy345ee992012-12-13 20:29:48 -08002
3import net.floodlightcontroller.restserver.RestletRoutable;
4
5import org.restlet.Context;
6import org.restlet.routing.Router;
7
8public class LinkDiscoveryWebRoutable implements RestletRoutable {
9 /**
10 * Create the Restlet router and bind to the proper resources.
11 */
12 @Override
13 public Router getRestlet(Context context) {
14 Router router = new Router(context);
Naoki Shiota862cc3b2013-12-13 15:42:50 -080015 router.attach("/links/json", LinksResource.class);
Umesh Krishnaswamy345ee992012-12-13 20:29:48 -080016 return router;
17 }
18
19 /**
Ray Milkeyb41100a2014-04-10 10:42:15 -070020 * Set the base path for the Topology.
Umesh Krishnaswamy345ee992012-12-13 20:29:48 -080021 */
22 @Override
23 public String basePath() {
Naoki Shiota862cc3b2013-12-13 15:42:50 -080024 return "/wm/onos/linkdiscovery";
Umesh Krishnaswamy345ee992012-12-13 20:29:48 -080025 }
Ray Milkey0f913a02014-04-07 20:58:17 -070026}