R/gen-PharmMLRef.R

Defines functions Description_acc id_acc name_acc so_PharmMLRef_set_Description so_PharmMLRef_get_Description so_PharmMLRef_set_id so_PharmMLRef_get_id so_PharmMLRef_set_name so_PharmMLRef_get_name so_PharmMLRef_unref so_PharmMLRef_ref so_PharmMLRef_free so_PharmMLRef_copy so_PharmMLRef_new

# libsoc - Library to handle standardised output files
# Copyright (C) 2015 Rikard Nordgren
# 
# This file was autogenerated and should not be edited
# 
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2 of the License, or (at your option) any later version.
# 
# his library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# Lesser General Public License for more details.
# 
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, see <http://www.gnu.org/licenses/>.

so_PharmMLRef_new <- function() {
	obj = .Call("r_so_PharmMLRef_new")
}

so_PharmMLRef_copy <- function(self) {
	.Call("r_so_PharmMLRef_copy", self)
}

so_PharmMLRef_free <- function(self) {
	.Call("r_so_PharmMLRef_free", self)
}

so_PharmMLRef_ref <- function(self) {
	.Call("r_so_PharmMLRef_ref", self)
}

so_PharmMLRef_unref <- function(self) {
	.Call("r_so_PharmMLRef_unref", self)
}

so_PharmMLRef_get_name <- function(self) {
	.Call("r_so_PharmMLRef_get_name", self)
}

so_PharmMLRef_set_name <- function(self, value) {
	.Call("r_so_PharmMLRef_set_name", self, value)
}

so_PharmMLRef_get_id <- function(self) {
	.Call("r_so_PharmMLRef_get_id", self)
}

so_PharmMLRef_set_id <- function(self, value) {
	.Call("r_so_PharmMLRef_set_id", self, value)
}

so_PharmMLRef_get_Description <- function(self) {
	.Call("r_so_PharmMLRef_get_Description", self)
}

so_PharmMLRef_set_Description <- function(self, value) {
	.Call("r_so_PharmMLRef_set_Description", self, value)
}

name_acc <- function(value)
{
	if (!isnull(.self$.cobj)) {
		if (missing(value)) {
			so_PharmMLRef_get_name(.self$.cobj)
		} else {
			stopifnot(is.character(value), length(value) == 1)
			so_PharmMLRef_set_name(.self$.cobj, value)
		}
	}
}

id_acc <- function(value)
{
	if (!isnull(.self$.cobj)) {
		if (missing(value)) {
			so_PharmMLRef_get_id(.self$.cobj)
		} else {
			stopifnot(is.character(value), length(value) == 1)
			so_PharmMLRef_set_id(.self$.cobj, value)
		}
	}
}

Description_acc <- function(value)
{
	if (!isnull(.self$.cobj)) {
		if (missing(value)) {
			so_PharmMLRef_get_Description(.self$.cobj)
		} else {
			if (!is(value, "character")) {
				stop("object must be of type 'character'")
			}
			so_PharmMLRef_set_Description(.self$.cobj, value)
		}
	}
}

so_PharmMLRef = setRefClass("so_PharmMLRef",
	fields=list(
		name = name_acc,
		id = id_acc,
		Description = Description_acc,
		.cobj = "externalptr"
	),
	methods=list(
		copy = function() {
			copy = so_PharmMLRef_copy(.self$.cobj)
			so_PharmMLRef$new(cobj=copy)
		},
		initialize = function(cobj) {
			if (missing(cobj)) {
				.cobj <<- so_PharmMLRef_new()
			} else {
				.cobj <<- cobj
			}
		},
		finalize = function() {
			so_PharmMLRef_unref(.self$.cobj)
		}
	)
)

Try the libsoc package in your browser

Any scripts or data that you put into this service are public.

libsoc documentation built on Feb. 3, 2022, 5:07 p.m.