1 /**
2 *
3 * Copyright (C) 2011 Cloud Conscious, LLC. <info@cloudconscious.com>
4 *
5 * ====================================================================
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 * ====================================================================
18 */
19 package org.jclouds.vcloud.domain.network;
20
21 import java.util.List;
22 import java.util.Set;
23
24 import javax.annotation.Nullable;
25
26 import org.jclouds.vcloud.domain.ReferenceType;
27 import org.jclouds.vcloud.domain.Task;
28 import org.jclouds.vcloud.domain.internal.VDCImpl;
29
30 import com.google.inject.ImplementedBy;
31
32 /**
33 * A vDC is a deployment environment for vApps. A Vdc element provides a user view of a vDC.
34 *
35 * @author Adrian Cole
36 */
37 @org.jclouds.vcloud.endpoints.Network
38 @ImplementedBy(VDCImpl.class)
39 public interface OrgNetwork extends ReferenceType {
40 /**
41 * The org this network belongs to.
42 *
43 * @since vcloud api 0.9
44 */
45 @Nullable
46 ReferenceType getOrg();
47
48 /**
49 * optional description
50 *
51 * @since vcloud api 0.8
52 */
53 @Nullable
54 String getDescription();
55
56 /**
57 * readâonly container for Task elements. Each element in the container represents a queued,
58 * running, or failed task owned by this object.
59 *
60 * @since vcloud api 0.9
61 */
62 List<Task> getTasks();
63
64 /**
65 *
66 * @return properties of the network
67 *
68 * @since vcloud api 0.9, but emulated for 0.8
69 */
70 Configuration getConfiguration();
71
72 /**
73 * A reference the network pool from which this network is provisioned. This element, which is
74 * required when creating a NatRouted or Isolated network, is returned in response to a creation
75 * request but not shown in subsequent GET requests.
76 *
77 * @since vcloud api 0.9
78 */
79 @Nullable
80 ReferenceType getNetworkPool();
81
82 /**
83 * list of external IP addresses that this network can use for NAT.
84 *
85 * @since vcloud api 0.9
86 */
87 Set<String> getAllowedExternalIpAddresses();
88
89 /**
90 * The Configuration element specifies properties of a network.
91 */
92 interface Configuration {
93 /**
94 * defines the address range, gateway, netmask, and other properties of the network.
95 *
96 * @since vcloud api 0.9, but emulated for 0.8
97 */
98 @Nullable
99 IpScope getIpScope();
100
101 /**
102 * reference to a network to which this network connects
103 *
104 * @since vcloud api 0.9
105 */
106 @Nullable
107 ReferenceType getParentNetwork();
108
109 /**
110 * defines how this network is connected to its ParentNetwork
111 *
112 * @since vcloud api 0.8
113 */
114 FenceMode getFenceMode();
115
116 /**
117 * defines a set of network features.
118 *
119 * @since vcloud api 0.9, but emulated for 0.8
120 */
121 @Nullable Features getFeatures();
122 }
123
124 }