Skip to contents

Basic R6 object for Log, any Log inherit from here

Public fields

filename

A character of where the log is to be stored.

output

The log content.

Methods


Method new()

Initializes the object and specifies some default parameters.

Usage

Log$new(filename, output)

Arguments

filename

A character of where the log is to be stored.

output

The log content.

Returns

NULL


Method print()

Print message with filename

Usage

Log$print()

Returns

A message on screen


Method open()

Opens the connection to the output filename.

Usage

Log$open(type = c("output", "message"))

Arguments

type

A character vector of the output types.

Returns

Invisible TRUE


Method close()

Closes the connection to the output file

Usage

Log$close()

Returns

Invisible TRUE


Method get_filename()

Get output filename

Usage

Log$get_filename()

Returns

A character with the filename


Method set_filename()

Set a new output filename

Usage

Log$set_filename(value)

Arguments

value

A character with the new filename.

Returns

Invisible TRUE


Method delete()

Delete log file

Usage

Log$delete()

Returns

Invisible TRUE


Method open_system()

Open log with system viewer

Usage

Log$open_system()

Returns

Invisible TRUE


Method clone()

The objects of this class are cloneable with this method.

Usage

Log$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.