123456789_123456789_123456789_123456789_123456789_

Class: CSV::FieldInfo

Relationships & Source Files
Super Chains via Extension / Inclusion / Inheritance
Class Chain:
self, Struct
Instance Chain:
self, Struct
Inherits: Struct
  • Object
Defined in: lib/csv.rb

Overview

A FieldInfo Struct contains details about a field’s position in the data source it was read from. ::CSV will pass this Struct to some blocks that make decisions based on field structure. See CSV.convert_fields() for an example.

index

The zero-based index of the field in its row.

line

The line of the data source this row is from.

header

The header for the column, when available.

quoted?

True or false, whether the original value is quoted or not.

Instance Attribute Summary

  • #header rw

    A FieldInfo Struct contains details about a field’s position in the data source it was read from.

  • #index rw

    A FieldInfo Struct contains details about a field’s position in the data source it was read from.

  • #line rw

    A FieldInfo Struct contains details about a field’s position in the data source it was read from.

Instance Method Summary

  • #quoted?

    A FieldInfo Struct contains details about a field’s position in the data source it was read from.

Instance Attribute Details

#header (rw)

A FieldInfo Struct contains details about a field’s position in the data source it was read from. ::CSV will pass this Struct to some blocks that make decisions based on field structure. See CSV.convert_fields() for an example.

index

The zero-based index of the field in its row.

line

The line of the data source this row is from.

header

The header for the column, when available.

quoted?

True or false, whether the original value is quoted or not.

[ GitHub ]

  
# File 'lib/csv.rb', line 868

FieldInfo = Struct.new(:index, :line, :header, :quoted?)

#index (rw)

A FieldInfo Struct contains details about a field’s position in the data source it was read from. ::CSV will pass this Struct to some blocks that make decisions based on field structure. See CSV.convert_fields() for an example.

index

The zero-based index of the field in its row.

line

The line of the data source this row is from.

header

The header for the column, when available.

quoted?

True or false, whether the original value is quoted or not.

[ GitHub ]

  
# File 'lib/csv.rb', line 868

FieldInfo = Struct.new(:index, :line, :header, :quoted?)

#line (rw)

A FieldInfo Struct contains details about a field’s position in the data source it was read from. ::CSV will pass this Struct to some blocks that make decisions based on field structure. See CSV.convert_fields() for an example.

index

The zero-based index of the field in its row.

line

The line of the data source this row is from.

header

The header for the column, when available.

quoted?

True or false, whether the original value is quoted or not.

[ GitHub ]

  
# File 'lib/csv.rb', line 868

FieldInfo = Struct.new(:index, :line, :header, :quoted?)

Instance Method Details

#quoted?

A FieldInfo Struct contains details about a field’s position in the data source it was read from. ::CSV will pass this Struct to some blocks that make decisions based on field structure. See CSV.convert_fields() for an example.

index

The zero-based index of the field in its row.

line

The line of the data source this row is from.

header

The header for the column, when available.

quoted?

True or false, whether the original value is quoted or not.

[ GitHub ]

  
# File 'lib/csv.rb', line 868

FieldInfo = Struct.new(:index, :line, :header, :quoted?)