1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package com.fatwire.gst.foundation.vwebroot;
17
18 import COM.FutureTense.Interfaces.Utilities;
19
20 import com.fatwire.assetapi.data.AssetId;
21 import com.openmarket.xcelerate.asset.AssetIdImpl;
22
23
24
25
26
27
28
29 final class VWebrootBeanImpl implements VirtualWebroot {
30
31 public static final String GST_VIRTUAL_WEBROOT = "GSTVirtualWebroot";
32 private AssetId id;
33 private String masterVWebroot;
34 private String envVWebroot;
35 private String envName;
36
37 VWebrootBeanImpl(long id, String masterVWebroot, String envVWebroot, String envName) {
38 this.id = new AssetIdImpl(GST_VIRTUAL_WEBROOT, id);
39 if (!Utilities.goodString(masterVWebroot))
40 throw new IllegalArgumentException("Invalid Master VWebroot:" + masterVWebroot);
41 this.masterVWebroot = masterVWebroot;
42 if (!Utilities.goodString(envVWebroot))
43 throw new IllegalArgumentException("Invalid Env VWebroot:" + envVWebroot);
44 this.envVWebroot = envVWebroot;
45 if (!Utilities.goodString(envName))
46 throw new IllegalArgumentException("Invalid Env Name:" + envName);
47 this.envName = envName;
48 }
49
50 public AssetId getId() {
51 return id;
52 }
53
54 public String getMasterVirtualWebroot() {
55 return masterVWebroot;
56 }
57
58 public String getEnvironmentVirtualWebroot() {
59 return envVWebroot;
60 }
61
62 public String getEnvironmentName() {
63 return envName;
64 }
65 }