diff options
author | CNlucius <lukai1@huawei.com> | 2016-09-13 11:40:12 +0800 |
---|---|---|
committer | CNlucius <lukai1@huawei.com> | 2016-09-13 11:41:53 +0800 |
commit | b731e2f1dd0972409b136aebc7b463dd72c9cfad (patch) | |
tree | 5107d7d80c19ad8076c2c97c2b5ef8d1cf3ab903 /framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table | |
parent | ee93993458266114c29271a481ef9ce7ce621b2a (diff) |
ONOSFW-171
O/S-SFC-ONOS scenario documentation
Change-Id: I51ae1cf736ea24ab6680f8edca1b2bf5dd598365
Signed-off-by: CNlucius <lukai1@huawei.com>
Diffstat (limited to 'framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table')
19 files changed, 0 insertions, 5331 deletions
diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Bridge.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Bridge.java deleted file mode 100644 index 0b5ffeff..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Bridge.java +++ /dev/null @@ -1,560 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.OvsdbSet; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.notation.UUID; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -import java.util.Map; -import java.util.Set; - -/** - * This class provides operations of Bridge Table. - */ -public class Bridge extends AbstractOvsdbTableService { - - /** - * Bridge table column name. - */ - public enum BridgeColumn { - NAME("name"), DATAPATHTYPE("datapath_type"), DATAPATHID("datapath_id"), - STPENABLE("stpenable"), PORTS("ports"), MIRRORS("mirrors"), - NETFLOW("netflow"), SFLOW("sflow"), IPFIX("ipfix"), - CONTROLLER("controller"), PROTOCOLS("protocols"), - FAILMODE("fail_mode"), STATUS("status"), OTHERCONFIG("other_config"), - EXTERNALIDS("external_ids"), FLOODVLANS("flood_vlans"), - FLOWTABLES("flow_tables"); - - private final String columnName; - - private BridgeColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for BridgeColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Bridge object. Generate Bridge Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Bridge(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.BRIDGE, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "name" from the Row entity of - * attributes. - * @return the Column entity which column name is "name" - */ - public Column getNameColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.NAME - .columnName(), - "getNameColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "name" to the Row entity of - * attributes. - * @param name the column data which column name is "name" - */ - public void setName(String name) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.NAME - .columnName(), - "setName", - VersionNum.VERSION100); - super.setDataHandler(columndesc, name); - } - - /** - * Get the column data which column name is "name" from the Row entity of - * attributes. - * @return the column data which column name is "name" - */ - public String getName() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.NAME - .columnName(), - "getName", - VersionNum.VERSION100); - return (String) super.getDataHandler(columndesc); - } - - /** - * Get the Column entity which column name is "datapath_type" from the Row - * entity of attributes. - * @return the Column entity which column name is "datapath_type" - */ - public Column getDatapathTypeColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.DATAPATHTYPE - .columnName(), - "getDatapathTypeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "datapath_type" to the Row - * entity of attributes. - * @param datapathType the column data which column name is "datapath_type" - */ - public void setDatapathType(String datapathType) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.DATAPATHTYPE - .columnName(), - "setDatapathType", - VersionNum.VERSION100); - super.setDataHandler(columndesc, datapathType); - } - - /** - * Get the Column entity which column name is "datapath_id" from the Row - * entity of attributes. - * @return the Column entity which column name is "datapath_id" - */ - public Column getDatapathIdColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.DATAPATHID - .columnName(), - "getDatapathIdColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "datapath_id" to the Row entity - * of attributes. - * @param datapathId the column data which column name is "datapath_id" - */ - public void setDatapathId(Set<String> datapathId) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.DATAPATHID - .columnName(), - "setDatapathId", - VersionNum.VERSION100); - super.setDataHandler(columndesc, datapathId); - } - - /** - * Get the Column entity which column name is "stpenable" from the Row - * entity of attributes. - * @return the Column entity which column name is "stpenable" - */ - public Column getStpEnableColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.STPENABLE - .columnName(), - "getStpEnableColumn", - VersionNum.VERSION620); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "stpenable" to the Row entity of - * attributes. - * @param stpenable the column data which column name is "stpenable" - */ - public void setStpEnable(Boolean stpenable) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.STPENABLE - .columnName(), - "setStpEnable", - VersionNum.VERSION620); - super.setDataHandler(columndesc, stpenable); - } - - /** - * Get the Column entity which column name is "ports" from the Row entity of - * attributes. - * @return the Column entity which column name is "ports" - */ - public Column getPortsColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.PORTS - .columnName(), - "getPortsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ports" to the Row entity of - * attributes. - * @param ports the column data which column name is "ports" - */ - public void setPorts(Set<UUID> ports) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.PORTS - .columnName(), - "setPorts", - VersionNum.VERSION100); - super.setDataHandler(columndesc, ports); - } - - /** - * Get the Column entity which column name is "mirrors" from the Row entity - * of attributes. - * @return the Column entity which column name is "mirrors" - */ - public Column getMirrorsColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.MIRRORS - .columnName(), - "getMirrorsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "mirrors" to the Row entity of - * attributes. - * @param mirrors the column data which column name is "mirrors" - */ - public void setMirrors(Set<UUID> mirrors) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.MIRRORS - .columnName(), - "setMirrors", - VersionNum.VERSION100); - super.setDataHandler(columndesc, mirrors); - } - - /** - * Get the Column entity which column name is "netflow" from the Row entity - * of attributes. - * @return the Column entity which column name is "netflow" - */ - public Column getNetflowColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.NETFLOW - .columnName(), - "getNetflowColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "netflow" to the Row entity of - * attributes. - * @param netflow the column data which column name is "netflow" - */ - public void setNetflow(Set<UUID> netflow) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.NETFLOW - .columnName(), - "setNetflow", - VersionNum.VERSION100); - super.setDataHandler(columndesc, netflow); - } - - /** - * Get the Column entity which column name is "sflow" from the Row entity of - * attributes. - * @return the Column entity which column name is "sflow" - */ - public Column getSflowColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.SFLOW - .columnName(), - "getSflowColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "sflow" to the Row entity of - * attributes. - * @param sflow the column data which column name is "sflow" - */ - public void setSflow(Set<UUID> sflow) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.SFLOW - .columnName(), - "setSflow", - VersionNum.VERSION100); - super.setDataHandler(columndesc, sflow); - } - - /** - * Get the Column entity which column name is "ipfix" from the Row entity of - * attributes. - * @return the Column entity which column name is "ipfix" - */ - public Column getIpfixColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.IPFIX - .columnName(), - "getIpfixColumn", - VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ipfix" to the Row entity of - * attributes. - * @param ipfix the column data which column name is "ipfix" - */ - public void setIpfix(Set<UUID> ipfix) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.IPFIX - .columnName(), - "setIpfix", - VersionNum.VERSION710); - super.setDataHandler(columndesc, ipfix); - } - - /** - * Get the Column entity which column name is "controller" from the Row - * entity of attributes. - * @return the Column entity which column name is "controller" - */ - public Column getControllerColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.CONTROLLER - .columnName(), - "getControllerColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "controller" to the Row entity - * of attributes. - * @param controller the column data which column name is "controller" - */ - public void setController(OvsdbSet controller) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.CONTROLLER - .columnName(), - "setController", - VersionNum.VERSION100); - super.setDataHandler(columndesc, controller); - } - - /** - * Get the Column entity which column name is "protocols" from the Row - * entity of attributes. - * @return the Column entity which column name is "protocols" - */ - public Column getProtocolsColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.PROTOCOLS - .columnName(), - "getProtocolsColumn", - VersionNum.VERSION6111); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "protocols" to the Row entity of - * attributes. - * @param protocols the column data which column name is "protocols" - */ - public void setProtocols(Set<String> protocols) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.PROTOCOLS - .columnName(), - "setProtocols", - VersionNum.VERSION6111); - super.setDataHandler(columndesc, protocols); - } - - /** - * Get the Column entity which column name is "fail_mode" from the Row - * entity of attributes. - * @return the Column entity which column name is "fail_mode" - */ - public Column getFailModeColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.FAILMODE - .columnName(), - "getFailModeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "fail_mode" to the Row entity of - * attributes. - * @param failMode the column data which column name is "fail_mode" - */ - public void setFailMode(Set<String> failMode) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.FAILMODE - .columnName(), - "setFailMode", - VersionNum.VERSION100); - super.setDataHandler(columndesc, failMode); - } - - /** - * Get the Column entity which column name is "status" from the Row entity - * of attributes. - * @return the Column entity which column name is "status" - */ - public Column getStatusColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.STATUS - .columnName(), - "getStatusColumn", - VersionNum.VERSION620); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "status" to the Row entity of - * attributes. - * @param status the column data which column name is "status" - */ - public void setStatus(Map<String, String> status) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.STATUS - .columnName(), - "setStatus", - VersionNum.VERSION620); - super.setDataHandler(columndesc, status); - } - - /** - * Get the Column entity which column name is "other_config" from the Row - * entity of attributes. - * @return the Column entity which column name is "other_config" - */ - public Column getOtherConfigColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.OTHERCONFIG - .columnName(), - "getOtherConfigColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "other_config" to the Row entity - * of attributes. - * @param otherConfig the column data which column name is "other_config" - */ - public void setOtherConfig(Map<String, String> otherConfig) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.OTHERCONFIG - .columnName(), - "setOtherConfig", - VersionNum.VERSION100); - super.setDataHandler(columndesc, otherConfig); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.EXTERNALIDS - .columnName(), - "getExternalIdsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.EXTERNALIDS - .columnName(), - "setExternalIds", - VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "flood_vlans" from the Row - * entity of attributes. - * @return the Column entity which column name is "flood_vlans" - */ - public Column getFloodVlansColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.FLOODVLANS - .columnName(), - "getFloodVlansColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "flood_vlans" to the Row entity - * of attributes. - * @param vlans the column data which column name is "flood_vlans" - */ - public void setFloodVlans(Set<Long> vlans) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.FLOODVLANS - .columnName(), - "setFloodVlans", - VersionNum.VERSION100); - super.setDataHandler(columndesc, vlans); - } - - /** - * Get the Column entity which column name is "flow_tables" from the Row - * entity of attributes. - * @return the Column entity which column name is "flow_tables" - */ - public Column getFlowTablesColumn() { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.FLOWTABLES - .columnName(), - "getFlowTablesColumn", - VersionNum.VERSION650); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "flow_tables" to the Row entity - * of attributes. - * @param flowTables the column data which column name is "flow_tables" - */ - public void setFlowTables(Map<Long, UUID> flowTables) { - ColumnDescription columndesc = new ColumnDescription( - BridgeColumn.FLOWTABLES - .columnName(), - "setFlowTables", - VersionNum.VERSION650); - super.setDataHandler(columndesc, flowTables); - } - -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Controller.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Controller.java deleted file mode 100644 index 912526cc..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Controller.java +++ /dev/null @@ -1,556 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Controller Table. - */ -public class Controller extends AbstractOvsdbTableService { - - /** - * Controller table column name. - */ - public enum ControllerColumn { - TARGET("target"), BURSTLIMIT("controller_burst_limit"), - RATELIMIT("controller_rate_limit"), CONNECTIONMODE("connection_mode"), - ENABLEASYNCMESSAGES("enable_async_messages"), - EXTERNALIDS("external_ids"), LOCALNETMASK("local_netmask"), - LOCALGATEWAY("local_gateway"), STATUS("status"), ROLE("role"), - INACTIVITYPROBE("inactivity_probe"), ISCONNECTED("is_connected"), - OTHERCONFIG("other_config"), MAXBACKOFF("max_backoff"), - LOCALIP("local_ip"), - DISCOVERUPDATERESOLVCONF("discover_update_resolv_conf"), - DISCOVERACCEPTREGEX("discover_accept_regex"); - - private final String columnName; - - private ControllerColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for ControllerColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Controller object. Generate Controller Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Controller(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.CONTROLLER, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "target" from the Row entity - * of attributes. - * @return the Column entity which column name is "target" - */ - public Column getTargetColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.TARGET - .columnName(), - "getTargetColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "target" to the Row entity of - * attributes. - * @param target the column data which column name is "target" - */ - public void setTarget(String target) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.TARGET - .columnName(), - "setTarget", - VersionNum.VERSION100); - super.setDataHandler(columndesc, target); - } - - /** - * Get the Column entity which column name is "controller_burst_limit" from - * the Row entity of attributes. - * @return the Column entity which column name is "controller_burst_limit" - */ - public Column getBurstLimitColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.BURSTLIMIT - .columnName(), - "getBurstLimitColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "controller_burst_limit" to the - * Row entity of attributes. - * @param burstLimit the column data which column name is - * "controller_burst_limit" - */ - public void setBurstLimit(Long burstLimit) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.BURSTLIMIT - .columnName(), - "setBurstLimit", - VersionNum.VERSION100); - super.setDataHandler(columndesc, burstLimit); - } - - /** - * Get the Column entity which column name is "controller_rate_limit" from - * the Row entity of attributes. - * @return the Column entity which column name is "controller_rate_limit" - */ - public Column getRateLimitColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.RATELIMIT - .columnName(), - "getRateLimitColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "controller_rate_limit" to the - * Row entity of attributes. - * @param rateLimit the column data which column name is - * "controller_rate_limit" - */ - public void setRateLimit(Long rateLimit) { - ColumnDescription columndesc = new ColumnDescription( - "controller_rate_limit", - "setRateLimit", - VersionNum.VERSION100); - super.setDataHandler(columndesc, rateLimit); - } - - /** - * Get the Column entity which column name is "connection_mode" from the Row - * entity of attributes. - * @return the Column entity which column name is "connection_mode" - */ - public Column getConnectionModeColumn() { - ColumnDescription columndesc = new ColumnDescription( - "connection_mode", - "getConnectionModeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "connection_mode" to the Row - * entity of attributes. - * @param connectionMode the column data which column name is - * "connection_mode" - */ - public void setConnectionMode(Set<String> connectionMode) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.RATELIMIT - .columnName(), - "setConnectionMode", - VersionNum.VERSION100); - super.setDataHandler(columndesc, connectionMode); - } - - /** - * Get the Column entity which column name is "enable_async_messages" from - * the Row entity of attributes. - * @return the Column entity which column name is "enable_async_messages" - */ - public Column getEnableAsyncMessagesColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.ENABLEASYNCMESSAGES - .columnName(), - "getEnableAsyncMessagesColumn", - VersionNum.VERSION670); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "enable_async_messages" to the - * Row entity of attributes. - * @param enableAsyncMessages the column data which column name is - * "enable_async_messages" - */ - public void setEnableAsyncMessages(Set<Boolean> enableAsyncMessages) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.ENABLEASYNCMESSAGES - .columnName(), - "setEnableAsyncMessages", - VersionNum.VERSION670); - super.setDataHandler(columndesc, enableAsyncMessages); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.EXTERNALIDS - .columnName(), - "getExternalIdsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.EXTERNALIDS - .columnName(), - "setExternalIds", - VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "local_netmask" from the Row - * entity of attributes. - * @return the Column entity which column name is "local_netmask" - */ - public Column getLocalNetmaskColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.LOCALNETMASK - .columnName(), - "getLocalNetmaskColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "local_netmask" to the Row - * entity of attributes. - * @param localNetmask the column data which column name is "local_netmask" - */ - public void setLocalNetmask(Set<String> localNetmask) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.LOCALNETMASK - .columnName(), - "setLocalNetmask", - VersionNum.VERSION100); - super.setDataHandler(columndesc, localNetmask); - } - - /** - * Get the Column entity which column name is "local_gateway" from the Row - * entity of attributes. - * @return the Column entity which column name is "local_gateway" - */ - public Column getLocalGatewayColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.LOCALGATEWAY - .columnName(), - "getLocalGatewayColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "local_gateway" to the Row - * entity of attributes. - * @param localGateway the column data which column name is "local_gateway" - */ - public void setLocalGateway(Set<String> localGateway) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.LOCALGATEWAY - .columnName(), - "setLocalGateway", - VersionNum.VERSION100); - super.setDataHandler(columndesc, localGateway); - } - - /** - * Get the Column entity which column name is "status" from the Row entity - * of attributes. - * @return the Column entity which column name is "status" - */ - public Column getStatusColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.STATUS - .columnName(), - "getStatusColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "status" to the Row entity of - * attributes. - * @param status the column data which column name is "status" - */ - public void setStatus(Map<String, String> status) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.STATUS - .columnName(), - "setStatus", - VersionNum.VERSION100); - super.setDataHandler(columndesc, status); - } - - /** - * Get the Column entity which column name is "role" from the Row entity of - * attributes. - * @return the Column entity which column name is "role" - */ - public Column getRoleColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.ROLE - .columnName(), - "getRoleColumn", - VersionNum.VERSION110); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "role" to the Row entity of - * attributes. - * @param role the column data which column name is "role" - */ - public void setRole(Set<String> role) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.ROLE - .columnName(), - "setRole", - VersionNum.VERSION110); - super.setDataHandler(columndesc, role); - } - - /** - * Get the Column entity which column name is "inactivity_probe" from the - * Row entity of attributes. - * @return the Column entity which column name is "inactivity_probe" - */ - public Column getInactivityProbeColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.INACTIVITYPROBE - .columnName(), - "getInactivityProbeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "inactivity_probe" to the Row - * entity of attributes. - * @param inactivityProbe the column data which column name is - * "inactivity_probe" - */ - public void setInactivityProbe(Set<Long> inactivityProbe) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.INACTIVITYPROBE - .columnName(), - "setInactivityProbe", - VersionNum.VERSION100); - super.setDataHandler(columndesc, inactivityProbe); - } - - /** - * Get the Column entity which column name is "is_connected" from the Row - * entity of attributes. - * @return the Column entity which column name is "is_connected" - */ - public Column getIsConnectedColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.ISCONNECTED - .columnName(), - "getIsConnectedColumn", - VersionNum.VERSION110); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "is_connected" to the Row entity - * of attributes. - * @param isConnected the column data which column name is "is_connected" - */ - public void setIsConnected(Boolean isConnected) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.ISCONNECTED - .columnName(), - "setIsConnected", - VersionNum.VERSION110); - super.setDataHandler(columndesc, isConnected); - } - - /** - * Get the Column entity which column name is "other_config" from the Row - * entity of attributes. - * @return the Column entity which column name is "other_config" - */ - public Column getOtherConfigColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.OTHERCONFIG - .columnName(), - "getOtherConfigColumn", - VersionNum.VERSION680); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "other_config" to the Row entity - * of attributes. - * @param otherConfig the column data which column name is "other_config" - */ - public void setOtherConfig(Map<String, String> otherConfig) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.OTHERCONFIG - .columnName(), - "setOtherConfig", - VersionNum.VERSION680); - super.setDataHandler(columndesc, otherConfig); - } - - /** - * Get the Column entity which column name is "max_backoff" from the Row - * entity of attributes. - * @return the Column entity which column name is "max_backoff" - */ - public Column getMaxBackoffColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.MAXBACKOFF - .columnName(), - "getMaxBackoffColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "max_backoff" to the Row entity - * of attributes. - * @param maxBackoff the column data which column name is "max_backoff" - */ - public void setMaxBackoff(Long maxBackoff) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.MAXBACKOFF - .columnName(), - "setMaxBackoff", - VersionNum.VERSION100); - super.setDataHandler(columndesc, maxBackoff); - } - - /** - * Get the Column entity which column name is "local_ip" from the Row entity - * of attributes. - * @return the Column entity which column name is "local_ip" - */ - public Column getLocalIpColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.LOCALIP - .columnName(), - "getLocalIpColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "local_ip" to the Row entity of - * attributes. - * @param localIp the column data which column name is "local_ip" - */ - public void setLocalIp(Set<String> localIp) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.LOCALIP - .columnName(), - "setLocalIp", - VersionNum.VERSION100); - super.setDataHandler(columndesc, localIp); - } - - /** - * Get the Column entity which column name is "discover_update_resolv_conf" - * from the Row entity of attributes. - * @return the Column entity which column name is - * "discover_update_resolv_conf" - */ - public Column getDiscoverUpdateResolvConfColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.DISCOVERUPDATERESOLVCONF - .columnName(), - "getDiscoverUpdateResolvConfColumn", - VersionNum.VERSION100, - VersionNum.VERSION300); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "discover_update_resolv_conf" to - * the Row entity of attributes. - * @param discoverUpdateResolvConf the column data which column name is - * "discover_update_resolv_conf" - */ - public void setDiscoverUpdateResolvConf(Set<String> discoverUpdateResolvConf) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.DISCOVERUPDATERESOLVCONF - .columnName(), - "setDiscoverUpdateResolvConf", - VersionNum.VERSION100, - VersionNum.VERSION300); - super.setDataHandler(columndesc, discoverUpdateResolvConf); - } - - /** - * Get the Column entity which column name is "discover_accept_regex" from - * the Row entity of attributes. - * @return the Column entity which column name is "discover_accept_regex" - */ - public Column getDiscoverAcceptRegexColumn() { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.DISCOVERACCEPTREGEX - .columnName(), - "getDiscoverAcceptRegexColumn", - VersionNum.VERSION100, - VersionNum.VERSION300); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "discover_accept_regex" to the - * Row entity of attributes. - * @param discoverAcceptRegex the column data which column name is - * "discover_accept_regex" - */ - public void setDiscoverAcceptRegex(Set<String> discoverAcceptRegex) { - ColumnDescription columndesc = new ColumnDescription( - ControllerColumn.DISCOVERACCEPTREGEX - .columnName(), - "setDiscoverAcceptRegex", - VersionNum.VERSION100, - VersionNum.VERSION300); - super.setDataHandler(columndesc, discoverAcceptRegex); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/FlowSampleCollectorSet.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/FlowSampleCollectorSet.java deleted file mode 100644 index 05a0354f..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/FlowSampleCollectorSet.java +++ /dev/null @@ -1,151 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.notation.UUID; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of FlowSampleCollectorSet Table. - */ -public class FlowSampleCollectorSet extends AbstractOvsdbTableService { - /** - * FlowSampleCollectorSet table column name. - */ - public enum FlowSampleCollectorSetColumn { - ID("id"), BRIDGE("bridge"), IPFIX("ipfix"), EXTERNALIDS("external_ids"); - - private final String columnName; - - private FlowSampleCollectorSetColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for FlowSampleCollectorSetColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a FlowSampleCollectorSet object. Generate - * FlowSampleCollectorSet Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public FlowSampleCollectorSet(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.FLOWSAMPLECOLLECTORSET, VersionNum.VERSION710); - } - - /** - * Get the Column entity which column name is "id" from the Row entity of - * attributes. - * @return the Column entity which column name is "id" - */ - public Column getIdColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowSampleCollectorSetColumn.ID.columnName(), - "getIdColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "id" to the Row entity of - * attributes. - * @param id the column data which column name is "id" - */ - public void setId(Long id) { - ColumnDescription columndesc = new ColumnDescription(FlowSampleCollectorSetColumn.ID.columnName(), - "setId", VersionNum.VERSION710); - super.setDataHandler(columndesc, id); - } - - /** - * Get the Column entity which column name is "bridge" from the Row entity - * of attributes. - * @return the Column entity which column name is "bridge" - */ - public Column getBridgeColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowSampleCollectorSetColumn.BRIDGE.columnName(), - "getBridgeColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bridge" to the Row entity of - * attributes. - * @param bridge the column data which column name is "bridge" - */ - public void setBridge(UUID bridge) { - ColumnDescription columndesc = new ColumnDescription(FlowSampleCollectorSetColumn.BRIDGE.columnName(), - "setBridge", VersionNum.VERSION710); - super.setDataHandler(columndesc, bridge); - } - - /** - * Get the Column entity which column name is "ipfix" from the Row entity of - * attributes. - * @return the Column entity which column name is "ipfix" - */ - public Column getIpfixColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowSampleCollectorSetColumn.IPFIX.columnName(), - "getIpfixColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ipfix" to the Row entity of - * attributes. - * @param ipfix the column data which column name is "ipfix" - */ - public void setIpfix(UUID ipfix) { - ColumnDescription columndesc = new ColumnDescription(FlowSampleCollectorSetColumn.IPFIX.columnName(), - "setIpfix", VersionNum.VERSION710); - super.setDataHandler(columndesc, ipfix); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowSampleCollectorSetColumn.EXTERNALIDS - .columnName(), - "getExternalIdsColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(FlowSampleCollectorSetColumn.EXTERNALIDS - .columnName(), - "setExternalIds", VersionNum.VERSION710); - super.setDataHandler(columndesc, externalIds); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/FlowTable.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/FlowTable.java deleted file mode 100644 index ed1c217a..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/FlowTable.java +++ /dev/null @@ -1,196 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of FlowTable Table. - */ -public class FlowTable extends AbstractOvsdbTableService { - /** - * FlowTable table column name. - */ - public enum FlowTableColumn { - FLOWLIMIT("flow_limit"), OVERFLOWPOLICY("overflow_policy"), GROUPS("groups"), NAME("name"), - PREFIXES("prefixes"), EXTERNALIDS("external_ids"); - - private final String columnName; - - private FlowTableColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for FlowTableColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a FlowTable object. Generate FlowTable Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public FlowTable(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.FLWTABLE, VersionNum.VERSION650); - } - - /** - * Get the Column entity which column name is "flow_limit" from the Row - * entity of attributes. - * @return the Column entity which column name is "flow_limit" - */ - public Column getFlowLimitColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.FLOWLIMIT.columnName(), - "getFlowLimitColumn", VersionNum.VERSION650); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "flow_limit" to the Row entity - * of attributes. - * @param flowLimit the column data which column name is "flow_limit" - */ - public void setFlowLimit(Set<Long> flowLimit) { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.FLOWLIMIT.columnName(), - "setFlowLimit", VersionNum.VERSION650); - super.setDataHandler(columndesc, flowLimit); - } - - /** - * Get the Column entity which column name is "overflow_policy" from the Row - * entity of attributes. - * @return the Column entity which column name is "overflow_policy" - */ - public Column getOverflowPolicyColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.OVERFLOWPOLICY.columnName(), - "getOverflowPolicyColumn", VersionNum.VERSION650); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "overflow_policy" to the Row - * entity of attributes. - * @param overflowPolicy the column data which column name is - * "overflow_policy" - */ - public void setOverflowPolicy(Set<String> overflowPolicy) { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.OVERFLOWPOLICY.columnName(), - "setOverflowPolicy", VersionNum.VERSION650); - super.setDataHandler(columndesc, overflowPolicy); - } - - /** - * Get the Column entity which column name is "groups" from the Row entity - * of attributes. - * @return the Column entity which column name is "groups" - */ - public Column getGroupsColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.GROUPS.columnName(), - "getGroupsColumn", VersionNum.VERSION650); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "groups" to the Row entity of - * attributes. - * @param groups the column data which column name is "groups" - */ - public void setGroups(Set<String> groups) { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.GROUPS.columnName(), - "setGroups", VersionNum.VERSION650); - super.setDataHandler(columndesc, groups); - } - - /** - * Get the Column entity which column name is "name" from the Row entity of - * attributes. - * @return the Column entity which column name is "name" - */ - public Column getNameColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.NAME.columnName(), - "getNameColumn", VersionNum.VERSION650); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "name" to the Row entity of - * attributes. - * @param name the column data which column name is "name" - */ - public void setName(Set<String> name) { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.NAME.columnName(), - "setName", - VersionNum.VERSION650); - super.setDataHandler(columndesc, name); - } - - /** - * Get the Column entity which column name is "prefixes" from the Row entity - * of attributes. - * @return the Column entity which column name is "prefixes" - */ - public Column getPrefixesColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.PREFIXES.columnName(), - "getPrefixesColumn", VersionNum.VERSION740); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "prefixes" to the Row entity of - * attributes. - * @param prefixes the column data which column name is "prefixes" - */ - public void setPrefixes(Set<String> prefixes) { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.PREFIXES.columnName(), - "setPrefixes", VersionNum.VERSION740); - super.setDataHandler(columndesc, prefixes); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION750); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(FlowTableColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION750); - super.setDataHandler(columndesc, externalIds); - } - -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Interface.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Interface.java deleted file mode 100644 index ee946287..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Interface.java +++ /dev/null @@ -1,1024 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Interface Table. - */ -public class Interface extends AbstractOvsdbTableService { - - /** - * Interface table column name. - */ - public enum InterfaceColumn { - NAME("name"), TYPE("type"), OPTIONS("options"), - INGRESSPOLICINGRATE("ingress_policing_rate"), - INGRESSPOLICINGBURST("ingress_policing_burst"), MACINUSE("mac_in_use"), - MAC("mac"), IFINDEX("ifindex"), EXTERNALIDS("external_ids"), - OFPORT("ofport"), OFPORTREQUEST("ofport_request"), BFD("bfd"), - BFDSTATUS("bfd_status"), MONITOR("monitor"), CFMMPID("cfm_mpid"), - CFMREMOTEMPID("cfm_remote_mpid"), CFMREMOTEMPIDS("cfm_remote_mpids"), - CFMFLAPCOUNT("cfm_flap_count"), CFMFAULT("cfm_fault"), - CFMFAULTSTATUS("cfm_fault_status"), - CFMREMOTEOPSTATE("cfm_remote_opstate"), CFMHEALTH("cfm_health"), - LACPCURRENT("lacp_current"), OTHERCONFIG("other_config"), - STATISTICS("statistics"), STATUS("status"), ADMINSTATE("admin_state"), - LINKSTATE("link_state"), LINKRESETS("link_resets"), - LINKSPEED("link_speed"), DUPLEX("duplex"), MTU("mtu"), ERROR("error"); - - private final String columnName; - - private InterfaceColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for InterfaceColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Interface object. Generate Interface Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Interface(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.INTERFACE, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "name" from the Row entity of - * attributes. - * @return the Column entity which column name is "name" - */ - public Column getNameColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.NAME - .columnName(), - "getNameColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "name" to the Row entity of - * attributes. - * @param name the column data which column name is "name" - */ - public void setName(String name) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.NAME - .columnName(), - "setName", - VersionNum.VERSION100); - super.setDataHandler(columndesc, name); - } - - /** - * Get the column data which column name is "name" from the Row entity of - * attributes. - * @return the column data which column name is "name" - */ - public String getName() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.NAME - .columnName(), - "getName", - VersionNum.VERSION100); - return (String) super.getDataHandler(columndesc); - } - - /** - * Get the Column entity which column name is "type" from the Row entity of - * attributes. - * @return the Column entity which column name is "type" - */ - public Column getTypeColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.TYPE - .columnName(), - "getTypeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "type" to the Row entity of - * attributes. - * @param type the column data which column name is "type" - */ - public void setType(String type) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.TYPE - .columnName(), - "setType", - VersionNum.VERSION100); - super.setDataHandler(columndesc, type); - } - - /** - * Get the Column entity which column name is "options" from the Row entity - * of attributes. - * @return the Column entity which column name is "options" - */ - public Column getOptionsColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.OPTIONS - .columnName(), - "getOptionsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "options" to the Row entity of - * attributes. - * @param options the column data which column name is "options" - */ - public void setOptions(Map<String, String> options) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.OPTIONS - .columnName(), - "setOptions", - VersionNum.VERSION100); - super.setDataHandler(columndesc, options); - } - - /** - * Get the Column entity which column name is "ingress_policing_rate" from - * the Row entity of attributes. - * @return the Column entity which column name is "ingress_policing_rate" - */ - public Column getIngressPolicingRateColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.INGRESSPOLICINGRATE - .columnName(), - "getIngressPolicingRateColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ingress_policing_rate" to the - * Row entity of attributes. - * @param ingressPolicingRate the column data which column name is - * "ingress_policing_rate" - */ - public void setIngressPolicingRate(Set<Long> ingressPolicingRate) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.INGRESSPOLICINGRATE - .columnName(), - "setIngressPolicingRate", - VersionNum.VERSION100); - super.setDataHandler(columndesc, ingressPolicingRate); - } - - /** - * Get the Column entity which column name is "ingress_policing_burst" from - * the Row entity of attributes. - * @return the Column entity which column name is "ingress_policing_burst" - */ - public Column getIngressPolicingBurstColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.INGRESSPOLICINGBURST - .columnName(), - "getIngressPolicingBurstColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ingress_policing_burst" to the - * Row entity of attributes. - * @param ingressPolicingBurst the column data which column name is - * "ingress_policing_burst" - */ - public void setIngressPolicingBurst(Set<Long> ingressPolicingBurst) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.INGRESSPOLICINGBURST - .columnName(), - "setIngressPolicingBurst", - VersionNum.VERSION100); - super.setDataHandler(columndesc, ingressPolicingBurst); - } - - /** - * Get the Column entity which column name is "mac_in_use" from the Row - * entity of attributes. - * @return the Column entity which column name is "mac_in_use" - */ - public Column getMacInUseColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.MACINUSE - .columnName(), - "getMacInUseColumn", - VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "mac_in_use" to the Row entity - * of attributes. - * @param macInUse the column data which column name is "mac_in_use" - */ - public void setMacInUse(Set<String> macInUse) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.MACINUSE - .columnName(), - "setMacInUse", - VersionNum.VERSION710); - super.setDataHandler(columndesc, macInUse); - } - - /** - * Get the Column entity which column name is "mac" from the Row entity of - * attributes. - * @return the Column entity which column name is "mac" - */ - public Column getMacColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.MAC - .columnName(), - "getMacColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "mac" to the Row entity of - * attributes. - * @param mac the column data which column name is "mac" - */ - public void setMac(Set<String> mac) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.MAC - .columnName(), - "setMac", - VersionNum.VERSION100); - super.setDataHandler(columndesc, mac); - } - - /** - * Get the Column entity which column name is "ifindex" from the Row entity - * of attributes. - * @return the Column entity which column name is "ifindex" - */ - public Column getIfIndexColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.IFINDEX - .columnName(), - "getIfIndexColumn", - VersionNum.VERSION721); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ifindex" to the Row entity of - * attributes. - * @param ifIndex the column data which column name is "ifindex" - */ - public void setIfIndex(Long ifIndex) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.IFINDEX - .columnName(), - "setIfIndex", - VersionNum.VERSION721); - super.setDataHandler(columndesc, ifIndex); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.EXTERNALIDS - .columnName(), - "getExternalIdsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.EXTERNALIDS - .columnName(), - "setExternalIds", - VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "ofport" from the Row entity - * of attributes. - * @return the Column entity which column name is "ofport" - */ - public Column getOpenFlowPortColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.OFPORT - .columnName(), - "getOpenFlowPortColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ofport" to the Row entity of - * attributes. - * @param openFlowPort the column data which column name is "ofport" - */ - public void setOpenFlowPort(Set<Long> openFlowPort) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.OFPORT - .columnName(), - "setOpenFlowPort", - VersionNum.VERSION100); - super.setDataHandler(columndesc, openFlowPort); - } - - /** - * Get the Column entity which column name is "ofport_request" from the Row - * entity of attributes. - * @return the Column entity which column name is "ofport_request" - */ - public Column getOpenFlowPortRequestColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.OFPORTREQUEST - .columnName(), - "getOpenFlowPortRequestColumn", - VersionNum.VERSION620); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ofport_request" to the Row - * entity of attributes. - * @param openFlowPortRequest the column data which column name is - * "ofport_request" - */ - public void setOpenFlowPortRequest(String openFlowPortRequest) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.OFPORTREQUEST - .columnName(), - "setOpenFlowPortRequest", - VersionNum.VERSION620); - super.setDataHandler(columndesc, openFlowPortRequest); - } - - /** - * Get the Column entity which column name is "bfd" from the Row entity of - * attributes. - * @return the Column entity which column name is "bfd" - */ - public Column getBfdColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.BFD - .columnName(), - "getBfdColumn", - VersionNum.VERSION720); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bfd" to the Row entity of - * attributes. - * @param bfd the column data which column name is "bfd" - */ - public void setBfd(Map<String, String> bfd) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.BFD - .columnName(), - "setBfd", - VersionNum.VERSION720); - super.setDataHandler(columndesc, bfd); - } - - /** - * Get the Column entity which column name is "bfd_status" from the Row - * entity of attributes. - * @return the Column entity which column name is "bfd_status" - */ - public Column getBfdStatusColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.BFDSTATUS - .columnName(), - "getBfdStatusColumn", - VersionNum.VERSION720); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bfd_status" to the Row entity - * of attributes. - * @param bfdStatus the column data which column name is "bfd_status" - */ - public void setBfdStatus(Map<String, String> bfdStatus) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.BFDSTATUS - .columnName(), - "setBfdStatus", - VersionNum.VERSION720); - super.setDataHandler(columndesc, bfdStatus); - } - - /** - * Get the Column entity which column name is "monitor" from the Row entity - * of attributes. - * @return the Column entity which column name is "monitor" - */ - public Column getMonitorColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.MONITOR - .columnName(), - "getMonitorColumn", - VersionNum.VERSION100, - VersionNum.VERSION350); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "monitor" to the Row entity of - * attributes. - * @param monitor the column data which column name is "monitor" - */ - public void setMonitor(String monitor) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.MONITOR - .columnName(), - "setMonitor", - VersionNum.VERSION100, - VersionNum.VERSION350); - super.setDataHandler(columndesc, monitor); - } - - /** - * Get the Column entity which column name is "cfm_mpid" from the Row entity - * of attributes. - * @return the Column entity which column name is "cfm_mpid" - */ - public Column getCfmMpidColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMMPID - .columnName(), - "getCfmMpidColumn", - VersionNum.VERSION400); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cfm_mpid" to the Row entity of - * attributes. - * @param cfmMpid the column data which column name is "cfm_mpid" - */ - public void setCfmMpid(Set<Long> cfmMpid) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMMPID - .columnName(), - "setCfmMpid", - VersionNum.VERSION400); - super.setDataHandler(columndesc, cfmMpid); - } - - /** - * Get the Column entity which column name is "cfm_remote_mpid" from the Row - * entity of attributes. - * @return the Column entity which column name is "cfm_remote_mpid" - */ - public Column getCfmRemoteMpidColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMREMOTEMPID - .columnName(), - "getCfmRemoteMpidColumn", - VersionNum.VERSION400, - VersionNum.VERSION520); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cfm_remote_mpid" to the Row - * entity of attributes. - * @param cfmRemoteMpid the column data which column name is - * "cfm_remote_mpid" - */ - public void setCfmRemoteMpid(Set<Long> cfmRemoteMpid) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMREMOTEMPID - .columnName(), - "setCfmRemoteMpid", - VersionNum.VERSION400, - VersionNum.VERSION520); - super.setDataHandler(columndesc, cfmRemoteMpid); - } - - /** - * Get the Column entity which column name is "cfm_remote_mpids" from the - * Row entity of attributes. - * @return the Column entity which column name is "cfm_remote_mpids" - */ - public Column getCfmRemoteMpidsColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMREMOTEMPIDS - .columnName(), - "getCfmRemoteMpidsColumn", - VersionNum.VERSION600); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cfm_remote_mpids" to the Row - * entity of attributes. - * @param cfmRemoteMpids the column data which column name is - * "cfm_remote_mpids" - */ - public void setCfmRemoteMpids(Set<Long> cfmRemoteMpids) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMREMOTEMPIDS - .columnName(), - "setCfmRemoteMpids", - VersionNum.VERSION600); - super.setDataHandler(columndesc, cfmRemoteMpids); - } - - /** - * Get the Column entity which column name is "cfm_flap_count" from the Row - * entity of attributes. - * @return the Column entity which column name is "cfm_flap_count" - */ - public Column getCfmFlapCountColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMFLAPCOUNT - .columnName(), - "getCfmFlapCountColumn", - VersionNum.VERSION730); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cfm_flap_count" to the Row - * entity of attributes. - * @param cfmFlapCount the column data which column name is "cfm_flap_count" - */ - public void setCfmFlapCount(Set<Long> cfmFlapCount) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMFLAPCOUNT - .columnName(), - "setCfmFlapCount", - VersionNum.VERSION730); - super.setDataHandler(columndesc, cfmFlapCount); - } - - /** - * Get the Column entity which column name is "cfm_fault" from the Row - * entity of attributes. - * @return the Column entity which column name is "cfm_fault" - */ - public Column getCfmFaultColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMFAULT - .columnName(), - "getCfmFaultColumn", - VersionNum.VERSION400); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cfm_fault" to the Row entity of - * attributes. - * @param cfmFault the column data which column name is "cfm_fault" - */ - public void setCfmFault(Set<Boolean> cfmFault) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMFAULT - .columnName(), - "setCfmFault", - VersionNum.VERSION400); - super.setDataHandler(columndesc, cfmFault); - } - - /** - * Get the Column entity which column name is "cfm_fault_status" from the - * Row entity of attributes. - * @return the Column entity which column name is "cfm_fault_status" - */ - public Column getCfmFaultStatusColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMFAULTSTATUS - .columnName(), - "getCfmFaultStatusColumn", - VersionNum.VERSION660); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cfm_fault_status" to the Row - * entity of attributes. - * @param cfmFaultStatus the column data which column name is - * "cfm_fault_status" - */ - public void setCfmFaultStatus(Set<String> cfmFaultStatus) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMFAULTSTATUS - .columnName(), - "setCfmFaultStatus", - VersionNum.VERSION660); - super.setDataHandler(columndesc, cfmFaultStatus); - } - - /** - * Get the Column entity which column name is "cfm_remote_opstate" from the - * Row entity of attributes. - * @return the Column entity which column name is "cfm_remote_opstate" - */ - public Column getCfmRemoteOpStateColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMREMOTEOPSTATE - .columnName(), - "getCfmRemoteOpStateColumn", - VersionNum.VERSION6100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cfm_remote_opstate" to the Row - * entity of attributes. - * @param cfmRemoteOpState the column data which column name is - * "cfm_remote_opstate" - */ - public void setCfmRemoteOpState(Set<String> cfmRemoteOpState) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMREMOTEOPSTATE - .columnName(), - "setCfmRemoteOpState", - VersionNum.VERSION6100); - super.setDataHandler(columndesc, cfmRemoteOpState); - } - - /** - * Get the Column entity which column name is "cfm_health" from the Row - * entity of attributes. - * @return the Column entity which column name is "cfm_health" - */ - public Column getCfmHealthColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMHEALTH - .columnName(), - "getCfmHealthColumn", - VersionNum.VERSION690); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cfm_health" to the Row entity - * of attributes. - * @param cfmHealth the column data which column name is "cfm_health" - */ - public void setCfmHealth(Set<Long> cfmHealth) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.CFMHEALTH - .columnName(), - "setCfmHealth", - VersionNum.VERSION690); - super.setDataHandler(columndesc, cfmHealth); - } - - /** - * Get the Column entity which column name is "lacp_current" from the Row - * entity of attributes. - * @return the Column entity which column name is "lacp_current" - */ - public Column getLacpCurrentColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.LACPCURRENT - .columnName(), - "getLacpCurrentColumn", - VersionNum.VERSION330); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "lacp_current" to the Row entity - * of attributes. - * @param lacpCurrent the column data which column name is "lacp_current" - */ - public void setLacpCurrent(Set<Boolean> lacpCurrent) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.LACPCURRENT - .columnName(), - "setLacpCurrent", - VersionNum.VERSION330); - super.setDataHandler(columndesc, lacpCurrent); - } - - /** - * Get the Column entity which column name is "other_config" from the Row - * entity of attributes. - * @return the Column entity which column name is "other_config" - */ - public Column getOtherConfigColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.OTHERCONFIG - .columnName(), - "getOtherConfigColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "other_config" to the Row entity - * of attributes. - * @param otherConfig the column data which column name is "other_config" - */ - public void setOtherConfig(Map<String, String> otherConfig) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.OTHERCONFIG - .columnName(), - "setOtherConfig", - VersionNum.VERSION100); - super.setDataHandler(columndesc, otherConfig); - } - - /** - * Get the Column entity which column name is "statistics" from the Row - * entity of attributes. - * @return the Column entity which column name is "statistics" - */ - public Column getStatisticsColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.STATISTICS - .columnName(), - "getStatisticsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "statistics" to the Row entity - * of attributes. - * @param statistics the column data which column name is "statistics" - */ - public void setStatistics(Map<String, Long> statistics) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.STATISTICS - .columnName(), - "setStatistics", - VersionNum.VERSION100); - super.setDataHandler(columndesc, statistics); - } - - /** - * Get the Column entity which column name is "status" from the Row entity - * of attributes. - * @return the Column entity which column name is "status" - */ - public Column getStatusColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.STATUS - .columnName(), - "getStatusColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "status" to the Row entity of - * attributes. - * @param status the column data which column name is "status" - */ - public void setStatus(Map<String, String> status) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.STATUS - .columnName(), - "setStatus", - VersionNum.VERSION100); - super.setDataHandler(columndesc, status); - } - - /** - * Get the Column entity which column name is "admin_state" from the Row - * entity of attributes. - * @return the Column entity which column name is "admin_state" - */ - public Column getAdminStateColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.ADMINSTATE - .columnName(), - "getAdminStateColumn", - VersionNum.VERSION106); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "admin_state" to the Row entity - * of attributes. - * @param adminState the column data which column name is "admin_state" - */ - public void setAdminState(Set<String> adminState) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.ADMINSTATE - .columnName(), - "setAdminState", - VersionNum.VERSION106); - super.setDataHandler(columndesc, adminState); - } - - /** - * Get the Column entity which column name is "link_state" from the Row - * entity of attributes. - * @return the Column entity which column name is "link_state" - */ - public Column getLinkStateColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.LINKSTATE - .columnName(), - "getLinkStateColumn", - VersionNum.VERSION106); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "link_state" to the Row entity - * of attributes. - * @param linkState the column data which column name is "link_state" - */ - public void setLinkState(Map<String, String> linkState) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.LINKSTATE - .columnName(), - "setLinkState", - VersionNum.VERSION106); - super.setDataHandler(columndesc, linkState); - } - - /** - * Get the Column entity which column name is "link_resets" from the Row - * entity of attributes. - * @return the Column entity which column name is "link_resets" - */ - public Column getLinkResetsColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.LINKRESETS - .columnName(), - "getLinkResetsColumn", - VersionNum.VERSION620); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "link_resets" to the Row entity - * of attributes. - * @param linkResets the column data which column name is "link_resets" - */ - public void setLinkResets(Set<String> linkResets) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.LINKRESETS - .columnName(), - "setLinkResets", - VersionNum.VERSION620); - super.setDataHandler(columndesc, linkResets); - } - - /** - * Get the Column entity which column name is "link_speed" from the Row - * entity of attributes. - * @return the Column entity which column name is "link_speed" - */ - public Column getLinkSpeedColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.LINKSPEED - .columnName(), - "getLinkSpeedColumn", - VersionNum.VERSION106); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "link_speed" to the Row entity - * of attributes. - * @param linkSpeed the column data which column name is "link_speed" - */ - public void setLinkSpeed(Set<Long> linkSpeed) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.LINKSPEED - .columnName(), - "setLinkSpeed", - VersionNum.VERSION106); - super.setDataHandler(columndesc, linkSpeed); - } - - /** - * Get the Column entity which column name is "duplex" from the Row entity - * of attributes. - * @return the Column entity which column name is "duplex" - */ - public Column getDuplexColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.DUPLEX - .columnName(), - "getDuplexColumn", - VersionNum.VERSION106); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "duplex" to the Row entity of - * attributes. - * @param duplex the column data which column name is "duplex" - */ - public void setDuplex(Set<Long> duplex) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.DUPLEX - .columnName(), - "setDuplex", - VersionNum.VERSION106); - super.setDataHandler(columndesc, duplex); - } - - /** - * Get the Column entity which column name is "mtu" from the Row entity of - * attributes. - * @return the Column entity which column name is "mtu" - */ - public Column getMtuColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.MTU - .columnName(), - "getMtuColumn", - VersionNum.VERSION106); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "mtu" to the Row entity of - * attributes. - * @param mtu the column data which column name is "mtu" - */ - public void setMtu(Set<Long> mtu) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.MTU - .columnName(), - "setMtu", - VersionNum.VERSION106); - super.setDataHandler(columndesc, mtu); - } - - /** - * Get the Column entity which column name is "error" from the Row entity of - * attributes. - * @return the Column entity which column name is "error" - */ - public Column getErrorColumn() { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.ERROR - .columnName(), - "getErrorColumn", - VersionNum.VERSION770); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "error" to the Row entity of - * attributes. - * @param error the column data which column name is "error" - */ - public void setError(Set<String> error) { - ColumnDescription columndesc = new ColumnDescription( - InterfaceColumn.ERROR - .columnName(), - "setError", - VersionNum.VERSION770); - super.setDataHandler(columndesc, error); - } - -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Ipfix.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Ipfix.java deleted file mode 100644 index c29f2e01..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Ipfix.java +++ /dev/null @@ -1,220 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Ipfix Table. - */ -public class Ipfix extends AbstractOvsdbTableService { - /** - * Ipfix table column name. - */ - public enum IpfixColumn { - TARGETS("targets"), SAMPLING("sampling"), OBSDOMAINID("obs_domain_id"), OBSPOINTID("obs_point_id"), - CACHEACTIVETIMEOUT("cache_active_timeout"), EXTERNALIDS("external_ids"), - CACHEMAXFLOWS("cache_max_flows"); - - private final String columnName; - - private IpfixColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for IpfixColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Ipfix object. Generate Ipfix Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Ipfix(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.IPFIX, VersionNum.VERSION710); - } - - /** - * Get the Column entity which column name is "targets" from the Row entity - * of attributes. - * @return the Column entity which column name is "targets" - */ - public Column getTargetsColumn() { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.TARGETS.columnName(), - "getTargetsColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "targets" to the Row entity of - * attributes. - * @param targets the column data which column name is "targets" - */ - public void setTargets(Set<String> targets) { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.TARGETS.columnName(), - "setTargets", - VersionNum.VERSION710); - super.setDataHandler(columndesc, targets); - } - - /** - * Get the Column entity which column name is "sampling" from the Row entity - * of attributes. - * @return the Column entity which column name is "sampling" - */ - public Column getSamplingColumn() { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.SAMPLING.columnName(), - "getSamplingColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "sampling" to the Row entity of - * attributes. - * @param sampling the column data which column name is "sampling" - */ - public void setSampling(Set<Long> sampling) { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.SAMPLING.columnName(), - "setSampling", VersionNum.VERSION710); - super.setDataHandler(columndesc, sampling); - } - - /** - * Get the Column entity which column name is "obs_domain_id" from the Row - * entity of attributes. - * @return the Column entity which column name is "obs_domain_id" - */ - public Column getObsDomainIdColumn() { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.OBSDOMAINID.columnName(), - "getObsDomainIdColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "obs_domain_id" to the Row - * entity of attributes. - * @param obsdomainid the column data which column name is "obs_domain_id" - */ - public void setObsDomainId(Set<Long> obsdomainid) { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.OBSDOMAINID.columnName(), - "setObsDomainId", VersionNum.VERSION710); - super.setDataHandler(columndesc, obsdomainid); - } - - /** - * Get the Column entity which column name is "obs_point_id" from the Row - * entity of attributes. - * @return the Column entity which column name is "obs_point_id" - */ - public Column getObsPointIdColumn() { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.OBSPOINTID.columnName(), - "getObsPointIdColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "obs_point_id" to the Row entity - * of attributes. - * @param obsPointId the column data which column name is "obs_point_id" - */ - public void setObsPointId(Set<Long> obsPointId) { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.OBSPOINTID.columnName(), - "setObsPointId", VersionNum.VERSION710); - super.setDataHandler(columndesc, obsPointId); - } - - /** - * Get the Column entity which column name is "cache_active_timeout" from - * the Row entity of attributes. - * @return the Column entity which column name is "cache_active_timeout" - */ - public Column getCacheActiveTimeoutColumn() { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.CACHEACTIVETIMEOUT.columnName(), - "getCacheActiveTimeoutColumn", - VersionNum.VERSION730); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cache_active_timeout" to the - * Row entity of attributes. - * @param cacheActiveTimeout the column data which column name is - * "cache_active_timeout" - */ - public void setCacheActiveTimeout(Set<Long> cacheActiveTimeout) { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.CACHEACTIVETIMEOUT.columnName(), - "setCacheActiveTimeout", VersionNum.VERSION730); - super.setDataHandler(columndesc, cacheActiveTimeout); - } - - /** - * Get the Column entity which column name is "cache_max_flows" from the Row - * entity of attributes. - * @return the Column entity which column name is "cache_max_flows" - */ - public Column getCacheMaxFlowsColumn() { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.CACHEMAXFLOWS.columnName(), - "getCacheMaxFlowsColumn", VersionNum.VERSION730); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cache_max_flows" to the Row - * entity of attributes. - * @param cacheMaxFlows the column data which column name is - * "cache_max_flows" - */ - public void setCacheMaxFlows(Set<Long> cacheMaxFlows) { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.CACHEMAXFLOWS.columnName(), - "setCacheMaxFlows", VersionNum.VERSION730); - super.setDataHandler(columndesc, cacheMaxFlows); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION710); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(IpfixColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION710); - super.setDataHandler(columndesc, externalIds); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Manager.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Manager.java deleted file mode 100644 index d0c2638f..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Manager.java +++ /dev/null @@ -1,243 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Manager Table. - */ -public class Manager extends AbstractOvsdbTableService { - /** - * Manager table column name. - */ - public enum ManagerColumn { - TARGET("target"), ISCONNECTED("is_connected"), CONNECTIONMODE("connection_mode"), - EXTERNALIDS("external_ids"), STATUS("status"), INACTIVITYPROBE("inactivity_probe"), - OTHERCONFIG("other_config"), MAXBACKOFF("max_backoff"); - - private final String columnName; - - private ManagerColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for ManagerColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Manager object. Generate Manager Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Manager(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.MANAGER, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "target" from the Row entity - * of attributes. - * @return the Column entity which column name is "target" - */ - public Column getTargetColumn() { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.TARGET.columnName(), - "getTargetColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "target" to the Row entity of - * attributes. - * @param target the column data which column name is "target" - */ - public void setTarget(Set<String> target) { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.TARGET.columnName(), - "setTarget", - VersionNum.VERSION100); - super.setDataHandler(columndesc, target); - } - - /** - * Get the Column entity which column name is "is_connected" from the Row - * entity of attributes. - * @return the Column entity which column name is "is_connected" - */ - public Column getIsConnectedColumn() { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.ISCONNECTED.columnName(), - "getIsConnectedColumn", VersionNum.VERSION110); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "is_connected" to the Row entity - * of attributes. - * @param isConnected the column data which column name is "is_connected" - */ - public void setIsConnected(Boolean isConnected) { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.ISCONNECTED.columnName(), - "setIsConnected", VersionNum.VERSION110); - super.setDataHandler(columndesc, isConnected); - } - - /** - * Get the Column entity which column name is "other_config" from the Row - * entity of attributes. - * @return the Column entity which column name is "other_config" - */ - public Column getOtherConfigColumn() { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.OTHERCONFIG.columnName(), - "getOtherConfigColumn", VersionNum.VERSION680); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "other_config" to the Row entity - * of attributes. - * @param otherConfig the column data which column name is "other_config" - */ - public void setOtherConfig(Map<String, String> otherConfig) { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.OTHERCONFIG.columnName(), - "setOtherConfig", VersionNum.VERSION680); - super.setDataHandler(columndesc, otherConfig); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "max_backoff" from the Row - * entity of attributes. - * @return the Column entity which column name is "max_backoff" - */ - public Column getMaxBackoffColumn() { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.MAXBACKOFF.columnName(), - "getMaxBackoffColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "max_backoff" to the Row entity - * of attributes. - * @param maxBackoff the column data which column name is "max_backoff" - */ - public void setMaxBackoff(Set<Long> maxBackoff) { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.MAXBACKOFF.columnName(), - "setMaxBackoff", VersionNum.VERSION100); - super.setDataHandler(columndesc, maxBackoff); - } - - /** - * Get the Column entity which column name is "status" from the Row entity - * of attributes. - * @return the Column entity which column name is "status" - */ - public Column getStatusColumn() { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.STATUS.columnName(), - "getStatusColumn", VersionNum.VERSION110); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "status" to the Row entity of - * attributes. - * @param status the column data which column name is "status" - */ - public void setStatus(Map<String, String> status) { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.STATUS.columnName(), - "setStatus", - VersionNum.VERSION110); - super.setDataHandler(columndesc, status); - } - - /** - * Get the Column entity which column name is "inactivity_probe" from the - * Row entity of attributes. - * @return the Column entity which column name is "inactivity_probe" - */ - public Column getInactivityProbeColumn() { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.INACTIVITYPROBE.columnName(), - "getInactivityProbeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "inactivity_probe" to the Row - * entity of attributes. - * @param inactivityProbe the column data which column name is - * "inactivity_probe" - */ - public void setInactivityProbe(Set<Long> inactivityProbe) { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.INACTIVITYPROBE.columnName(), - "setInactivityProbe", VersionNum.VERSION100); - super.setDataHandler(columndesc, inactivityProbe); - } - - /** - * Get the Column entity which column name is "connection_mode" from the Row - * entity of attributes. - * @return the Column entity which column name is "connection_mode" - */ - public Column getConnectionModeColumn() { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.CONNECTIONMODE.columnName(), - "getConnectionModeColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "connection_mode" to the Row - * entity of attributes. - * @param connectionMode the column data which column name is - * "connection_mode" - */ - public void setConnectionMode(Set<String> connectionMode) { - ColumnDescription columndesc = new ColumnDescription(ManagerColumn.CONNECTIONMODE.columnName(), - "setConnectionMode", VersionNum.VERSION100); - super.setDataHandler(columndesc, connectionMode); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Mirror.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Mirror.java deleted file mode 100644 index ec022fee..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Mirror.java +++ /dev/null @@ -1,277 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.notation.UUID; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Mirror Table. - */ -public class Mirror extends AbstractOvsdbTableService { - /** - * Mirror table column name. - */ - public enum MirrorColumn { - NAME("name"), SELECTSRCPORT("select_src_port"), SELECTDSTPORT("select_dst_port"), - SELECTVLAN("select_vlan"), OUTPUTPORT("output_port"), EXTERNALIDS("external_ids"), - OUTPUTVLAN("output_vlan"), STATISTICS("statistics"), SELECTALL("select_all"); - - private final String columnName; - - private MirrorColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for MirrorColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Mirror object. Generate Mirror Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Mirror(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.MIRROR, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "name" from the Row entity of - * attributes. - * @return the Column entity which column name is "name" - */ - public Column getNameColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.NAME.columnName(), - "getNameColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "name" to the Row entity of - * attributes. - * @param name the column data which column name is "name" - */ - public void setName(Set<String> name) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.NAME.columnName(), - "setName", - VersionNum.VERSION100); - super.setDataHandler(columndesc, name); - } - - /** - * Get the column data which column name is "name" from the Row entity of - * attributes. - * @return the column data which column name is "name" - */ - public Set<String> getName() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.NAME.columnName(), - "getName", - VersionNum.VERSION100); - return (Set<String>) super.getDataHandler(columndesc); - } - - /** - * Get the Column entity which column name is "select_src_port" from the Row - * entity of attributes. - * @return the Column entity which column name is "select_src_port" - */ - public Column getSelectSrcPortColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.SELECTSRCPORT.columnName(), - "getSelectSrcPortColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "select_src_port" to the Row - * entity of attributes. - * @param selectSrcPort the column data which column name is - * "select_src_port" - */ - public void setSelectSrcPort(Set<UUID> selectSrcPort) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.SELECTSRCPORT.columnName(), - "setSelectSrcPort", VersionNum.VERSION100); - super.setDataHandler(columndesc, selectSrcPort); - } - - /** - * Get the Column entity which column name is "select_dst_port" from the Row - * entity of attributes. - * @return the Column entity which column name is "select_dst_port" - */ - public Column getSelectDstPortColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.SELECTDSTPORT.columnName(), - "getSelectDstPortColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "select_dst_port" to the Row - * entity of attributes. - * @param selectDstPrt the column data which column name is - * "select_dst_port" - */ - public void setSelectDstPort(Set<UUID> selectDstPrt) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.SELECTDSTPORT.columnName(), - "setSelectDstPort", VersionNum.VERSION100); - super.setDataHandler(columndesc, selectDstPrt); - } - - /** - * Get the Column entity which column name is "select_vlan" from the Row - * entity of attributes. - * @return the Column entity which column name is "select_vlan" - */ - public Column getSelectVlanColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.SELECTVLAN.columnName(), - "getSelectVlanColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "select_vlan" to the Row entity - * of attributes. - * @param selectVlan the column data which column name is "select_vlan" - */ - public void setSelectVlan(Set<Long> selectVlan) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.SELECTVLAN.columnName(), - "setSelectVlan", VersionNum.VERSION100); - super.setDataHandler(columndesc, selectVlan); - } - - /** - * Get the Column entity which column name is "output_port" from the Row - * entity of attributes. - * @return the Column entity which column name is "output_port" - */ - public Column getOutputPortColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.OUTPUTPORT.columnName(), - "getOutputPortColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "output_port" to the Row entity - * of attributes. - * @param outputPort the column data which column name is "output_port" - */ - public void setOutputPort(Set<UUID> outputPort) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.OUTPUTPORT.columnName(), - "setOutputPort", VersionNum.VERSION100); - super.setDataHandler(columndesc, outputPort); - } - - /** - * Get the Column entity which column name is "output_vlan" from the Row - * entity of attributes. - * @return the Column entity which column name is "output_vlan" - */ - public Column getOutputVlanColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.OUTPUTVLAN.columnName(), - "getOutputVlanColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "output_vlan" to the Row entity - * of attributes. - * @param outputVlan the column data which column name is "output_vlan" - */ - public void setOutputVlan(Set<Long> outputVlan) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.OUTPUTVLAN.columnName(), - "setOutputVlan", VersionNum.VERSION100); - super.setDataHandler(columndesc, outputVlan); - } - - /** - * Get the Column entity which column name is "statistics" from the Row - * entity of attributes. - * @return the Column entity which column name is "statistics" - */ - public Column getStatisticsColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.STATISTICS.columnName(), - "getStatisticsColumn", VersionNum.VERSION640); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "statistics" to the Row entity - * of attributes. - * @param statistics the column data which column name is "statistics" - */ - public void setStatistics(Map<String, Long> statistics) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.STATISTICS.columnName(), - "setStatistics", VersionNum.VERSION640); - super.setDataHandler(columndesc, statistics); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "select_all" from the Row - * entity of attributes. - * @return the Column entity which column name is "select_all" - */ - public Column getSelectAllColumn() { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.SELECTALL.columnName(), - "getSelectAllColumn", VersionNum.VERSION620); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "select_all" to the Row entity - * of attributes. - * @param selectAll the column data which column name is "select_all" - */ - public void setSelectAll(Boolean selectAll) { - ColumnDescription columndesc = new ColumnDescription(MirrorColumn.SELECTALL.columnName(), - "setSelectAll", VersionNum.VERSION620); - super.setDataHandler(columndesc, selectAll); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Netflow.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Netflow.java deleted file mode 100644 index 98c3de55..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Netflow.java +++ /dev/null @@ -1,197 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Netflow Table. - */ -public class Netflow extends AbstractOvsdbTableService { - /** - * Netflow table column name. - */ - public enum NetflowColumn { - TARGETS("targets"), ACTIVETIMEOUT("active_timeout"), ENGINETYPE("engine_type"), - EXTERNALIDS("external_ids"), ADDIDTOINTERFACE("add_id_to_interface"), ENGINEID("engine_id"); - - private final String columnName; - - private NetflowColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for NetflowColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a NetFlow object. Generate Netflow Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Netflow(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.NETFLOW, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "targets" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getTargetsColumn() { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.TARGETS.columnName(), - "getTargetsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "targets" to the Row entity of - * attributes. - * @param targets the column data which column name is "targets" - */ - public void setTargets(Set<String> targets) { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.TARGETS.columnName(), - "setTargets", VersionNum.VERSION100); - super.setDataHandler(columndesc, targets); - } - - /** - * Get the Column entity which column name is "active_timeout" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getActiveTimeoutColumn() { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.ACTIVETIMEOUT.columnName(), - "getActiveTimeoutColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "active_timeout" to the Row - * entity of attributes. - * @param activeTimeout the column data which column name is - * "active_timeout" - */ - public void setActiveTimeout(Long activeTimeout) { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.ACTIVETIMEOUT.columnName(), - "setActiveTimeout", VersionNum.VERSION100); - super.setDataHandler(columndesc, activeTimeout); - } - - /** - * Get the Column entity which column name is "engine_type" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getEngineTypeColumn() { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.ENGINETYPE.columnName(), - "getEngineTypeColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "engine_type" to the Row entity - * of attributes. - * @param engineType the column data which column name is "engine_type" - */ - public void setEngineType(Set<Long> engineType) { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.ENGINETYPE.columnName(), - "setEngineType", VersionNum.VERSION100); - super.setDataHandler(columndesc, engineType); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "add_id_to_interface" from the - * Row entity of attributes. - * @return the Column entity - */ - public Column getAddIdToInterfaceColumn() { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.ADDIDTOINTERFACE.columnName(), - "getAddIdToInterfaceColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "add_id_to_interface" to the Row - * entity of attributes. - * @param addIdToInterface the column data which column name is - * "add_id_to_interface" - */ - public void setAddIdToInterface(Boolean addIdToInterface) { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.ADDIDTOINTERFACE.columnName(), - "setAddIdToInterface", VersionNum.VERSION100); - super.setDataHandler(columndesc, addIdToInterface); - } - - /** - * Get the Column entity which column name is "engine_id" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getEngineIdColumn() { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.ENGINETYPE.columnName(), - "getEngineIdColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "engine_id" to the Row entity of - * attributes. - * @param engineId the column data which column name is "engine_id" - */ - public void setEngineId(Set<Long> engineId) { - ColumnDescription columndesc = new ColumnDescription(NetflowColumn.ENGINETYPE.columnName(), - "setEngineId", VersionNum.VERSION100); - super.setDataHandler(columndesc, engineId); - } - -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/OpenVSwitch.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/OpenVSwitch.java deleted file mode 100644 index 9d20b982..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/OpenVSwitch.java +++ /dev/null @@ -1,466 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.notation.UUID; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Open_vSwitch Table. - */ -public class OpenVSwitch extends AbstractOvsdbTableService { - - /** - * OpenVSwitch table column name. - */ - public enum OpenVSwitchColumn { - BRIDGES("bridges"), MANAGERS("managers"), - MANAGEROPTIONS("manager_options"), SSL("ssl"), - OTHERCONFIG("other_config"), EXTERNALIDS("external_ids"), - NEXTCFG("next_cfg"), CURCFG("cur_cfg"), CAPABILITIES("capabilities"), - STATISTICS("statistics"), OVSVERSION("ovs_version"), - DBVERSION("db_version"), SYSTEMTYPE("system_type"), - SYSTEMVERSION("system_version"); - - private final String columnName; - - private OpenVSwitchColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for OpenVSwitchColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a OpenVSwitch object. Generate Open_vSwitch Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public OpenVSwitch(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.OPENVSWITCH, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "bridges" from the Row entity - * of attributes. - * @return the Column entity which column name is "bridges" - */ - public Column getBridgesColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.BRIDGES - .columnName(), - "getBridgesColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bridges" to the Row entity of - * attributes. - * @param bridges the column data which column name is "bridges" - */ - public void setBridges(Set<UUID> bridges) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.BRIDGES - .columnName(), - "setBridges", - VersionNum.VERSION100); - super.setDataHandler(columndesc, bridges); - } - - /** - * Get the Column entity which column name is "managers" from the Row entity - * of attributes. - * @return the Column entity which column name is "managers" - */ - public Column getManagersColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.MANAGERS - .columnName(), - "getManagersColumn", - VersionNum.VERSION100, - VersionNum.VERSION200); - return (Column) super.getDataHandler(columndesc); - } - - /** - * Add a Column entity which column name is "managers" to the Row entity of - * attributes. - * @param managers the column data which column name is "managers" - */ - public void setManagers(Set<UUID> managers) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.MANAGERS - .columnName(), - "setManagers", - VersionNum.VERSION100, - VersionNum.VERSION200); - super.setDataHandler(columndesc, managers); - } - - /** - * Get the Column entity which column name is "manager_options" from the Row - * entity of attributes. - * @return the Column entity which column name is "manager_options" - */ - public Column getManagerOptionsColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.MANAGEROPTIONS - .columnName(), - "getManagerOptionsColumn", - VersionNum.VERSION100); - return (Column) super.getDataHandler(columndesc); - } - - /** - * Add a Column entity which column name is "manager_options" to the Row - * entity of attributes. - * @param managerOptions the column data which column name is - * "manager_options" - */ - public void setManagerOptions(Set<UUID> managerOptions) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.MANAGEROPTIONS - .columnName(), - "setManagerOptions", - VersionNum.VERSION100); - super.setDataHandler(columndesc, managerOptions); - } - - /** - * Get the Column entity which column name is "ssl" from the Row entity of - * attributes. - * @return the Column entity which column name is "ssl" - */ - public Column getSslColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.SSL - .columnName(), - "getSslColumn", - VersionNum.VERSION100); - return (Column) super.getDataHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ssl" to the Row entity of - * attributes. - * @param ssl the column data which column name is "ssl" - */ - public void setSsl(Set<UUID> ssl) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.SSL - .columnName(), - "setSsl", - VersionNum.VERSION100); - super.setDataHandler(columndesc, ssl); - } - - /** - * Get the Column entity which column name is "other_config" from the Row - * entity of attributes. - * @return the Column entity which column name is "other_config" - */ - public Column getOtherConfigColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.OTHERCONFIG - .columnName(), - "getOtherConfigColumn", - VersionNum.VERSION510); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "other_config" to the Row entity - * of attributes. - * @param otherConfig the column data which column name is "other_config" - */ - public void setOtherConfig(Map<String, String> otherConfig) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.OTHERCONFIG - .columnName(), - "setOtherConfig", - VersionNum.VERSION510); - super.setDataHandler(columndesc, otherConfig); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity which column name is "external_ids" - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.EXTERNALIDS - .columnName(), - "getExternalIdsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.EXTERNALIDS - .columnName(), - "setExternalIds", - VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "next_cfg" from the Row entity - * of attributes. - * @return the Column entity which column name is "next_cfg" - */ - public Column getNextConfigColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.NEXTCFG - .columnName(), - "getNextConfigColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "next_cfg" to the Row entity of - * attributes. - * @param nextConfig the column data which column name is "next_cfg" - */ - public void setNextConfig(Long nextConfig) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.NEXTCFG - .columnName(), - "setNextConfig", - VersionNum.VERSION100); - super.setDataHandler(columndesc, nextConfig); - } - - /** - * Get the Column entity which column name is "cur_cfg" from the Row entity - * of attributes. - * @return the Column entity which column name is "cur_cfg" - */ - public Column getCurrentConfigColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.CURCFG - .columnName(), - "getCurrentConfigColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "cur_cfg" to the Row entity of - * attributes. - * @param currentConfig the column data which column name is "cur_cfg" - */ - public void setCurrentConfig(Long currentConfig) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.CURCFG - .columnName(), - "setCurrentConfig", - VersionNum.VERSION100); - super.setDataHandler(columndesc, currentConfig); - } - - /** - * Get the Column entity which column name is "capabilities" from the Row - * entity of attributes. - * @return the Column entity which column name is "capabilities" - */ - public Column getCapabilitiesColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.CAPABILITIES - .columnName(), - "getCapabilitiesColumn", - VersionNum.VERSION100, - VersionNum.VERSION670); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "capabilities" to the Row entity - * of attributes. - * @param capabilities the column data which column name is "capabilities" - */ - public void setCapabilities(Map<String, UUID> capabilities) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.CAPABILITIES - .columnName(), - "setCapabilities", - VersionNum.VERSION100, - VersionNum.VERSION670); - super.setDataHandler(columndesc, capabilities); - } - - /** - * Get the Column entity which column name is "statistics" from the Row - * entity of attributes. - * @return the Column entity which column name is "statistics" - */ - public Column getStatisticsColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.STATISTICS - .columnName(), - "getStatisticsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "statistics" to the Row entity - * of attributes. - * @param statistics the column data which column name is "statistics" - */ - public void setStatistics(Map<String, Long> statistics) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.STATISTICS - .columnName(), - "setStatistics", - VersionNum.VERSION100); - super.setDataHandler(columndesc, statistics); - } - - /** - * Get the Column entity which column name is "ovs_version" from the Row - * entity of attributes. - * @return the Column entity which column name is "ovs_version" - */ - public Column getOvsVersionColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.OVSVERSION - .columnName(), - "getOvsVersionColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ovs_version" to the Row entity - * of attributes. - * @param ovsVersion the column data which column name is "ovs_version" - */ - public void setOvsVersion(Set<String> ovsVersion) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.OVSVERSION - .columnName(), - "setOvsVersion", - VersionNum.VERSION100); - super.setDataHandler(columndesc, ovsVersion); - } - - /** - * Get the Column entity which column name is "db_version" from the Row - * entity of attributes. - * @return the Column entity which column name is "db_version" - */ - public Column getDbVersionColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.DBVERSION - .columnName(), - "getDbVersionColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "db_version" to the Row entity - * of attributes. - * @param dbVersion the column data which column name is "db_version" - */ - public void setDbVersion(Set<String> dbVersion) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.DBVERSION - .columnName(), - "setDbVersion", - VersionNum.VERSION100); - super.setDataHandler(columndesc, dbVersion); - } - - /** - * Get the Column entity which column name is "system_type" from the Row - * entity of attributes. - * @return the Column entity which column name is "system_type" - */ - public Column getSystemTypeColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.SYSTEMTYPE - .columnName(), - "getSystemTypeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "system_type" to the Row entity - * of attributes. - * @param systemType the column data which column name is "system_type" - */ - public void setSystemType(Set<String> systemType) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.SYSTEMTYPE - .columnName(), - "setSystemType", - VersionNum.VERSION100); - super.setDataHandler(columndesc, systemType); - } - - /** - * Get the Column entity which column name is "system_version" from the Row - * entity of attributes. - * @return the Column entity which column name is "system_version" - */ - public Column getSystemVersionColumn() { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.SYSTEMVERSION - .columnName(), - "getSystemVersionColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "system_version" to the Row - * entity of attributes. - * @param systemVersion the column data which column name is - * "system_version" - */ - public void setSystemVersion(Set<String> systemVersion) { - ColumnDescription columndesc = new ColumnDescription( - OpenVSwitchColumn.SYSTEMVERSION - .columnName(), - "setSystemVersion", - VersionNum.VERSION100); - super.setDataHandler(columndesc, systemVersion); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/OvsdbTable.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/OvsdbTable.java deleted file mode 100644 index 2bfe2e79..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/OvsdbTable.java +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -/** - * Ovsdb table name. Refer to RFC7047's Section 9.2. - */ -public enum OvsdbTable { - INTERFACE("Interface"), BRIDGE("Bridge"), CONTROLLER("Controller"), - PORT("Port"), OPENVSWITCH("Open_vSwitch"), FLWTABLE("Flow_Table"), - QOS("Qos"), QUEUE("Queue"), MIRROR("Mirror"), MANAGER("Manager"), - NETFLOW("NetFlow"), SSL("SSL"), SFLOW("sFlow"), IPFIX("IPFIX"), - FLOWSAMPLECOLLECTORSET("Flow_Sample_Collector_Set"); - - private final String tableName; - - private OvsdbTable(String tableName) { - this.tableName = tableName; - } - - /** - * Returns the table name for OvsdbTable. - * @return the table name - */ - public String tableName() { - return tableName; - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Port.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Port.java deleted file mode 100644 index 1e1ab7d7..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Port.java +++ /dev/null @@ -1,590 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.notation.UUID; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Port Table. - */ -public class Port extends AbstractOvsdbTableService { - - /** - * Port table column name. - */ - public enum PortColumn { - NAME("name"), INTERFACES("interfaces"), TRUNKS("trunks"), TAG("tag"), - VLANMODE("vlan_mode"), QOS("qos"), MAC("mac"), BONDTYPE("bond_type"), - BONDMODE("bond_mode"), LACP("lacp"), BONDUPDELAY("bond_updelay"), - BONDDOWNDELAY("bond_downdelay"), BONDFAKEIFACE("bond_fake_iface"), - FAKEBRIDGE("fake_bridge"), STATUS("status"), STATISTICS("statistics"), - OTHERCONFIG("other_config"), EXTERNALIDS("external_ids"); - - private final String columnName; - - private PortColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for PortColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Port object. Generate Port Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Port(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.PORT, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "name" from the Row entity of - * attributes. - * @return the Column entity - */ - public Column getNameColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.NAME - .columnName(), - "getNameColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "name" to the Row entity of - * attributes. - * @param name the column data which column name is "name" - */ - public void setName(String name) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.NAME - .columnName(), - "setName", - VersionNum.VERSION100); - super.setDataHandler(columndesc, name); - } - - /** - * Get the Column entity which column name is "name" from the Row entity of - * attributes. - * @return the Column entity - */ - public String getName() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.NAME - .columnName(), - "getName", - VersionNum.VERSION100); - return (String) super.getDataHandler(columndesc); - } - - /** - * Get the Column entity which column name is "interfaces" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getInterfacesColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.INTERFACES - .columnName(), - "getInterfacesColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "interfaces" to the Row entity - * of attributes. - * @param interfaces the column data which column name is "interfaces" - */ - public void setInterfaces(Set<UUID> interfaces) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.INTERFACES - .columnName(), - "setInterfaces", - VersionNum.VERSION100); - super.setDataHandler(columndesc, interfaces); - } - - /** - * Get the Column entity which column name is "trunks" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getTrunksColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.TRUNKS - .columnName(), - "getTrunksColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "trunks" to the Row entity of - * attributes. - * @param trunks the column data which column name is "trunks" - */ - public void setTrunks(Set<Long> trunks) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.TRUNKS - .columnName(), - "setTrunks", - VersionNum.VERSION100); - super.setDataHandler(columndesc, trunks); - } - - /** - * Get the Column entity which column name is "tag" from the Row entity of - * attributes. - * @return the Column entity - */ - public Column getTagColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.TAG - .columnName(), - "getTagColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "tag" to the Row entity of - * attributes. - * @param tag the column data which column name is "tag" - */ - public void setTag(Set<Long> tag) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.TAG - .columnName(), - "setTag", - VersionNum.VERSION100); - super.setDataHandler(columndesc, tag); - } - - /** - * Get the Column entity which column name is "vlan_mode" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getVlanModeColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.VLANMODE - .columnName(), - "getVlanModeColumn", - VersionNum.VERSION610); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "vlan_mode" to the Row entity of - * attributes. - * @param vlanMode the column data which column name is "vlan_mode" - */ - public void setVlanMode(Set<String> vlanMode) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.VLANMODE - .columnName(), - "setVlanMode", - VersionNum.VERSION610); - super.setDataHandler(columndesc, vlanMode); - } - - /** - * Get the Column entity which column name is "qos" from the Row entity of - * attributes. - * @return the Column entity - */ - public Column getQosColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.QOS - .columnName(), - "getQosColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "qos" to the Row entity of - * attributes. - * @param qos the column data which column name is "qos" - */ - public void setQos(Set<UUID> qos) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.QOS - .columnName(), - "setQos", - VersionNum.VERSION100); - super.setDataHandler(columndesc, qos); - } - - /** - * Get the Column entity which column name is "mac" from the Row entity of - * attributes. - * @return the Column entity - */ - public Column getMacColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.MAC - .columnName(), - "getMacColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "mac" to the Row entity of - * attributes. - * @param mac the column data which column name is "mac" - */ - public void setMac(Set<String> mac) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.MAC - .columnName(), - "setMac", - VersionNum.VERSION100); - super.setDataHandler(columndesc, mac); - } - - /** - * Get the Column entity which column name is "bond_type" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getBondTypeColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDTYPE - .columnName(), - "getBondTypeColumn", - VersionNum.VERSION102, - VersionNum.VERSION103); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bond_type" to the Row entity of - * attributes. - * @param bondtype the column data which column name is "bond_type" - */ - public void setBondType(Set<String> bondtype) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDTYPE - .columnName(), - "setBondType", - VersionNum.VERSION102, - VersionNum.VERSION103); - super.setDataHandler(columndesc, bondtype); - } - - /** - * Get the Column entity which column name is "bond_mode" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getBondModeColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDMODE - .columnName(), - "getBondModeColumn", - VersionNum.VERSION104); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bond_mode" to the Row entity of - * attributes. - * @param bondmode the column data which column name is "bond_mode" - */ - public void setBondMode(Set<String> bondmode) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDMODE - .columnName(), - "setBondMode", - VersionNum.VERSION104); - super.setDataHandler(columndesc, bondmode); - } - - /** - * Get the Column entity which column name is "lacp" from the Row entity of - * attributes. - * @return the Column entity - */ - public Column getLacpColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.LACP - .columnName(), - "getLacpColumn", - VersionNum.VERSION130); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "lacp" to the Row entity of - * attributes. - * @param lacp the column data which column name is "lacp" - */ - public void setLacp(Set<String> lacp) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.LACP - .columnName(), - "setLacp", - VersionNum.VERSION130); - super.setDataHandler(columndesc, lacp); - } - - /** - * Get the Column entity which column name is "bond_updelay" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getBondUpDelayColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDUPDELAY - .columnName(), - "getBondUpDelayColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bond_updelay" to the Row entity - * of attributes. - * @param bondUpDelay the column data which column name is "bond_updelay" - */ - public void setBondUpDelay(Set<Long> bondUpDelay) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDUPDELAY - .columnName(), - "setBondUpDelay", - VersionNum.VERSION100); - super.setDataHandler(columndesc, bondUpDelay); - } - - /** - * Get the Column entity which column name is "bond_downdelay" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getBondDownDelayColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDDOWNDELAY - .columnName(), - "getBondDownDelayColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bond_downdelay" to the Row - * entity of attributes. - * @param bondDownDelay the column data which column name is - * "bond_downdelay" - */ - public void setBondDownDelay(Set<Long> bondDownDelay) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDDOWNDELAY - .columnName(), - "setBondDownDelay", - VersionNum.VERSION100); - super.setDataHandler(columndesc, bondDownDelay); - } - - /** - * Get the Column entity which column name is "bond_fake_iface" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getBondFakeInterfaceColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDFAKEIFACE - .columnName(), - "getBondFakeInterfaceColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bond_fake_iface" to the Row - * entity of attributes. - * @param bondFakeInterface the column data which column name is - * "bond_fake_iface" - */ - public void setBondFakeInterface(Set<Boolean> bondFakeInterface) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.BONDFAKEIFACE - .columnName(), - "setBondFakeInterface", - VersionNum.VERSION100); - super.setDataHandler(columndesc, bondFakeInterface); - } - - /** - * Get the Column entity which column name is "fake_bridge" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getFakeBridgeColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.FAKEBRIDGE - .columnName(), - "getFakeBridgeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "fake_bridge" to the Row entity - * of attributes. - * @param fakeBridge the column data which column name is "fake_bridge" - */ - public void setFakeBridge(Set<Boolean> fakeBridge) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.FAKEBRIDGE - .columnName(), - "setFakeBridge", - VersionNum.VERSION100); - super.setDataHandler(columndesc, fakeBridge); - } - - /** - * Get the Column entity which column name is "status" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getStatusColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.STATUS - .columnName(), - "getStatusColumn", - VersionNum.VERSION620); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "status" to the Row entity of - * attributes. - * @param status the column data which column name is "status" - */ - public void setStatus(Map<String, String> status) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.STATUS - .columnName(), - "setStatus", - VersionNum.VERSION620); - super.setDataHandler(columndesc, status); - } - - /** - * Get the Column entity which column name is "statistics" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getStatisticsColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.STATISTICS - .columnName(), - "getStatisticsColumn", - VersionNum.VERSION630); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "statistics" to the Row entity - * of attributes. - * @param statistics the column data which column name is "statistics" - */ - public void setStatistics(Map<String, Long> statistics) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.STATISTICS - .columnName(), - "setStatistics", - VersionNum.VERSION630); - super.setDataHandler(columndesc, statistics); - } - - /** - * Get the Column entity which column name is "other_config" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getOtherConfigColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.OTHERCONFIG - .columnName(), - "getOtherConfigColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "other_config" to the Row entity - * of attributes. - * @param otherConfig the column data which column name is "other_config" - */ - public void setOtherConfig(Map<String, String> otherConfig) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.OTHERCONFIG - .columnName(), - "setOtherConfig", - VersionNum.VERSION100); - super.setDataHandler(columndesc, otherConfig); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.EXTERNALIDS - .columnName(), - "getExternalIdsColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription( - PortColumn.EXTERNALIDS - .columnName(), - "setExternalIds", - VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Qos.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Qos.java deleted file mode 100644 index a40aa30c..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Qos.java +++ /dev/null @@ -1,149 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.notation.UUID; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Qos Table. - */ -public class Qos extends AbstractOvsdbTableService { - /** - * Qos table column name. - */ - public enum QosColumn { - QUEUES("queues"), TYPE("type"), OTHERCONFIG("other_config"), EXTERNALIDS("external_ids"); - - private final String columnName; - - private QosColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for QosColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Qos object. Generate Qos Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Qos(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.QOS, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "queues" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getQueuesColumn() { - ColumnDescription columndesc = new ColumnDescription(QosColumn.QUEUES.columnName(), - "getQueuesColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "queues" to the Row entity of - * attributes. - * @param queues the column data which column name is "queues" - */ - public void setQueues(Map<Long, UUID> queues) { - ColumnDescription columndesc = new ColumnDescription(QosColumn.QUEUES.columnName(), "setQueues", - VersionNum.VERSION100); - super.setDataHandler(columndesc, queues); - } - - /** - * Get the Column entity which column name is "type" from the Row entity of - * attributes. - * @return the Column entity - */ - public Column getTypeColumn() { - ColumnDescription columndesc = new ColumnDescription(QosColumn.TYPE.columnName(), "getTypeColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "type" to the Row entity of - * attributes. - * @param type the column data which column name is "type" - */ - public void setType(Set<String> type) { - ColumnDescription columndesc = new ColumnDescription(QosColumn.TYPE.columnName(), "setType", - VersionNum.VERSION100); - super.setDataHandler(columndesc, type); - } - - /** - * Get the Column entity which column name is "other_config" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getOtherConfigColumn() { - ColumnDescription columndesc = new ColumnDescription(QosColumn.OTHERCONFIG.columnName(), - "getOtherConfigColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "other_config" to the Row entity - * of attributes. - * @param otherConfig the column data which column name is "other_config" - */ - public void setOtherConfig(Map<String, String> otherConfig) { - ColumnDescription columndesc = new ColumnDescription(QosColumn.OTHERCONFIG.columnName(), - "setOtherConfig", VersionNum.VERSION100); - super.setDataHandler(columndesc, otherConfig); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(QosColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(QosColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Queue.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Queue.java deleted file mode 100644 index a89abafc..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Queue.java +++ /dev/null @@ -1,126 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Queue Table. - */ -public class Queue extends AbstractOvsdbTableService { - /** - * Queue table column name. - */ - public enum QueueColumn { - DSCP("dscp"), OTHERCONFIG("other_config"), EXTERNALIDS("external_ids"); - - private final String columnName; - - private QueueColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for QueueColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Queue object. Generate Queue Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Queue(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.QUEUE, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "dscp" from the Row entity of - * attributes. - * @return the Column entity - */ - public Column getDscpColumn() { - ColumnDescription columndesc = new ColumnDescription(QueueColumn.DSCP.columnName(), "getDscpColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "dscp" to the Row entity of - * attributes. - * @param dscp the column data which column name is "dscp" - */ - public void setDscp(Set<Long> dscp) { - ColumnDescription columndesc = new ColumnDescription(QueueColumn.DSCP.columnName(), "setDscp", - VersionNum.VERSION100); - super.setDataHandler(columndesc, dscp); - } - - /** - * Get the Column entity which column name is "other_config" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getOtherConfigColumn() { - ColumnDescription columndesc = new ColumnDescription(QueueColumn.OTHERCONFIG.columnName(), - "getOtherConfigColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "other_config" to the Row entity - * of attributes. - * @param otherConfig the column data which column name is "other_config" - */ - public void setOtherConfig(Map<String, String> otherConfig) { - ColumnDescription columndesc = new ColumnDescription(QueueColumn.OTHERCONFIG.columnName(), - "setOtherConfig", VersionNum.VERSION100); - super.setDataHandler(columndesc, otherConfig); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(QueueColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(QueueColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Sflow.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Sflow.java deleted file mode 100644 index 142f66e3..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Sflow.java +++ /dev/null @@ -1,193 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; -import java.util.Set; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Sflow Table. - */ -public class Sflow extends AbstractOvsdbTableService { - /** - * Sflow table column name. - */ - public enum SflowColumn { - TARGETS("targets"), AGENT("agent"), EXTERNALIDS("external_ids"), HAEDER("header"), - POLLING("polling"), SAMPLING("sampling"); - - private final String columnName; - - private SflowColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for SflowColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Sflow object. Generate Sflow Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Sflow(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.SFLOW, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "targets" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getTargetsColumn() { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.TARGETS.columnName(), - "getTargetsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "targets" to the Row entity of - * attributes. - * @param targets the column data which column name is "targets" - */ - public void setTargets(Set<String> targets) { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.TARGETS.columnName(), "setTargets", - VersionNum.VERSION100); - super.setDataHandler(columndesc, targets); - } - - /** - * Get the Column entity which column name is "agent" from the Row entity of - * attributes. - * @return the Column entity - */ - public Column getAgentColumn() { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.AGENT.columnName(), - "getAgentColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "agent" to the Row entity of - * attributes. - * @param agent the column data which column name is "agent" - */ - public void setAgent(Set<String> agent) { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.AGENT.columnName(), "setAgent", - VersionNum.VERSION100); - super.setDataHandler(columndesc, agent); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "header" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getHeaderColumn() { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.HAEDER.columnName(), - "getHeaderColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "header" to the Row entity of - * attributes. - * @param header the column data which column name is "header" - */ - public void setHeader(Set<Long> header) { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.HAEDER.columnName(), "setHeader", - VersionNum.VERSION100); - super.setDataHandler(columndesc, header); - } - - /** - * Get the Column entity which column name is "polling" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getPollingColumn() { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.POLLING.columnName(), - "getPollingColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "polling" to the Row entity of - * attributes. - * @param polling the column data which column name is "polling" - */ - public void setPolling(Set<Long> polling) { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.POLLING.columnName(), "setPolling", - VersionNum.VERSION100); - super.setDataHandler(columndesc, polling); - } - - /** - * Get the Column entity which column name is "sampling" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getSamplingColumn() { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.SAMPLING.columnName(), - "getSamplingColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "sampling" to the Row entity of - * attributes. - * @param sampling the column data which column name is "sampling" - */ - public void setSampling(Set<Long> sampling) { - ColumnDescription columndesc = new ColumnDescription(SflowColumn.SAMPLING.columnName(), - "setSampling", VersionNum.VERSION100); - super.setDataHandler(columndesc, sampling); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Ssl.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Ssl.java deleted file mode 100644 index 188dee52..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/Ssl.java +++ /dev/null @@ -1,172 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import java.util.Map; - -import org.onosproject.ovsdb.rfc.notation.Column; -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; -import org.onosproject.ovsdb.rfc.tableservice.AbstractOvsdbTableService; -import org.onosproject.ovsdb.rfc.tableservice.ColumnDescription; - -/** - * This class provides operations of Ssl Table. - */ -public class Ssl extends AbstractOvsdbTableService { - /** - * Ssl table column name. - */ - public enum SslColumn { - CACERT("ca_cert"), EXTERNALIDS("external_ids"), BOOTSTRAPCACERT("bootstrap_ca_cert"), - CERTIFICATE("certificate"), PRIVATEKEY("private_key"); - - private final String columnName; - - private SslColumn(String columnName) { - this.columnName = columnName; - } - - /** - * Returns the table column name for SslColumn. - * @return the table column name - */ - public String columnName() { - return columnName; - } - } - - /** - * Constructs a Ssl object. Generate Ssl Table Description. - * @param dbSchema DatabaseSchema - * @param row Row - */ - public Ssl(DatabaseSchema dbSchema, Row row) { - super(dbSchema, row, OvsdbTable.SSL, VersionNum.VERSION100); - } - - /** - * Get the Column entity which column name is "ca_cert" from the Row entity - * of attributes. - * @return the Column entity - */ - public Column getCaCertColumn() { - ColumnDescription columndesc = new ColumnDescription(SslColumn.CACERT.columnName(), - "getCaCertColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "ca_cert" to the Row entity of - * attributes. - * @param caCert the column data which column name is "ca_cert" - */ - public void setCaCert(String caCert) { - ColumnDescription columndesc = new ColumnDescription(SslColumn.CACERT.columnName(), "setCaCert", - VersionNum.VERSION100); - super.setDataHandler(columndesc, caCert); - } - - /** - * Get the Column entity which column name is "external_ids" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getExternalIdsColumn() { - ColumnDescription columndesc = new ColumnDescription(SslColumn.EXTERNALIDS.columnName(), - "getExternalIdsColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "external_ids" to the Row entity - * of attributes. - * @param externalIds the column data which column name is "external_ids" - */ - public void setExternalIds(Map<String, String> externalIds) { - ColumnDescription columndesc = new ColumnDescription(SslColumn.EXTERNALIDS.columnName(), - "setExternalIds", VersionNum.VERSION100); - super.setDataHandler(columndesc, externalIds); - } - - /** - * Get the Column entity which column name is "bootstrap_ca_cert" from the - * Row entity of attributes. - * @return the Column entity - */ - public Column getBootstrapCaCertColumn() { - ColumnDescription columndesc = new ColumnDescription(SslColumn.BOOTSTRAPCACERT.columnName(), - "getBootstrapCaCertColumn", - VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "bootstrap_ca_cert" to the Row - * entity of attributes. - * @param bootstrapCaCert the column data which column name is - * "bootstrap_ca_cert" - */ - public void setBootstrapCaCert(Boolean bootstrapCaCert) { - ColumnDescription columndesc = new ColumnDescription(SslColumn.BOOTSTRAPCACERT.columnName(), - "setBootstrapCaCert", VersionNum.VERSION100); - super.setDataHandler(columndesc, bootstrapCaCert); - } - - /** - * Get the Column entity which column name is "certificate" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getCertificateColumn() { - ColumnDescription columndesc = new ColumnDescription(SslColumn.CERTIFICATE.columnName(), - "getCertificateColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "certificate" to the Row entity - * of attributes. - * @param certificate the column data which column name is "certificate" - */ - public void setCertificate(String certificate) { - ColumnDescription columndesc = new ColumnDescription(SslColumn.CERTIFICATE.columnName(), - "setCertificate", VersionNum.VERSION100); - super.setDataHandler(columndesc, certificate); - } - - /** - * Get the Column entity which column name is "private_key" from the Row - * entity of attributes. - * @return the Column entity - */ - public Column getPrivateKeyColumn() { - ColumnDescription columndesc = new ColumnDescription(SslColumn.PRIVATEKEY.columnName(), - "getPrivateKeyColumn", VersionNum.VERSION100); - return (Column) super.getColumnHandler(columndesc); - } - - /** - * Add a Column entity which column name is "private_key" to the Row entity - * of attributes. - * @param privatekey the column data which column name is "private_key" - */ - public void setPrivateKey(String privatekey) { - ColumnDescription columndesc = new ColumnDescription(SslColumn.PRIVATEKEY.columnName(), - "setPrivateKey", VersionNum.VERSION100); - super.setDataHandler(columndesc, privatekey); - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/TableGenerator.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/TableGenerator.java deleted file mode 100644 index f5bd860d..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/TableGenerator.java +++ /dev/null @@ -1,103 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -import org.onosproject.ovsdb.rfc.notation.Row; -import org.onosproject.ovsdb.rfc.schema.DatabaseSchema; - -/** - * Table generator. - */ -public final class TableGenerator { - - /** - * Constructs a TableGenerator object. Utility classes should not have a - * public or default constructor, otherwise it will compile failed. This - * class should not be instantiated. - */ - private TableGenerator() { - } - - /** - * Create table. - * @param dbSchema DatabaseSchema entity - * @param tableName table name - * @return Object table entity - */ - //FIXME change the name, it creates a row object, such as a controller. - public static Object createTable(DatabaseSchema dbSchema, - OvsdbTable tableName) { - Row row = new Row(); - return generateTable(dbSchema, row, tableName); - } - - /** - * Get table from Row. - * @param dbSchema DatabaseSchema entity - * @param row Row entity - * @param tableName table name - * @return Object table entity - */ - public static Object getTable(DatabaseSchema dbSchema, Row row, - OvsdbTable tableName) { - return generateTable(dbSchema, row, tableName); - } - - /** - * Generate the table by table name. - * @param dbSchema DatabaseSchema entity - * @param row Row entity - * @param tableName table name - * @return Object Table entity - */ - private static Object generateTable(DatabaseSchema dbSchema, Row row, - OvsdbTable tableName) { - switch (tableName) { - case INTERFACE: - return new Interface(dbSchema, row); - case BRIDGE: - return new Bridge(dbSchema, row); - case CONTROLLER: - return new Controller(dbSchema, row); - case OPENVSWITCH: - return new OpenVSwitch(dbSchema, row); - case PORT: - return new Port(dbSchema, row); - case FLWTABLE: - return new FlowTable(dbSchema, row); - case QOS: - return new Qos(dbSchema, row); - case QUEUE: - return new Queue(dbSchema, row); - case MIRROR: - return new Mirror(dbSchema, row); - case MANAGER: - return new Manager(dbSchema, row); - case NETFLOW: - return new Netflow(dbSchema, row); - case SSL: - return new Ssl(dbSchema, row); - case SFLOW: - return new Sflow(dbSchema, row); - case IPFIX: - return new Ipfix(dbSchema, row); - case FLOWSAMPLECOLLECTORSET: - return new FlowSampleCollectorSet(dbSchema, row); - default: - return null; - } - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/VersionNum.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/VersionNum.java deleted file mode 100644 index 8b356420..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/VersionNum.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.onosproject.ovsdb.rfc.table; - -/** - * The version number of tables and columns. - */ -public enum VersionNum { - VERSION100("1.0.0"), VERSION102("1.0.2"), VERSION103("1.0.3"), - VERSION104("1.0.4"), VERSION106("1.0.6"), VERSION110("1.1.0"), - VERSION130("1.3.0"), VERSION200("2.0.0"), VERSION300("3.0.0"), - VERSION330("3.3.0"), VERSION350("3.5.0"), VERSION400("4.0.0"), - VERSION510("5.1.0"), VERSION520("5.2.0"), VERSION600("6.0.0"), - VERSION610("6.1.0"), VERSION620("6.2.0"), VERSION630("6.3.0"), - VERSION640("6.4.0"), VERSION650("6.5.0"), VERSION660("6.6.0"), - VERSION670("6.7.0"), VERSION680("6.8.0"), VERSION690("6.9.0"), - VERSION6100("6.10.0"), VERSION6111("6.11.1"), VERSION710("7.1.0"), - VERSION720("7.2.0"), VERSION721("7.2.1"), VERSION730("7.3.0"), - VERSION740("7.4.0"), VERSION750("7.5.0"), VERSION770("7.7.0"); - - private final String versionNum; - - private VersionNum(String versionNum) { - this.versionNum = versionNum; - } - - /** - * Returns the version number for VersionNum. - * @return the version number - */ - public String versionNum() { - return versionNum; - } -} diff --git a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/package-info.java b/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/package-info.java deleted file mode 100644 index e235b168..00000000 --- a/framework/src/onos/protocols/ovsdb/rfc/src/main/java/org/onosproject/ovsdb/rfc/table/package-info.java +++ /dev/null @@ -1,20 +0,0 @@ -/* - * Copyright 2015 Open Networking Laboratory - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * OVSDB table definitions. - */ -package org.onosproject.ovsdb.rfc.table; |