blob: d9b1f6035ed524d03087ff483ed4bf1fc13184a7 [file] [log] [blame]
Toshio Koidea03915e2014-07-01 18:39:52 -07001package net.onrc.onos.core.newintent;
2
3import java.util.Collection;
4import java.util.EventListener;
5
6import net.onrc.onos.api.batchoperation.BatchOperation;
7import net.onrc.onos.api.flowmanager.ConflictDetectionPolicy;
8import net.onrc.onos.api.flowmanager.IFlow;
9import net.onrc.onos.api.intent.IIntentRuntimeService;
10import net.onrc.onos.api.intent.Intent;
Toshio Koide025a9152014-07-21 11:00:34 -070011import net.onrc.onos.api.intent.IntentId;
Sho SHIMIZU308a45a2014-07-23 11:27:04 -070012import net.onrc.onos.api.intent.IntentInstaller;
Sho SHIMIZU113c0272014-07-22 22:07:26 -070013import net.onrc.onos.api.intent.IntentResolver;
Toshio Koidea03915e2014-07-01 18:39:52 -070014
15/**
16 * Implementation of Intent-Runtime Service.
17 * <p>
18 * TODO: Make all methods thread-safe. <br>
19 * TODO: Design methods to support the ReactiveForwarding and the SDN-IP.
20 */
21public class IntentRuntimeModule implements IIntentRuntimeService {
Toshio Koidea03915e2014-07-01 18:39:52 -070022 @Override
Sho SHIMIZU68a052d2014-07-24 15:25:14 -070023 public boolean install(Intent intent) {
24 // TODO: implement this method
25 return false;
Toshio Koidea03915e2014-07-01 18:39:52 -070026 }
27
28 @Override
Sho SHIMIZU68a052d2014-07-24 15:25:14 -070029 public boolean remove(IntentId id) {
30 // TODO: implement this method
31 return false;
Toshio Koidea03915e2014-07-01 18:39:52 -070032 }
33
34 @Override
Toshio Koide025a9152014-07-21 11:00:34 -070035 public Intent getIntent(IntentId id) {
Toshio Koidea03915e2014-07-01 18:39:52 -070036 // TODO Auto-generated method stub
37 // - retrieves intents from global distributed maps
38 return null;
39 }
40
41 @Override
42 public Collection<Intent> getIntents() {
43 // TODO Auto-generated method stub
44 // - retrieves intents from global distributed maps
45 return null;
46 }
47
48 @Override
49 public boolean executeBatch(BatchOperation<Intent> ops) {
50 // TODO Auto-generated method stub
51 // - gets flow operations using compile() method for each Intent object.
52 // - allocates resources
53 // - combines and executes flow operations using FlowManager Service.
54 // - updates global distributed maps
55 return false;
56 }
57
58 @Override
Sho SHIMIZU113c0272014-07-22 22:07:26 -070059 public <T extends Intent> void addResolver(Class<T> type, IntentResolver<T> resolver) {
60 //To change body of implemented methods use File | Settings | File Templates.
61 }
62
63 @Override
64 public <T extends Intent> void removeResolver(Class<T> type) {
65 //To change body of implemented methods use File | Settings | File Templates.
66 }
67
68 @Override
Sho SHIMIZU308a45a2014-07-23 11:27:04 -070069 public <T extends Intent> boolean addInstaller(Class<T> type, IntentInstaller<T> installer) {
70 // TODO: implement this method
71 return false;
72 }
73
74 @Override
75 public <T extends Intent> boolean removeInstaller(Class<T> type) {
76 // TODO: impelment this method
77 return false;
78 }
79
80 @Override
Toshio Koidea03915e2014-07-01 18:39:52 -070081 public Collection<IFlow> getFlows(String intentId) {
82 // TODO Auto-generated method stub
83 return null;
84 }
85
86 @Override
87 public Intent getIntentByFlow(String flowId) {
88 // TODO Auto-generated method stub
89 return null;
90 }
91
92 @Override
93 public void setConflictDetectionPolicy(ConflictDetectionPolicy policy) {
94 // TODO Auto-generated method stub
95
96 }
97
98 @Override
99 public ConflictDetectionPolicy getConflictDetectionPolicy() {
100 // TODO Auto-generated method stub
101 return null;
102 }
103
104 @Override
105 public void addEventListener(EventListener listener) {
106 // TODO Auto-generated method stub
107 // - listener for addition/removal of intents,
108 // and states changes of intents
109 }
110
111 @Override
112 public void removeEventListener(EventListener listener) {
113 // TODO Auto-generated method stub
114
115 }
116}