blob: 717f9e5f06c36f940e24545de264270fc5bfa4d7 [file] [log] [blame]
Thomas Vachuska83e090e2014-10-22 14:25:35 -07001/*
Brian O'Connor5ab426f2016-04-09 01:19:45 -07002 * Copyright 2014-present Open Networking Laboratory
Thomas Vachuska83e090e2014-10-22 14:25:35 -07003 *
Thomas Vachuska4f1a60c2014-10-28 13:39:07 -07004 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
Thomas Vachuska83e090e2014-10-22 14:25:35 -07007 *
Thomas Vachuska4f1a60c2014-10-28 13:39:07 -07008 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
Thomas Vachuska83e090e2014-10-22 14:25:35 -070015 */
Brian O'Connorabafb502014-12-02 22:26:20 -080016package org.onosproject.net.flow;
alshabib902d41b2014-10-07 16:52:05 -070017
Brian O'Connorabafb502014-12-02 22:26:20 -080018import org.onosproject.net.flow.FlowRuleBatchEntry.FlowRuleOperation;
alshabib902d41b2014-10-07 16:52:05 -070019
Ray Milkeyc4dd7262015-08-21 09:33:42 -070020@Deprecated
21/**
22 * @deprecated in Drake release - no longer a public API
23 */
alshabib902d41b2014-10-07 16:52:05 -070024public class FlowRuleBatchEntry
25 extends BatchOperationEntry<FlowRuleOperation, FlowRule> {
26
Sho SHIMIZUc0e8bfa2015-01-22 16:15:08 -080027 private final Long id; // FIXME: consider using Optional<Long>
Brian O'Connor427a1762014-11-19 18:40:32 -080028
alshabib902d41b2014-10-07 16:52:05 -070029 public FlowRuleBatchEntry(FlowRuleOperation operator, FlowRule target) {
30 super(operator, target);
Sho SHIMIZUc0e8bfa2015-01-22 16:15:08 -080031 this.id = null;
Brian O'Connor427a1762014-11-19 18:40:32 -080032 }
33
Sho SHIMIZUc0e8bfa2015-01-22 16:15:08 -080034 public FlowRuleBatchEntry(FlowRuleOperation operator, FlowRule target, Long id) {
Brian O'Connor427a1762014-11-19 18:40:32 -080035 super(operator, target);
Sho SHIMIZUc0e8bfa2015-01-22 16:15:08 -080036 this.id = id;
Brian O'Connor427a1762014-11-19 18:40:32 -080037 }
38
Sho SHIMIZUc0e8bfa2015-01-22 16:15:08 -080039 public Long id() {
Brian O'Connor427a1762014-11-19 18:40:32 -080040 return id;
alshabib902d41b2014-10-07 16:52:05 -070041 }
42
43 public enum FlowRuleOperation {
44 ADD,
45 REMOVE,
46 MODIFY
47 }
48
49}