seasonder_readSeaSondeCSFileHeaderV6 {SeaSondeR}R Documentation

Read SeaSonde CS File Header V6

Description

This function reads the header of a SeaSonde CS File Version 6. It sequentially reads blocks based on the provided specifications and returns the read data.

Usage

seasonder_readSeaSondeCSFileHeaderV6(
  specs,
  connection,
  endian = "big",
  prev_data = NULL
)

Arguments

specs

A list of specifications for reading the file header. It should contain three main elements: nCS6ByteSize, block_spec, and blocks, each containing further specifications for reading various parts of the header.

connection

A connection object to the SeaSonde CS file.

endian

The byte order for reading the file. Default is "big".

prev_data

Previous data, if any, that might affect the current reading. Default is NULL.

Value

A list containing the read data, organized based on the block keys.

Condition Management

This function utilizes the rlang package to manage conditions and provide detailed and structured condition messages:

Condition Classes:

Condition Cases:

The following are the scenarios when errors or conditions are raised:

Restart Options:

The function provides the following restart option:

seasonder_v6_skip_transformation: This restart allows users to skip the transformation for a specific block and instead return the provided value.

Effects of Restart Options:

Using the seasonder_v6_skip_transformation restart:

Proper error management ensures the integrity of the reading process and provides detailed feedback to users regarding issues and potential resolutions.

See Also

seasonder_check_specs seasonder_readSeaSondeCSFileBlock readV6BlockData seasonder_v6_skip_transformation


[Package SeaSondeR version 0.2.8 Index]