EMMA Coverage Report (generated Wed Jun 22 19:47:49 EDT 2011)
[all classes][org.jclouds.gogrid]

COVERAGE SUMMARY FOR SOURCE FILE [GoGridPropertiesBuilder.java]

nameclass, %method, %block, %line, %
GoGridPropertiesBuilder.java100% (1/1)100% (2/2)100% (44/44)100% (11/11)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class GoGridPropertiesBuilder100% (1/1)100% (2/2)100% (44/44)100% (11/11)
GoGridPropertiesBuilder (Properties): void 100% (1/1)100% (4/4)100% (2/2)
defaultProperties (): Properties 100% (1/1)100% (40/40)100% (9/9)

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 */
19package org.jclouds.gogrid;
20 
21import static org.jclouds.Constants.PROPERTY_API_VERSION;
22import static org.jclouds.Constants.PROPERTY_ENDPOINT;
23import static org.jclouds.Constants.PROPERTY_ISO3166_CODES;
24import static org.jclouds.gogrid.reference.GoGridConstants.PROPERTY_GOGRID_DEFAULT_DC;
25import static org.jclouds.location.reference.LocationConstants.ISO3166_CODES;
26import static org.jclouds.location.reference.LocationConstants.PROPERTY_ZONE;
27import static org.jclouds.location.reference.LocationConstants.PROPERTY_ZONES;
28 
29import java.util.Properties;
30 
31import org.jclouds.PropertiesBuilder;
32 
33/**
34 * Builds properties used in GoGrid Clients
35 * 
36 * @author Adrian Cole
37 * @author Oleksiy Yarmula
38 * 
39 */
40public class GoGridPropertiesBuilder extends PropertiesBuilder {
41   @Override
42   protected Properties defaultProperties() {
43      Properties properties = super.defaultProperties();
44      properties.setProperty(PROPERTY_ZONES, "1,2");
45      properties.setProperty(PROPERTY_ISO3166_CODES, "US-CA,US-VA");
46      properties.setProperty(PROPERTY_ZONE + ".1." + ISO3166_CODES, "US-CA");
47      properties.setProperty(PROPERTY_ZONE + ".2." + ISO3166_CODES, "US-VA");
48      properties.setProperty(PROPERTY_API_VERSION, GoGridAsyncClient.VERSION);
49      properties.setProperty(PROPERTY_ENDPOINT, "https://api.gogrid.com/api");
50      properties.setProperty(PROPERTY_GOGRID_DEFAULT_DC, "1");
51      return properties;
52   }
53 
54   public GoGridPropertiesBuilder(Properties properties) {
55      super(properties);
56   }
57 
58}

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