Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/LindsayBradford/go-dbf
/ functions
Functions
115 in github.com/LindsayBradford/go-dbf
⨍
Functions
115
◇
Types & classes
20
↓ 29 callers
Method
Fields
Fields return the fields of the table as a slice
godbf/table.go:330
↓ 23 callers
Function
New
New creates a new dbase table from scratch for the given character encoding
godbf/interpreter.go:131
↓ 15 callers
Method
AddBooleanField
(fieldName string)
godbf/table.go:185
↓ 13 callers
Method
SetFieldValueByName
SetFieldValueByName sets the value for the given row and field name as specified If the field name does not exist, or the value is incompatible with t
godbf/table.go:416
↓ 10 callers
Function
NewFromFile
NewFromFile creates a DbfTable, reading it from a file with the given file name, expecting the supplied encoding.
godbf/io.go:12
↓ 10 callers
Method
NumberOfRecords
NumberOfRecords returns the number of records in the table
godbf/table.go:403
↓ 8 callers
Method
FieldValueByName
FieldValueByName returns the value of a field given row number and name provided
godbf/table.go:542
↓ 7 callers
Method
AddFloatField
(fieldName string, length byte, decimalPlaces uint8)
godbf/table.go:201
↓ 7 callers
Method
AddNewRecord
AddNewRecord adds a new empty record to the table, and returns the index number of the record.
godbf/table.go:375
↓ 6 callers
Method
AddNumberField
(fieldName string, length byte, decimalPlaces uint8)
godbf/table.go:197
↓ 6 callers
Method
AddTextField
(fieldName string, length byte)
godbf/table.go:193
↓ 6 callers
Function
NewFromByteArray
NewFromByteArray creates a DbfTable, reading it from a raw byte array, expecting the supplied encoding.
godbf/interpreter.go:10
↓ 5 callers
Method
GetRowAsSlice
GetRowAsSlice return the record values for the row specified as a string slice
godbf/table.go:559
↓ 5 callers
Method
addField
(fieldName string, fieldType DbaseDataType, length byte, decimalPlaces uint8)
godbf/table.go:205
↓ 4 callers
Method
AddDateField
(fieldName string)
godbf/table.go:189
↓ 4 callers
Method
DecimalPlacesInField
DecimalPlacesInField returns the number of decimal places for the field with the given name. If the field does not exist, or does not use decimal plac
godbf/table.go:360
↓ 4 callers
Method
FieldNames
FieldNames return the names of fields in the table as a slice
godbf/table.go:335
↓ 4 callers
Function
SaveToFile
SaveToFile saves the supplied DbfTable to a file of the specified filename
godbf/io.go:27
↓ 3 callers
Method
decimalCountNotApplicable
decimalCountNotApplicable is a convenience decorator supplying a 0-valued byte. THis is used indicate that the data type describes a field that does n
godbf/field.go:77
↓ 3 callers
Function
uint32ToBytes
(x uint32)
godbf/helpers.go:57
↓ 3 callers
Function
verifyTableIsCorrect
(tableUnderTest *DbfTable, g *GomegaWithT)
godbf/io_test.go:129
↓ 2 callers
Method
Create
(name string)
godbf/helpers.go:15
↓ 2 callers
Method
FieldType
FieldType returns the type of data stored for the field as a DbaseDataType
godbf/field.go:18
↓ 2 callers
Method
FieldValue
FieldValue returns the content for the record at the given row and field index as a string If the row or field index is invalid, an error is returned
godbf/table.go:487
↓ 2 callers
Method
HasField
HasField returns true if the table has a field with the given name If the field does not exist an error is returned.
godbf/table.go:347
↓ 2 callers
Method
LastUpdated
LastUpdated interprets the byte trio in dateOfLastUpdate, returning as close a time.Time value as possible. As no hours, minutes, seconds, etc. are s
godbf/table.go:120
↓ 2 callers
Method
Open
(name string)
godbf/helpers.go:16
↓ 2 callers
Method
Stat
()
godbf/helpers.go:34
↓ 2 callers
Method
UseEncoding
(encoding string)
godbf/table.go:174
↓ 2 callers
Method
fixedFieldLength
fixedFieldLength returns the length in bytes in for the data type if it describes a fixed-length field.
godbf/field.go:54
↓ 2 callers
Method
updateHeader
()
godbf/table.go:289
↓ 1 callers
Method
DecimalPlaces
DecimalPlaces returns the count of decimal places for the field
godbf/field.go:28
↓ 1 callers
Method
Float64FieldValueByName
Float64FieldValueByName returns the value of a field given row number and name provided as a float64
godbf/table.go:530
↓ 1 callers
Method
Int64FieldValueByName
Int64FieldValueByName returns the value of a field given row number and name provided as an int64
godbf/table.go:536
↓ 1 callers
Method
Length
Length returns the length of data stored for the field
godbf/field.go:23
↓ 1 callers
Method
LowDefTime
LowDefTime takes a time.Time and returns a low-definition time.Time equivalent that follows the same simplification approach as LastUpdated().
godbf/table.go:133
↓ 1 callers
Method
Name
Name returns the column name of the field
godbf/field.go:13
↓ 1 callers
Method
RefreshLastUpdated
RefreshLastUpdated refreshes the dateOfLastUpdate to the YYMMDD byte encoding of today, assuming the local timezone. SetLastUpdated() is used by this
godbf/table.go:95
↓ 1 callers
Method
SetFieldValue
SetFieldValue sets the value for the given row and field index as specified If the field index is invalid, or the value is incompatible with the field
godbf/table.go:425
↓ 1 callers
Method
SetLastUpdated
SetLastUpdated sets the dateOfLastUpdate to the YYMMDD byte encoding of the time.Time specified. See dateOfLastUpdate for the various limitations pres
godbf/table.go:101
↓ 1 callers
Method
SetLastUpdatedFromBytes
SetLastUpdatedFromBytes sets the dateOfLastUpdate to the YYMMDD byte encoding of the time specified. The 0-index is assigned to updateYear, the 1-inde
godbf/table.go:111
↓ 1 callers
Method
SetLengthOfEachRecordFromBytes
SetLengthOfEachRecordFromBytes sets lengthOfEachRecord from a byte array.
godbf/table.go:68
↓ 1 callers
Method
SetNumberOfBytesInHeaderFromBytes
SetNumberOfBytesInHeaderFromBytes sets numberOfBytesInHeader from a byte array.
godbf/table.go:63
↓ 1 callers
Method
SetNumberOfRecordsFromBytes
SetNumberOfRecordsFromBytes sets numberOfRecords from a byte array.
godbf/table.go:58
↓ 1 callers
Method
byte
()
godbf/field.go:47
↓ 1 callers
Method
convertToByteSlice
* getByteSlice converts value to byte slice according to given encoding and return a slice that is fixedFieldLength equals to numberOfBytes or les
godbf/table.go:277
↓ 1 callers
Function
deriveFieldName
(s []byte, dt *DbfTable, offset int)
godbf/interpreter.go:85
↓ 1 callers
Function
enforceBlankPadding
Some Dbf encoders pad with null chars instead of blanks, this forces blanks as per https://www.dbase.com/Knowledgebase/INT/db7_file_fmt.htm
godbf/table.go:521
↓ 1 callers
Method
fillFieldWithBlanks
(fieldLength int, offset int, recordOffset int)
godbf/table.go:479
↓ 1 callers
Function
lockSchema
(dt *DbfTable)
godbf/interpreter.go:126
↓ 1 callers
Method
normaliseFieldName
(name string)
godbf/table.go:258
↓ 1 callers
Function
readFile
(filename string)
godbf/helpers.go:37
↓ 1 callers
Function
unpackField
(s []byte, dt *DbfTable, fieldIndex int)
godbf/interpreter.go:56
↓ 1 callers
Function
unpackFields
(s []byte, dt *DbfTable)
godbf/interpreter.go:42
↓ 1 callers
Function
unpackFooter
(data []byte, dt *DbfTable)
godbf/interpreter.go:103
↓ 1 callers
Function
unpackHeader
(s []byte, dt *DbfTable)
godbf/interpreter.go:29
↓ 1 callers
Function
unpackRecords
(data []byte, dt *DbfTable)
godbf/interpreter.go:99
↓ 1 callers
Method
usesDecimalCount
usesDecimalCount indicates whether the data type describes a field that makes use of a field's decimal count setting.
godbf/field.go:66
↓ 1 callers
Method
usesDecimalPlaces
()
godbf/field.go:32
↓ 1 callers
Function
verifyFieldDescriptorsAreCorrect
(tableUnderTest *DbfTable, g *GomegaWithT)
godbf/io_test.go:134
↓ 1 callers
Function
verifyRecordsAreCorrect
(tableUnderTest *DbfTable, g *GomegaWithT)
godbf/io_test.go:165
↓ 1 callers
Function
verifyTableAgainstRawBytes
(s []byte, dt *DbfTable)
godbf/interpreter.go:107
↓ 1 callers
Function
verifyTableAgainstRawFooter
(s []byte, dt *DbfTable)
godbf/interpreter.go:112
↓ 1 callers
Function
verifyTableAgainstRawHeader
(s []byte, dt *DbfTable)
godbf/interpreter.go:118
↓ 1 callers
Function
writeContent
(dt *DbfTable, f *os.File)
godbf/io.go:53
Method
Create
(name string)
godbf/helpers.go:23
Method
Create
(name string)
godbf/io_test.go:278
Method
Create
(name string)
godbf/io_test.go:304
Method
HasRecord
HasRecord returns true if the table has a record with the given number otherwise, false is returned. Use this method before FieldValue() to avoid inde
godbf/table.go:409
Method
Open
(name string)
godbf/helpers.go:24
Method
Open
(name string)
godbf/io_test.go:234
Method
RowIsDeleted
RowIsDeleted returns whether a row has marked as deleted
godbf/table.go:551
Method
SaveFile
Deprecated: Use SaveToFile() instead.
godbf/table.go:571
Method
Stat
(name string)
godbf/helpers.go:17
Method
Stat
(name string)
godbf/helpers.go:25
Method
Stat
(name string)
godbf/io_test.go:252
Function
TestDbfTable_AddBooleanField
(t *testing.T)
godbf/table_test.go:24
Function
TestDbfTable_AddBooleanField_ErrorAfterDataEntryStart
(t *testing.T)
godbf/table_test.go:68
Function
TestDbfTable_AddBooleanField_SecondAttemptFails
(t *testing.T)
godbf/table_test.go:53
Function
TestDbfTable_AddBooleanField_TooLongGetsTruncated
(t *testing.T)
godbf/table_test.go:40
Function
TestDbfTable_AddDateField
(t *testing.T)
godbf/table_test.go:87
Function
TestDbfTable_AddFloatField
(t *testing.T)
godbf/table_test.go:141
Function
TestDbfTable_AddNumericField
(t *testing.T)
godbf/table_test.go:121
Function
TestDbfTable_AddRecordWithNoFieldsDefined_Errors
(t *testing.T)
godbf/table_test.go:359
Function
TestDbfTable_AddTextField
(t *testing.T)
godbf/table_test.go:103
Function
TestDbfTable_DecimalPlacesInField_InvalidField
(t *testing.T)
godbf/table_test.go:210
Function
TestDbfTable_DecimalPlacesInField_NonExistentField
(t *testing.T)
godbf/table_test.go:199
Function
TestDbfTable_DecimalPlacesInField_ValidField
(t *testing.T)
godbf/table_test.go:177
Function
TestDbfTable_FieldDescriptor
(t *testing.T)
godbf/table_test.go:411
Function
TestDbfTable_FieldNames
(t *testing.T)
godbf/table_test.go:161
Function
TestDbfTable_FieldValueByName
(t *testing.T)
godbf/table_test.go:294
Function
TestDbfTable_FieldValueByName_NonExistentField
(t *testing.T)
godbf/table_test.go:334
Function
TestDbfTable_Float64FieldValueByName
(t *testing.T)
godbf/table_test.go:390
Function
TestDbfTable_GetRowAsSlice
(t *testing.T)
godbf/table_test.go:252
Function
TestDbfTable_GetRowAsSlice_InitiallyEmptyStrings
(t *testing.T)
godbf/table_test.go:223
Function
TestDbfTable_Int64FieldValueByName
(t *testing.T)
godbf/table_test.go:369
Function
TestDbfTable_New
For reference: https://en.wikipedia.org/wiki/.dbf#File_format_of_Level_5_DOS_dBASE
godbf/table_test.go:15
Function
TestDbfTable_SetFieldValueByName_NonExistentField
(t *testing.T)
godbf/table_test.go:348
Function
TestFieldsNameCorrectDetect
(t *testing.T)
godbf/io_test.go:180
Function
TestNewFromByteArray_EndOfFieldMarkerMissing_TableParsingError
(t *testing.T)
godbf/io_test.go:102
next →
1–100 of 115, ranked by callers