blob: 5d99d7460638f69767e6708f60b447d229bf0eac [file] [log] [blame]
Thomas Vachuska9c9ff7c2015-07-20 10:38:59 -07001/*
2 * Copyright 2015 Open Networking Laboratory
3 *
4 * 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
7 *
8 * 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.
15 */
16package org.onosproject.flowanalyzer;
17
18import org.apache.felix.scr.annotations.Activate;
19import org.apache.felix.scr.annotations.Component;
20import org.apache.felix.scr.annotations.Deactivate;
21import org.apache.felix.scr.annotations.Reference;
22import org.apache.felix.scr.annotations.ReferenceCardinality;
23import org.apache.felix.scr.annotations.Service;
24import org.onosproject.net.flow.FlowRuleService;
25import org.onosproject.net.host.HostService;
26import org.onosproject.net.link.LinkService;
27import org.osgi.service.component.ComponentContext;
28import org.slf4j.Logger;
29
30import static org.slf4j.LoggerFactory.getLogger;
31
32/**
33 * Simple flow space analyzer app.
34 */
35@Component(immediate = true)
36@Service(value = FlowAnalyzer.class)
37public class FlowAnalyzer {
38
39 private final Logger log = getLogger(getClass());
40
41 @Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
42 protected FlowRuleService flowRuleService;
43
44 @Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
45 protected LinkService linkService;
46
47 @Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
48 protected HostService hostService;
49
50
51 @Activate
52 public void activate(ComponentContext context) {
53 log.info("Started");
54 }
55
56 @Deactivate
57 public void deactivate() {
58 log.info("Stopped");
59 }
60
61
62 /**
63 * ...
64 */
65 public void analyze() {
66 // TODO: implement this
67 }
68
69}