EMMA Coverage Report (generated Mon Oct 17 05:41:20 EDT 2011)
[all classes][org.jclouds.aws.ec2.compute.suppliers]

COVERAGE SUMMARY FOR SOURCE FILE [AWSEC2HardwareSupplier.java]

nameclass, %method, %block, %line, %
AWSEC2HardwareSupplier.java0%   (0/1)0%   (0/2)0%   (0/52)0%   (0/7)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class AWSEC2HardwareSupplier0%   (0/1)0%   (0/2)0%   (0/52)0%   (0/7)
AWSEC2HardwareSupplier (Set): void 0%   (0/1)0%   (0/6)0%   (0/3)
get (): Set 0%   (0/1)0%   (0/46)0%   (0/4)

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.aws.ec2.compute.suppliers;
20 
21import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.c1_medium;
22import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.c1_xlarge;
23import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.cc1_4xlarge;
24import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m1_large;
25import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m1_small32;
26import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m1_xlarge;
27import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m2_2xlarge;
28import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m2_4xlarge;
29import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.m2_xlarge;
30import static org.jclouds.ec2.compute.domain.EC2HardwareBuilder.t1_micro;
31 
32import java.util.Set;
33 
34import javax.inject.Inject;
35import javax.inject.Singleton;
36 
37import org.jclouds.aws.ec2.compute.config.ClusterCompute;
38import org.jclouds.compute.domain.Hardware;
39import org.jclouds.ec2.compute.suppliers.EC2HardwareSupplier;
40 
41import com.google.common.collect.ImmutableSet;
42import com.google.common.collect.ImmutableSet.Builder;
43 
44/**
45 * 
46 * @author Adrian Cole
47 */
48@Singleton
49public class AWSEC2HardwareSupplier extends EC2HardwareSupplier {
50 
51   private final Set<String> ccAmis;
52 
53   @Inject
54   public AWSEC2HardwareSupplier(@ClusterCompute Set<String> ccAmis) {
55      this.ccAmis = ccAmis;
56   }
57 
58   @Override
59   public Set<? extends Hardware> get() {
60      Builder<Hardware> sizes = ImmutableSet.builder();
61      sizes.add(cc1_4xlarge().supportsImageIds(ccAmis).build());
62      sizes.addAll(ImmutableSet.<Hardware> of(t1_micro().build(), c1_medium().build(), c1_xlarge().build(), m1_large()
63               .build(), m1_small32().build(), m1_xlarge().build(), m2_xlarge().build(), m2_2xlarge().build(),
64               m2_4xlarge().build()));
65      return sizes.build();
66   }
67}

[all classes][org.jclouds.aws.ec2.compute.suppliers]
EMMA 2.0.5312 (C) Vladimir Roubtsov