// Code generated by sqlc. DO NOT EDIT. // versions: // sqlc v1.25.0 // source: onion.sql package sqlc import ( "context" "time" ) const deleteOnionPrivateKey = `-- name: DeleteOnionPrivateKey :exec DELETE FROM onion ` func (q *Queries) DeleteOnionPrivateKey(ctx context.Context) error { _, err := q.db.ExecContext(ctx, deleteOnionPrivateKey) return err } const selectOnionPrivateKey = `-- name: SelectOnionPrivateKey :one SELECT private_key FROM onion LIMIT 1 ` func (q *Queries) SelectOnionPrivateKey(ctx context.Context) ([]byte, error) { row := q.db.QueryRowContext(ctx, selectOnionPrivateKey) var private_key []byte err := row.Scan(&private_key) return private_key, err } const upsertOnion = `-- name: UpsertOnion :exec INSERT INTO onion ( private_key, created_at ) VALUES ( $1, $2 ) ON CONFLICT ( private_key ) DO NOTHING ` type UpsertOnionParams struct { PrivateKey []byte CreatedAt time.Time } func (q *Queries) UpsertOnion(ctx context.Context, arg UpsertOnionParams) error { _, err := q.db.ExecContext(ctx, upsertOnion, arg.PrivateKey, arg.CreatedAt) return err }