utils

package
v0.0.0-...-443ed56 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 30, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BsonDArrayToFile

func BsonDArrayToFile(bsonDArray []bson.D, bar *pb.ProgressBar, filename string) error

func BsonDArrayToGzipFile

func BsonDArrayToGzipFile(bsonDArray []bson.D, bar *pb.ProgressBar, filename string) error

func BsonDArrayToJsonFile

func BsonDArrayToJsonFile(bsonDArray []bson.D, bar *pb.ProgressBar, filename string) error

func BsonDToJson

func BsonDToJson(b bson.D) (string, error)

func BsonDToMap

func BsonDToMap(b bson.D) (map[string]interface{}, error)

func Contains

func Contains(collection []string, item string) bool

func GetBarTemplate

func GetBarTemplate(entityType string, entity string) string

func GetBars

func GetBars(arr []string, entityType string, testMode bool) []*pb.ProgressBar

func GetName

func GetName(filename string) string

func InterfaceToSQLInsertRowString

func InterfaceToSQLInsertRowString(itf interface{}) string

func InterfaceToString

func InterfaceToString(itf interface{}) string

func MapArrayToCSVFile

func MapArrayToCSVFile(mp []map[string]interface{}, bar *pb.ProgressBar, filename string) error

func MapArrayToJSONFile

func MapArrayToJSONFile(mp []map[string]interface{}, bar *pb.ProgressBar, filename string) error

func MapArrayToTSVFile

func MapArrayToTSVFile(mp []map[string]interface{}, bar *pb.ProgressBar, filename string) error

func SqlRowToMap

func SqlRowToMap(rows *sql.Rows) ([]map[string]interface{}, error)

func SqlRowToString

func SqlRowToString(rows *sql.Rows) ([]string, error)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL