Class PhysicalConnectionRestController
- java.lang.Object
-
- org.neotropic.kuwaiba.northbound.rest.services.PhysicalConnectionRestController
-
- All Implemented Interfaces:
PhysicalConnectionRestOpenApi
@RestController @RequestMapping("/v2.1.1/physical-connections/") public class PhysicalConnectionRestController extends Object implements PhysicalConnectionRestOpenApi
Physical Connection Rest Controller.- Author:
- Mauricio Ruiz Beltrán <mauricio.ruiz@kuwaiba.org>
-
-
Constructor Summary
Constructors Constructor Description PhysicalConnectionRestController()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
createPhysicalConnection(String aObjectClassName, String aObjectId, String bObjectClassName, String bObjectId, String name, String connectionClassName, String templateId, String userName, String sessionId)
Creates a physical connection.void
deletePhysicalConnection(String objectClassName, String objectId, String userName, String sessionId)
Deletes a physical connection.List<BusinessObjectLight>
getPhysicalPath(String objectClassName, String objectId, String sessionId)
Finds the physical path from one port to another.HashMap<BusinessObjectLight,List<BusinessObjectLight>>
getPhysicalTree(String objectClassName, String objectId, String sessionId)
Gets A tree representation of all physical paths as a hash map.
-
-
-
Field Detail
-
PATH
public static final String PATH
Path that includes the Kuwaiba version and module- See Also:
- Constant Field Values
-
-
Method Detail
-
createPhysicalConnection
@RequestMapping(method=POST, value="createPhysicalConnection/{aObjectClassName}/{aObjectId}/{bObjectClassName}/{bObjectId}/{name}/{connectionClassName}/{templateId}/{userName}/{sessionId}", produces="application/json") public String createPhysicalConnection(@PathVariable("aObjectClassName") String aObjectClassName, @PathVariable("aObjectId") String aObjectId, @PathVariable("bObjectClassName") String bObjectClassName, @PathVariable("bObjectId") String bObjectId, @PathVariable("name") String name, @PathVariable("connectionClassName") String connectionClassName, @PathVariable("templateId") String templateId, @PathVariable("userName") String userName, @PathVariable("sessionId") String sessionId)
Creates a physical connection.- Specified by:
createPhysicalConnection
in interfacePhysicalConnectionRestOpenApi
- Parameters:
aObjectClassName
- The class name of the first object to related.aObjectId
- The id of the first object to related.bObjectClassName
- The class name of the second object to related.bObjectId
- The id of the first object to related.name
- The connection name.connectionClassName
- The class name of the connection. Must be subclass of GenericPhysicalConnection.templateId
- Template id to be used to create the current object. Use "null" as string or empty string to not use a template.userName
- The user name of the session.sessionId
- The session token id.- Returns:
- The id of the newly created physical connection.
-
deletePhysicalConnection
@RequestMapping(method=DELETE, value="deletePhysicalConnection/{objectClassName}/{objectId}/{userName}/{sessionId}", produces="application/json") public void deletePhysicalConnection(@PathVariable("objectClassName") String objectClassName, @PathVariable("objectId") String objectId, @PathVariable("userName") String userName, @PathVariable("sessionId") String sessionId)
Deletes a physical connection.- Specified by:
deletePhysicalConnection
in interfacePhysicalConnectionRestOpenApi
- Parameters:
objectClassName
- The class name of the object.objectId
- The id of the object.userName
- The user name of the session.sessionId
- The session token id.
-
getPhysicalPath
@RequestMapping(method=GET, value="getPhysicalPath/{objectClassName}/{objectId}/{sessionId}", produces="application/json") public List<BusinessObjectLight> getPhysicalPath(@PathVariable("objectClassName") String objectClassName, @PathVariable("objectId") String objectId, @PathVariable("sessionId") String sessionId)
Finds the physical path from one port to another.- Specified by:
getPhysicalPath
in interfacePhysicalConnectionRestOpenApi
- Parameters:
objectClassName
- The source port class name.objectId
- The source port id.sessionId
- The session token id.- Returns:
- A list of objects that make part of the physical trace.
-
getPhysicalTree
@RequestMapping(method=GET, value="getPhysicalTree/{objectClassName}/{objectId}/{sessionId}", produces="application/json") public HashMap<BusinessObjectLight,List<BusinessObjectLight>> getPhysicalTree(@PathVariable("objectClassName") String objectClassName, @PathVariable("objectId") String objectId, @PathVariable("sessionId") String sessionId)
Gets A tree representation of all physical paths as a hash map.- Specified by:
getPhysicalTree
in interfacePhysicalConnectionRestOpenApi
- Parameters:
objectClassName
- The source port class name.objectId
- The source port id.sessionId
- The session token id.- Returns:
- A tree representation of all physical paths as a hash map.
-
-