1 /**
2 *
3 * Copyright 2003-2004 The Apache Software Foundation
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17
18 //
19 // This source code implements specifications defined by the Java
20 // Community Process. In order to remain compliant with the specification
21 // DO NOT add / change / or delete method signatures!
22 //
23
24 package javax.enterprise.deploy.spi;
25
26 import javax.enterprise.deploy.model.DeployableObject;
27 import javax.enterprise.deploy.shared.DConfigBeanVersionType;
28 import javax.enterprise.deploy.shared.ModuleType;
29 import javax.enterprise.deploy.spi.exceptions.DConfigBeanVersionUnsupportedException;
30 import javax.enterprise.deploy.spi.exceptions.InvalidModuleException;
31 import javax.enterprise.deploy.spi.exceptions.TargetException;
32 import javax.enterprise.deploy.spi.status.ProgressObject;
33 import java.io.File;
34 import java.io.InputStream;
35 import java.util.Locale;
36
37 public class MockDeploymentManager implements DeploymentManager {
38 public Target[] getTargets() throws IllegalStateException {
39 return new Target[0];
40 }
41
42 public TargetModuleID[] getRunningModules(ModuleType moduleType, Target[] targetList) throws TargetException, IllegalStateException {
43 return new TargetModuleID[0];
44 }
45
46 public TargetModuleID[] getNonRunningModules(ModuleType moduleType, Target[] targetList) throws TargetException, IllegalStateException {
47 return new TargetModuleID[0];
48 }
49
50 public TargetModuleID[] getAvailableModules(ModuleType moduleType, Target[] targetList) throws TargetException, IllegalStateException {
51 return new TargetModuleID[0];
52 }
53
54 public DeploymentConfiguration createConfiguration(DeployableObject dObj) throws InvalidModuleException {
55 return null;
56 }
57
58 public ProgressObject distribute(Target[] targetList, File moduleArchive, File deploymentPlan) throws IllegalStateException {
59 return null;
60 }
61
62 public ProgressObject distribute(Target[] targetList, InputStream moduleArchive, InputStream deploymentPlan) throws IllegalStateException {
63 return null;
64 }
65
66 public ProgressObject start(TargetModuleID[] moduleIDList) throws IllegalStateException {
67 return null;
68 }
69
70 public ProgressObject stop(TargetModuleID[] moduleIDList) throws IllegalStateException {
71 return null;
72 }
73
74 public ProgressObject undeploy(TargetModuleID[] moduleIDList) throws IllegalStateException {
75 return null;
76 }
77
78 public boolean isRedeploySupported() {
79 return false;
80 }
81
82 public ProgressObject redeploy(TargetModuleID[] moduleIDList, File moduleArchive, File deploymentPlan) throws UnsupportedOperationException, IllegalStateException {
83 return null;
84 }
85
86 public ProgressObject redeploy(TargetModuleID[] moduleIDList, InputStream moduleArchive, InputStream deploymentPlan) throws UnsupportedOperationException, IllegalStateException {
87 return null;
88 }
89
90 public void release() {
91 }
92
93 public Locale getDefaultLocale() {
94 return null;
95 }
96
97 public Locale getCurrentLocale() {
98 return null;
99 }
100
101 public void setLocale(Locale locale) throws UnsupportedOperationException {
102 }
103
104 public Locale[] getSupportedLocales() {
105 return new Locale[0];
106 }
107
108 public boolean isLocaleSupported(Locale locale) {
109 return false;
110 }
111
112 public DConfigBeanVersionType getDConfigBeanVersion() {
113 return null;
114 }
115
116 public boolean isDConfigBeanVersionSupported(DConfigBeanVersionType version) {
117 return false;
118 }
119
120 public void setDConfigBeanVersion(DConfigBeanVersionType version) throws DConfigBeanVersionUnsupportedException {
121 }
122 }