database

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2026 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Overview

Package database handles session storage and retrieval using CSV files.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

func Add(databasePath string, sessionData [][]string) error

Add appends new sessions to the database file.

func B64SessionToArray

func B64SessionToArray(base64Session structure.B64Session) []string

B64SessionToArray converts a B64Session to a string array for database storage.

func EnumerateSessions

func EnumerateSessions(sessionList [][]string) []string

EnumerateSessions lists all sessions and returns their IDs.

func GetPath

func GetPath() (string, error)

GetPath returns the path to the sessions database file, creating it if necessary.

func Init

func Init(databasePath string) error

Init initializes the database file, creating headers if empty.

func Read

func Read(databasePath string) ([][]string, error)

Read retrieves all sessions from the database file, excluding headers.

func Write

func Write(databasePath string, sessionData [][]string) error

Write overwrites the database file with the provided content.

Types

This section is empty.

Jump to

Keyboard shortcuts

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