Serializer: Serializer class - base class for JSON/YAML serializers

Description Public fields Methods

Description

Serializer class - base class for JSON/YAML serializers

Serializer class - base class for JSON/YAML serializers

Public fields

file_extension

(character) A file extension

path

(character) full path to the yaml file

Methods

Public methods


Method new()

Create a new YAML object

Usage
Serializer$new(file_extension = NULL, path = NULL)
Arguments
file_extension

(character) A file extension

path

(character) path to the cassette, excluding the cassette directory and the file extension

Returns

A new YAML object


Method serialize()

Serializes a hash - REPLACED BY YAML/JSON METHODS

Usage
Serializer$serialize(x, path, bytes)
Arguments
x

(list) the object to serialize

path

(character) the file path

bytes

(logical) whether to preserve exact body bytes or not

Returns

(character) the YAML or JSON string to write to disk


Method deserialize()

Serializes a file - REPLACED BY YAML/JSON METHODS

Usage
Serializer$deserialize()

Method clone()

The objects of this class are cloneable with this method.

Usage
Serializer$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.


vcr documentation built on June 1, 2021, 1:06 a.m.