blob: a16e1364b6f8307028885fa26e3fbd8b1294d1d5 [file] [log] [blame]
Pankaj Berdeda809572013-02-22 15:31:20 -08001package net.onrc.onos.util;
2
HIGUCHI Yuta20514902013-06-12 11:24:16 -07003import net.onrc.onos.ofcontroller.core.INetMapTopologyObjects.IDeviceObject;
4import net.onrc.onos.ofcontroller.core.INetMapTopologyObjects.IFlowEntry;
5import net.onrc.onos.ofcontroller.core.INetMapTopologyObjects.IFlowPath;
6import net.onrc.onos.ofcontroller.core.INetMapTopologyObjects.IPortObject;
7import net.onrc.onos.ofcontroller.core.INetMapTopologyObjects.ISwitchObject;
HIGUCHI Yuta356086e2013-06-12 15:21:19 -07008import net.onrc.onos.ofcontroller.util.FlowEntryId;
9import net.onrc.onos.ofcontroller.util.FlowId;
Pankaj Berdeda809572013-02-22 15:31:20 -080010
11public interface IDBUtils {
12 public ISwitchObject searchSwitch(GraphDBConnection conn, String dpid);
Pavlin Radoslavovf6fa7f02013-03-28 16:40:48 -070013 public ISwitchObject searchActiveSwitch(GraphDBConnection conn, String dpid);
Pankaj Berde15193092013-03-21 17:30:14 -070014 public Iterable<ISwitchObject> getActiveSwitches(GraphDBConnection conn);
15 public Iterable<ISwitchObject> getAllSwitches(GraphDBConnection conn);
16 public Iterable<ISwitchObject> getInactiveSwitches(GraphDBConnection conn);
17
18
Pankaj Berdeda809572013-02-22 15:31:20 -080019 public IDeviceObject searchDevice(GraphDBConnection conn, String macAddr);
20 public IDeviceObject newDevice(GraphDBConnection conn);
21 public void removeDevice(GraphDBConnection conn, IDeviceObject dev);
22 public IPortObject searchPort(GraphDBConnection conn, String dpid, short number);
Pankaj Berdeac1a8c32013-02-26 17:45:57 -080023 public Iterable<IDeviceObject> getDevices(GraphDBConnection conn);
Pavlin Radoslavovb6f53542013-03-01 16:02:14 -080024 public IFlowPath searchFlowPath(GraphDBConnection conn, FlowId flowId);
25 public IFlowPath newFlowPath(GraphDBConnection conn);
26 public void removeFlowPath(GraphDBConnection conn, IFlowPath flowPath);
27 public IFlowPath getFlowPathByFlowEntry(GraphDBConnection conn,
28 IFlowEntry flowEntry);
Pavlin Radoslavov706df052013-03-06 10:49:07 -080029 public Iterable<IFlowPath> getAllFlowPaths(GraphDBConnection conn);
Pavlin Radoslavovb6f53542013-03-01 16:02:14 -080030 public IFlowEntry searchFlowEntry(GraphDBConnection conn,
31 FlowEntryId flowEntryId);
32 public IFlowEntry newFlowEntry(GraphDBConnection conn);
33 public void removeFlowEntry(GraphDBConnection conn,
34 IFlowEntry flowEntry);
35 public Iterable<IFlowEntry> getAllFlowEntries(GraphDBConnection conn);
Pankaj Berde15193092013-03-21 17:30:14 -070036 public IPortObject newPort(GraphDBConnection conn);
37 ISwitchObject newSwitch(GraphDBConnection conn);
38 void removePort(GraphDBConnection conn, IPortObject port);
39 void removeSwitch(GraphDBConnection conn, ISwitchObject sw);
Pankaj Berde5d506412013-04-23 15:03:02 -070040 Iterable<IFlowEntry> getAllSwitchNotUpdatedFlowEntries(GraphDBConnection conn);
Pankaj Berdeda809572013-02-22 15:31:20 -080041}