package
Version:
v0.0.0-...-c9cb955
Opens a new window with list of versions in this module.
Published: Jun 21, 2024
License: MIT
Opens a new window with license information.
Imports: 10
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
LoadCSV loads the CSV file into the specified table in the database
SendError sends a JSON error response with the given status code and error message
SendJSON sends a JSON response with the given status code, message, and data
type CsvSource struct {
}
CsvSource implements the pgx.CopyFromSource interface
type JSONResponse struct {
Status string `json:"status"`
Message string `json:"message,omitempty"`
Data interface{} `json:"data,omitempty"`
}
JSONResponse represents the structure of a typical JSON response
Logger represents a logger instance.
NewLogger creates a new logger instance.
Debug logs a debug message.
Error logs an error message.
Fatal logs a fatal error message and exits the program.
Info logs an informational message.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.