@Path(value="flows")
public class FlowsWebResource
extends org.onosproject.rest.AbstractWebResource
| Constructor and Description |
|---|
FlowsWebResource() |
| Modifier and Type | Method and Description |
|---|---|
javax.ws.rs.core.Response |
createFlow(String deviceId,
String appId,
InputStream stream)
Creates new flow rule.
|
javax.ws.rs.core.Response |
createFlows(String appId,
InputStream stream)
Creates new flow rules.
|
javax.ws.rs.core.Response |
deleteFlowByDeviceIdAndFlowId(String deviceId,
long flowId)
Removes flow rule.
|
javax.ws.rs.core.Response |
deleteFlows(InputStream stream)
Removes a batch of flow rules.
|
javax.ws.rs.core.Response |
getFlowByAppId(String appId)
Gets flow rules generated by an application.
|
javax.ws.rs.core.Response |
getFlowByDeviceId(String deviceId)
Gets flow entries of a device.
|
javax.ws.rs.core.Response |
getFlowByDeviceIdAndFlowId(String deviceId,
long flowId)
Gets flow rules.
|
javax.ws.rs.core.Response |
getFlows()
Gets all flow entries.
|
javax.ws.rs.core.Response |
getPendingFlows()
Gets all pending flow entries.
|
javax.ws.rs.core.Response |
getTableFlows(int tableId)
Gets all flow entries for a table.
|
javax.ws.rs.core.Response |
removeFlowByAppId(String appId)
Removes flow rules by application ID.
|
codec, encodeArray, getService, mapper, newArray, newObject@GET @Produces(value="application/json") public javax.ws.rs.core.Response getFlows()
@GET @Produces(value="application/json") @Path(value="pending") public javax.ws.rs.core.Response getPendingFlows()
@GET
@Produces(value="application/json")
@Path(value="table/{tableId}")
public javax.ws.rs.core.Response getTableFlows(@PathParam(value="tableId")
int tableId)
tableId - table identifier@POST
@Consumes(value="application/json")
@Produces(value="application/json")
public javax.ws.rs.core.Response createFlows(@QueryParam(value="appId")
String appId,
InputStream stream)
appId - application idstream - flow rules JSON@GET
@Produces(value="application/json")
@Path(value="{deviceId}")
public javax.ws.rs.core.Response getFlowByDeviceId(@PathParam(value="deviceId")
String deviceId)
deviceId - device identifier@GET
@Produces(value="application/json")
@Path(value="{deviceId}/{flowId}")
public javax.ws.rs.core.Response getFlowByDeviceIdAndFlowId(@PathParam(value="deviceId")
String deviceId,
@PathParam(value="flowId")
long flowId)
deviceId - device identifierflowId - flow rule identifier@GET
@Produces(value="application/json")
@Path(value="application/{appId}")
public javax.ws.rs.core.Response getFlowByAppId(@PathParam(value="appId")
String appId)
appId - application identifier@DELETE
@Produces(value="application/json")
@Path(value="application/{appId}")
public javax.ws.rs.core.Response removeFlowByAppId(@PathParam(value="appId")
String appId)
appId - application identifier@POST
@Path(value="{deviceId}")
@Consumes(value="application/json")
@Produces(value="application/json")
public javax.ws.rs.core.Response createFlow(@PathParam(value="deviceId")
String deviceId,
@QueryParam(value="appId")
String appId,
InputStream stream)
deviceId - device identifierappId - application identifierstream - flow rule JSON@DELETE
@Path(value="{deviceId}/{flowId}")
public javax.ws.rs.core.Response deleteFlowByDeviceIdAndFlowId(@PathParam(value="deviceId")
String deviceId,
@PathParam(value="flowId")
long flowId)
deviceId - device identifierflowId - flow rule identifier@DELETE public javax.ws.rs.core.Response deleteFlows(InputStream stream)
stream - stream for posted JSON