EMMA Coverage Report (generated Mon Oct 17 05:41:20 EDT 2011)
[all classes][org.jclouds.vcloud.domain]

COVERAGE SUMMARY FOR SOURCE FILE [VDCStatus.java]

nameclass, %method, %block, %line, %
VDCStatus.java50%  (1/2)43%  (3/7)49%  (63/128)33%  (4.6/14)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class VDCStatus$10%   (0/1)0%   (0/1)0%   (0/33)0%   (0/1)
<static initializer> 0%   (0/1)0%   (0/33)0%   (0/1)
     
class VDCStatus100% (1/1)50%  (3/6)66%  (63/95)33%  (4.6/14)
value (): int 0%   (0/1)0%   (0/15)0%   (0/6)
valueOf (String): VDCStatus 0%   (0/1)0%   (0/5)0%   (0/1)
values (): VDCStatus [] 0%   (0/1)0%   (0/4)0%   (0/1)
fromValue (int): VDCStatus 100% (1/1)33%  (4/12)33%  (2/6)
<static initializer> 100% (1/1)100% (54/54)100% (2/2)
VDCStatus (String, int): void 100% (1/1)100% (5/5)100% (2/2)

1/**
2 * Licensed to jclouds, Inc. (jclouds) under one or more
3 * contributor license agreements.  See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership.  jclouds licenses this file
6 * to you under the Apache License, Version 2.0 (the
7 * "License"); you may not use this file except in compliance
8 * with the License.  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,
13 * software distributed under the License is distributed on an
14 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15 * KIND, either express or implied.  See the License for the
16 * specific language governing permissions and limitations
17 * under the License.
18 */
19package org.jclouds.vcloud.domain;
20 
21/**
22 * The creation status of the vDC
23 * 
24 * @see VDC#getStatus
25 */
26public enum VDCStatus {
27 
28   CREATION_FAILED, NOT_READY, READY, UNKNOWN, UNRECOGNIZED;
29 
30   public int value() {
31      switch (this) {
32         case CREATION_FAILED:
33            return -1;
34         case NOT_READY:
35            return 0;
36         case READY:
37            return 1;
38         case UNKNOWN:
39            return 2;
40         default:
41            return 3;
42      }
43   }
44 
45   public static VDCStatus fromValue(int status) {
46      switch (status) {
47         case -1:
48            return CREATION_FAILED;
49         case 0:
50            return NOT_READY;
51         case 1:
52            return READY;
53         case 2:
54            return UNKNOWN;
55         default:
56            return UNRECOGNIZED;
57      }
58   }
59}

[all classes][org.jclouds.vcloud.domain]
EMMA 2.0.5312 (C) Vladimir Roubtsov