blob: 4c25dc539f1946b1317dd108a077ccaea2759844 [file] [log] [blame]
Brian O'Connor0e271dc2015-02-04 18:20:25 -08001/*
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.net.intent.impl;
17
18import org.onosproject.net.intent.IntentData;
19
20import static org.onosproject.net.intent.IntentState.FAILED;
21
22/**
23 * Represents a phase where the compile has failed.
24 */
Sho SHIMIZUd2d99742015-02-05 15:55:14 -080025class CompilingFailed extends CompletedIntentUpdate {
Brian O'Connor0e271dc2015-02-04 18:20:25 -080026
27 private final IntentData intentData;
28
29 CompilingFailed(IntentData intentData) {
30 this.intentData = intentData;
31 this.intentData.setState(FAILED);
32 }
33
34 @Override
35 public IntentData data() {
36 return intentData;
37 }
38
39 //FIXME we also need to decide what to do with the current intent's resources i.e. cleanup or revert
40}