CsvCodec

zio.blocks.schema.csv.CsvCodec
abstract class CsvCodec[A] extends TextCodec[A]

Abstract codec for encoding and decoding values to/from CSV format.

Extends TextCodec[A] to provide CSV-specific serialization.

Type parameters

A

The type being encoded/decoded

Attributes

Source
CsvCodec.scala
Graph
Supertypes
class TextCodec[A]
class Object
trait Matchable
class Any

Members list

Value members

Abstract methods

def headerNames: IndexedSeq[String]

Returns the header names for CSV columns.

Returns the header names for CSV columns.

Attributes

Returns

field names that will appear in the CSV header row

Source
CsvCodec.scala

Inherited and Abstract methods

def decode(input: CharBuffer): Either[SchemaError, A]

Decodes the specified input into a value of the target type.

Decodes the specified input into a value of the target type.

Value parameters

input

The input data that needs to be decoded.

Attributes

Returns

Either a SchemaError indicating the decoding failure, or a decoded value.

Inherited from:
Codec
Source
Codec.scala
def encode(value: A, output: CharBuffer): Unit

Encodes the given value into the specified output representation.

Encodes the given value into the specified output representation.

Value parameters

output

The target output into which the value will be encoded.

value

The value to be encoded.

Attributes

Returns

This method does not return a value.

Inherited from:
Codec
Source
Codec.scala