mirror of https://github.com/apache/jclouds.git
Make Datapoint getters public
This commit is contained in:
parent
e28d45ec18
commit
c03265785e
|
@ -56,7 +56,7 @@ public class Datapoint {
|
|||
* return Average of samples for the datapoint.
|
||||
*/
|
||||
@Nullable
|
||||
Double getAverage() {
|
||||
public Double getAverage() {
|
||||
return average;
|
||||
}
|
||||
|
||||
|
@ -64,7 +64,7 @@ public class Datapoint {
|
|||
* return Maximum of the samples used for the datapoint.
|
||||
*/
|
||||
@Nullable
|
||||
Double getMaximum() {
|
||||
public Double getMaximum() {
|
||||
return maximum;
|
||||
}
|
||||
|
||||
|
@ -72,7 +72,7 @@ public class Datapoint {
|
|||
* return Minimum of samples for the datapoint.
|
||||
*/
|
||||
@Nullable
|
||||
Double getMinimum() {
|
||||
public Double getMinimum() {
|
||||
return minimum;
|
||||
}
|
||||
|
||||
|
@ -80,7 +80,7 @@ public class Datapoint {
|
|||
* return Indicates the beginning of the time aggregation for this value and samples.
|
||||
*/
|
||||
@Nullable
|
||||
Date getTimestamp() {
|
||||
public Date getTimestamp() {
|
||||
return timestamp;
|
||||
}
|
||||
|
||||
|
@ -88,7 +88,7 @@ public class Datapoint {
|
|||
* return The number of Measurements that contributed to the aggregate value of this datapoint.
|
||||
*/
|
||||
@Nullable
|
||||
Double getSamples() {
|
||||
public Double getSamples() {
|
||||
return samples;
|
||||
}
|
||||
|
||||
|
@ -96,7 +96,7 @@ public class Datapoint {
|
|||
* return Sum of samples for the datapoint.
|
||||
*/
|
||||
@Nullable
|
||||
Double getSum() {
|
||||
public Double getSum() {
|
||||
return sum;
|
||||
}
|
||||
|
||||
|
@ -104,7 +104,7 @@ public class Datapoint {
|
|||
* return Standard unit used for the datapoint.
|
||||
*/
|
||||
@Nullable
|
||||
StandardUnit getUnit() {
|
||||
public StandardUnit getUnit() {
|
||||
return unit;
|
||||
}
|
||||
|
||||
|
@ -112,7 +112,7 @@ public class Datapoint {
|
|||
* return CustomUnit defined for the datapoint.
|
||||
*/
|
||||
@Nullable
|
||||
String getCustomUnit() {
|
||||
public String getCustomUnit() {
|
||||
return customUnit;
|
||||
}
|
||||
|
||||
|
|
|
@ -23,8 +23,11 @@ import static com.google.common.base.Preconditions.checkNotNull;
|
|||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.Properties;
|
||||
import java.util.Set;
|
||||
|
||||
import org.jclouds.Constants;
|
||||
import org.jclouds.cloudwatch.domain.Datapoint;
|
||||
import org.jclouds.logging.Logger;
|
||||
import org.jclouds.logging.log4j.config.Log4JLoggingModule;
|
||||
import org.jclouds.rest.RestContext;
|
||||
import org.jclouds.rest.RestContextFactory;
|
||||
|
@ -89,7 +92,10 @@ public class CloudWatchClientLiveTest {
|
|||
protected void getMetricStatisticsInRegion(String region) {
|
||||
Calendar cal = Calendar.getInstance();
|
||||
cal.add(Calendar.MINUTE, -1);
|
||||
assert client.getMetricStatisticsInRegion(region, "CPUUtilization", cal.getTime(), new Date(), 60, "Average") != null;
|
||||
|
||||
Set<Datapoint> datapoints = client.getMetricStatisticsInRegion(
|
||||
region, "CPUUtilization", cal.getTime(), new Date(), 60, "Average");
|
||||
assert datapoints != null;
|
||||
}
|
||||
|
||||
@AfterTest
|
||||
|
|
Loading…
Reference in New Issue