EMMA Coverage Report (generated Mon Oct 17 05:41:20 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% (49/49)100% (12/12)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class GoGridPropertiesBuilder100% (1/1)100% (2/2)100% (49/49)100% (12/12)
GoGridPropertiesBuilder (Properties): void 100% (1/1)100% (4/4)100% (2/2)
defaultProperties (): Properties 100% (1/1)100% (45/45)100% (10/10)

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.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,3");
45      properties.setProperty(PROPERTY_ISO3166_CODES, "US-CA,US-VA,BR-SP");
46      properties.setProperty(PROPERTY_ZONE + ".1." + ISO3166_CODES, "US-CA");
47      properties.setProperty(PROPERTY_ZONE + ".2." + ISO3166_CODES, "US-VA");
48      properties.setProperty(PROPERTY_ZONE + ".3." + ISO3166_CODES, "BR-SP");
49      properties.setProperty(PROPERTY_API_VERSION, GoGridAsyncClient.VERSION);
50      properties.setProperty(PROPERTY_ENDPOINT, "https://api.gogrid.com/api");
51      properties.setProperty(PROPERTY_GOGRID_DEFAULT_DC, "1");
52      return properties;
53   }
54 
55   public GoGridPropertiesBuilder(Properties properties) {
56      super(properties);
57   }
58 
59}

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