@Generated(value="com.amazonaws:awsjavasdkcodegenerator") public class TumblingWindow extends Object implements Serializable, Cloneable, StructuredPojo
Contains a tumbling window, which is a repeating fixedsized, nonoverlapping, and contiguous time window. You use this window in metrics to aggregate data from properties and other assets.
You can use m
, h
, d
, and w
when you specify an interval or
offset. Note that m
represents minutes, and w
represents weeks. You can also use
s
to represent seconds in offset
.
The interval
and offset
parameters support the ISO 8601 format. For example, PT5S
represents five
seconds, PT5M
represents five minutes, and PT5H
represents five hours.
Constructor and Description 

TumblingWindow() 
Modifier and Type  Method and Description 

TumblingWindow 
clone() 
boolean 
equals(Object obj) 
String 
getInterval()
The time interval for the tumbling window.

String 
getOffset()
The offset for the tumbling window.

int 
hashCode() 
void 
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . 
void 
setInterval(String interval)
The time interval for the tumbling window.

void 
setOffset(String offset)
The offset for the tumbling window.

String 
toString()
Returns a string representation of this object.

TumblingWindow 
withInterval(String interval)
The time interval for the tumbling window.

TumblingWindow 
withOffset(String offset)
The offset for the tumbling window.

public void setInterval(String interval)
The time interval for the tumbling window. The interval time must be between 1 minute and 1 week.
IoT SiteWise computes the 1w
interval the end of Sunday at midnight each week (UTC), the
1d
interval at the end of each day at midnight (UTC), the 1h
interval at the end of
each hour, and so on.
When IoT SiteWise aggregates data points for metric computations, the start of each interval is exclusive and the end of each interval is inclusive. IoT SiteWise places the computed data point at the end of the interval.
interval
 The time interval for the tumbling window. The interval time must be between 1 minute and 1 week.
IoT SiteWise computes the 1w
interval the end of Sunday at midnight each week (UTC), the
1d
interval at the end of each day at midnight (UTC), the 1h
interval at the end
of each hour, and so on.
When IoT SiteWise aggregates data points for metric computations, the start of each interval is exclusive and the end of each interval is inclusive. IoT SiteWise places the computed data point at the end of the interval.
public String getInterval()
The time interval for the tumbling window. The interval time must be between 1 minute and 1 week.
IoT SiteWise computes the 1w
interval the end of Sunday at midnight each week (UTC), the
1d
interval at the end of each day at midnight (UTC), the 1h
interval at the end of
each hour, and so on.
When IoT SiteWise aggregates data points for metric computations, the start of each interval is exclusive and the end of each interval is inclusive. IoT SiteWise places the computed data point at the end of the interval.
IoT SiteWise computes the 1w
interval the end of Sunday at midnight each week (UTC), the
1d
interval at the end of each day at midnight (UTC), the 1h
interval at the
end of each hour, and so on.
When IoT SiteWise aggregates data points for metric computations, the start of each interval is exclusive and the end of each interval is inclusive. IoT SiteWise places the computed data point at the end of the interval.
public TumblingWindow withInterval(String interval)
The time interval for the tumbling window. The interval time must be between 1 minute and 1 week.
IoT SiteWise computes the 1w
interval the end of Sunday at midnight each week (UTC), the
1d
interval at the end of each day at midnight (UTC), the 1h
interval at the end of
each hour, and so on.
When IoT SiteWise aggregates data points for metric computations, the start of each interval is exclusive and the end of each interval is inclusive. IoT SiteWise places the computed data point at the end of the interval.
interval
 The time interval for the tumbling window. The interval time must be between 1 minute and 1 week.
IoT SiteWise computes the 1w
interval the end of Sunday at midnight each week (UTC), the
1d
interval at the end of each day at midnight (UTC), the 1h
interval at the end
of each hour, and so on.
When IoT SiteWise aggregates data points for metric computations, the start of each interval is exclusive and the end of each interval is inclusive. IoT SiteWise places the computed data point at the end of the interval.
public void setOffset(String offset)
The offset for the tumbling window. The offset
parameter accepts the following:
The offset time.
For example, if you specify 18h
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The ISO 8601 format.
For example, if you specify PT18H
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The 24hour clock.
For example, if you specify 00:03:00
for offset
and 5m
for
interval
, and you create the metric at 2 PM (UTC), you get the first aggregation result at 2:03 PM
(UTC). You get the second aggregation result at 2:08 PM (UTC).
The offset time zone.
For example, if you specify 20210723T18:0008
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) on the day when you create the metric.
If you create the metric after 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) the next day.
offset
 The offset for the tumbling window. The offset
parameter accepts the following:
The offset time.
For example, if you specify 18h
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The ISO 8601 format.
For example, if you specify PT18H
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The 24hour clock.
For example, if you specify 00:03:00
for offset
and 5m
for
interval
, and you create the metric at 2 PM (UTC), you get the first aggregation result at
2:03 PM (UTC). You get the second aggregation result at 2:08 PM (UTC).
The offset time zone.
For example, if you specify 20210723T18:0008
for offset
and 1d
for interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) on the day when you create the metric.
If you create the metric after 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) the next day.
public String getOffset()
The offset for the tumbling window. The offset
parameter accepts the following:
The offset time.
For example, if you specify 18h
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The ISO 8601 format.
For example, if you specify PT18H
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The 24hour clock.
For example, if you specify 00:03:00
for offset
and 5m
for
interval
, and you create the metric at 2 PM (UTC), you get the first aggregation result at 2:03 PM
(UTC). You get the second aggregation result at 2:08 PM (UTC).
The offset time zone.
For example, if you specify 20210723T18:0008
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) on the day when you create the metric.
If you create the metric after 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) the next day.
offset
parameter accepts the following:
The offset time.
For example, if you specify 18h
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The ISO 8601 format.
For example, if you specify PT18H
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The 24hour clock.
For example, if you specify 00:03:00
for offset
and 5m
for
interval
, and you create the metric at 2 PM (UTC), you get the first aggregation result at
2:03 PM (UTC). You get the second aggregation result at 2:08 PM (UTC).
The offset time zone.
For example, if you specify 20210723T18:0008
for offset
and 1d
for interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) on the day when you create the metric.
If you create the metric after 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) the next day.
public TumblingWindow withOffset(String offset)
The offset for the tumbling window. The offset
parameter accepts the following:
The offset time.
For example, if you specify 18h
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The ISO 8601 format.
For example, if you specify PT18H
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The 24hour clock.
For example, if you specify 00:03:00
for offset
and 5m
for
interval
, and you create the metric at 2 PM (UTC), you get the first aggregation result at 2:03 PM
(UTC). You get the second aggregation result at 2:08 PM (UTC).
The offset time zone.
For example, if you specify 20210723T18:0008
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) on the day when you create the metric.
If you create the metric after 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) the next day.
offset
 The offset for the tumbling window. The offset
parameter accepts the following:
The offset time.
For example, if you specify 18h
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The ISO 8601 format.
For example, if you specify PT18H
for offset
and 1d
for
interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) on the day when you create the metric.
If you create the metric after 6:00 PM (UTC), you get the first aggregation result at 6 PM (UTC) the next day.
The 24hour clock.
For example, if you specify 00:03:00
for offset
and 5m
for
interval
, and you create the metric at 2 PM (UTC), you get the first aggregation result at
2:03 PM (UTC). You get the second aggregation result at 2:08 PM (UTC).
The offset time zone.
For example, if you specify 20210723T18:0008
for offset
and 1d
for interval
, IoT SiteWise aggregates data in one of the following ways:
If you create the metric before or at 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) on the day when you create the metric.
If you create the metric after 6:00 PM (PST), you get the first aggregation result at 6 PM (PST) the next day.
public String toString()
toString
in class Object
Object.toString()
public TumblingWindow clone()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
 Implementation of ProtocolMarshaller
used to marshall this object's data.