From 1c192d2dd68724e292b6a30f463085a262e1e813 Mon Sep 17 00:00:00 2001 From: Patrick Brady Date: Wed, 15 Feb 2017 23:11:26 -0800 Subject: Moving all files to root directory Change-Id: Ica5535fd6ec85f350fe1640b42137b49f83f10f0 Signed-off-by: Patrick Brady --- .../appc-lifecycle-management-api/.gitignore | 1 + .../org.eclipse.wst.common.project.facet.core.xml | 4 +++ .../appc-lifecycle-management-api/pom.xml | 36 ++++++++++++++++++++++ .../appc/lifecyclemanager/LifecycleManager.java | 30 ++++++++++++++++++ .../appc/lifecyclemanager/objects/LCMResponse.java | 33 ++++++++++++++++++++ .../objects/LifecycleException.java | 34 ++++++++++++++++++++ .../objects/NoTransitionDefinedException.java | 34 ++++++++++++++++++++ .../objects/VNFOperationOutcome.java | 29 +++++++++++++++++ 8 files changed, 201 insertions(+) create mode 100644 appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/.gitignore create mode 100644 appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/.settings/org.eclipse.wst.common.project.facet.core.xml create mode 100644 appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/pom.xml create mode 100644 appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/LifecycleManager.java create mode 100644 appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/LCMResponse.java create mode 100644 appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/LifecycleException.java create mode 100644 appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/NoTransitionDefinedException.java create mode 100644 appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/VNFOperationOutcome.java (limited to 'appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api') diff --git a/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/.gitignore b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/.gitignore new file mode 100644 index 000000000..b83d22266 --- /dev/null +++ b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/.gitignore @@ -0,0 +1 @@ +/target/ diff --git a/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/.settings/org.eclipse.wst.common.project.facet.core.xml b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/.settings/org.eclipse.wst.common.project.facet.core.xml new file mode 100644 index 000000000..f4ef8aa0a --- /dev/null +++ b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/.settings/org.eclipse.wst.common.project.facet.core.xml @@ -0,0 +1,4 @@ + + + + diff --git a/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/pom.xml b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/pom.xml new file mode 100644 index 000000000..67e52a2a6 --- /dev/null +++ b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/pom.xml @@ -0,0 +1,36 @@ + + 4.0.0 + + org.openecomp.appc + appc-lifecycle-management + 1.0.0 + + + org.openecomp.appc + appc-lifecycle-management-api + 1.0.0 + bundle + + appc-lifecycle-management-api + http://maven.apache.org + + + UTF-8 + + + + + org.apache.felix + maven-bundle-plugin + + + ${project.artifactId} + ${project.version} + org.openecomp.appc.lifecyclemanager.* + + + + + + + diff --git a/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/LifecycleManager.java b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/LifecycleManager.java new file mode 100644 index 000000000..795e340e0 --- /dev/null +++ b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/LifecycleManager.java @@ -0,0 +1,30 @@ +/*- + * ============LICENSE_START======================================================= + * openECOMP : APP-C + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights + * reserved. + * ================================================================================ + * 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. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.appc.lifecyclemanager; + + +import org.openecomp.appc.lifecyclemanager.objects.LifecycleException; +import org.openecomp.appc.lifecyclemanager.objects.NoTransitionDefinedException; + +public interface LifecycleManager { + String getNextState(String vnfType, String currentState, String event) throws NoTransitionDefinedException,LifecycleException; +} diff --git a/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/LCMResponse.java b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/LCMResponse.java new file mode 100644 index 000000000..70aefee26 --- /dev/null +++ b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/LCMResponse.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * openECOMP : APP-C + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights + * reserved. + * ================================================================================ + * 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. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.appc.lifecyclemanager.objects; + +public enum LCMResponse { + INVALID_INPUT_PARAMETERS, + NO_STATE_CHANGE, + NO_TRANSITION_DEFINED, + VALID_TRANSITION; + + public String toString(){ + return this.name(); + } +} diff --git a/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/LifecycleException.java b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/LifecycleException.java new file mode 100644 index 000000000..d729ca161 --- /dev/null +++ b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/LifecycleException.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * openECOMP : APP-C + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights + * reserved. + * ================================================================================ + * 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. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.appc.lifecyclemanager.objects; + + +public class LifecycleException extends Exception { + public final String currentState; + public final String event; + public LifecycleException(Exception e,String currentState,String event){ + super(e); + this.currentState = currentState; + this.event = event; + + } +} diff --git a/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/NoTransitionDefinedException.java b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/NoTransitionDefinedException.java new file mode 100644 index 000000000..688be531d --- /dev/null +++ b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/NoTransitionDefinedException.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * openECOMP : APP-C + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights + * reserved. + * ================================================================================ + * 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. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.appc.lifecyclemanager.objects; + + +public class NoTransitionDefinedException extends Exception { + public final String currentState; + public final String event; + public NoTransitionDefinedException(String message,String currentState,String event){ + super(message); + this.currentState = currentState; + this.event = event; + + } +} diff --git a/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/VNFOperationOutcome.java b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/VNFOperationOutcome.java new file mode 100644 index 000000000..9ad1cc701 --- /dev/null +++ b/appc-dispatcher/appc-lifecycle-management/appc-lifecycle-management-api/src/main/java/org/openecomp/appc/lifecyclemanager/objects/VNFOperationOutcome.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * openECOMP : APP-C + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights + * reserved. + * ================================================================================ + * 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. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.appc.lifecyclemanager.objects; + +public enum VNFOperationOutcome { + SUCCESS,FAILURE,EXPIRE; + public String toString(){ + return this.name(); + } +} -- cgit 1.2.3-korg