Sha256: f96bd26ead48c62267c21c6e262f3881cec046ceb910a5668c4b397438540336

Contents?: true

Size: 1.41 KB

Versions: 3

Compression:

Stored size: 1.41 KB

Contents

# frozen_string_literal: true

require "lutaml/model"
require_relative "time_instant_property"
require_relative "time_interval_length"
require_relative "time_position"
require_relative "abstract_time_geometric_primitive"

module Ogc
  module Gml
    class TimePeriod < AbstractTimeGeometricPrimitive
      attribute :begin_position, TimePosition
      attribute :begin, TimeInstantProperty
      attribute :end_position, TimePosition
      attribute :end, TimeInstantProperty
      attribute :duration, :string
      attribute :time_interval, TimeIntervalLength

      xml do
        root "TimePeriod"
        namespace "http://www.opengis.net/gml/3.2", "gml"

        map_attribute "id", to: :id, prefix: "gml", namespace: "http://www.opengis.net/gml/3.2"
        map_attribute "frame", to: :frame
        map_element "metaDataProperty", to: :meta_data_property
        map_element "description", to: :description
        map_element "descriptionReference", to: :description_reference
        map_element "identifier", to: :identifier
        map_element "name", to: :name
        map_element "relatedTime", to: :related_time
        map_element "beginPosition", to: :begin_position
        map_element "begin", to: :begin
        map_element "endPosition", to: :end_position
        map_element "end", to: :end
        map_element "duration", to: :duration
        map_element "timeInterval", to: :time_interval
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ogc-gml-1.0.3 lib/ogc/gml/time_period.rb
ogc-gml-1.0.2 lib/ogc/gml/time_period.rb
ogc-gml-1.0.1 lib/ogc/gml/time_period.rb