Learn R Programming

geometa (version 0.6-2)

GMLTimePeriod: GMLTimePeriod

Description

GMLTimePeriod

Usage

GMLTimePeriod

Arguments

Value

Object of R6Class for modelling an GMLTimePeriod

Format

R6Class object.

Fields

beginPosition

[POSIXt]

endPosition

[POSIXt]

duration

[character]

Methods

new(xml, beginPosition, endPosition)

This method is used to instantiate an GMLTimePeriod

setBeginPosition(beginPosition)

Sets the begin position (beginning date or date and time of the resource contents), as object of class "POSIXct"/"POSIXt" or "Date"

setEndPosition(endPosition)

Sets the end position (ending date or date and time of the resource contents), as object of class "POSIXct"/"POSIXt" or "Date"

computeInterval()

Computes the ISO interval string and set as GML id

setId(id)

Sets the GML id string.

setDuration(years, months, days, hours, mins, secs)

Set duration (Length of time between measurements)

Examples

Run this code
# NOT RUN {
  start <- ISOdate(2000, 1, 12, 12, 59, 45)
  end <- ISOdate(2010, 8, 22, 13, 12, 43)
  md <- GMLTimePeriod$new(beginPosition = start, endPosition = end)
  xml <- md$encode()

# }

Run the code above in your browser using DataLab