Skip navigation links

Oracle® Information Rights Management Server Java API Reference
11g Release 1 (11.1.1)

E12907-02


oracle.irm.engine.core.time
Interface TimeRange


public interface TimeRange

An absolute time range. A TimeRange specifies a range of time starting at the Begin time and ending at the End time. A time range can be also be created by specifying a time interval e.g. create a time range from starting now and ending in ten minutes. It is valid for the time range to go backwards. i.e. the begin time can be after the end time.

Creation

Instances of Time Range objects can be created using the following factory style method(s).

TimeRange object = createTimeRange(
    begin,
    end);
TimeRange object = createTimeRange(
    date,
    direction,
    interval,
    size);

XML Serialization

Time Range instances can be serialized as an XML document. This XML document can also be used to recreate a Time Range object. The following XML document shows an example Time Range in XML form.

<?xml version="1.0" encoding="UTF-8"?>
<core:TimeRange xmlns:core="http://xmlns.oracle.com/irm/core">
    <begin>2007-01-01T12:00:00.000+01:00</begin>
    <end>2007-01-01T13:00:00.000+01:00</end>
</core:TimeRange>


Nested Class Summary
static class TimeRange.Direction
          Time interval direction.
static class TimeRange.Interval
          Time interval.

 

Method Summary
 Date getBegin()
          Start of the time range.
 Date getEnd()
          End of the time range.

 

Method Detail

getBegin

Date getBegin()
Start of the time range.

State

The date returned by this method can be safely altered without affecting the internal state of the object.
Returns:
the value of the property. This method will never return null.

getEnd

Date getEnd()
End of the time range.

State

The date returned by this method can be safely altered without affecting the internal state of the object.
Returns:
the value of the property. This method will never return null.

Skip navigation links

Oracle® Information Rights Management Server Java API Reference
11g Release 1 (11.1.1)

E12907-02


Copyright © 2010, Oracle. All rights reserved.