geoflow_subject: Geoflow subject class

geoflow_subjectR Documentation

Geoflow subject class

Description

This class models a subject

Format

R6Class object.

Details

geoflow_subject

Value

Object of R6Class for modelling a subject

Public fields

key

subject key

name

subject name

uri

subject URI

dates

subject date(s)

keywords

subject keywords

Methods

Public methods


Method new()

Initializes an object of class geoflow_subject

Usage
geoflow_subject$new(str = NULL, kvp = NULL)
Arguments
str

a character string to initialize from, using key-based syntax

kvp

an object of class geoflow_kvp


Method setKey()

Sets subject key

Usage
geoflow_subject$setKey(key)
Arguments
key

key


Method setName()

Sets subject name

Usage
geoflow_subject$setName(name)
Arguments
name

name


Method setUri()

Sets subject URI

Usage
geoflow_subject$setUri(uri)
Arguments
uri

uri


Method setDate()

Sets date

Usage
geoflow_subject$setDate(dateType, date)
Arguments
dateType

type of date

date

date


Method addKeyword()

Adds a keyword

Usage
geoflow_subject$addKeyword(keyword, uri = NULL)
Arguments
keyword

keyword

uri

keyword URI. Default is NULL


Method getKeywords()

Get keywords associated with the subject

Usage
geoflow_subject$getKeywords(pretty = FALSE)
Arguments
pretty

whether the output has to prettyfied as data.frame

Returns

the list of keywords as list of geoflow_keyword objects or data.frame


Method clone()

The objects of this class are cloneable with this method.

Usage
geoflow_subject$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.

Author(s)

Emmanuel Blondel <emmanuel.blondel1@gmail.com>

Examples

## Not run: 
  subject <- geoflow_subject$new()
  subject$setKey("theme")
  subject$setName("General")
  subject$setUri("http://somelink/general")
  subject$addKeyword("keyword1", "http://somelink/keyword1")
  subject$addKeyword("keyword2", "http://somelink/keyword2")
  subject$addKeyword("keyword3", "http://somelink/keyword3")

## End(Not run)


geoflow documentation built on Dec. 12, 2025, 5:08 p.m.