data

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2023 License: MIT Imports: 2 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Quote

type Quote struct {
	// ID is the unique identifier of the quote.
	ID string `json:"id"`
	//	AuthorID is the unique identifier of the author.
	AuthorID string `json:"authorId"`
	//	Text of the quote.
	Text string `json:"text"`
	// Timestamp is the timestamp when the quote was added.
	Timestamp int64 `json:"timestamp"`
}

Quote represents a quote.

type QuoteBuilder

type QuoteBuilder interface {
	WithId(id string) QuoteBuilder
	WithAuthorId(authorId string) QuoteBuilder
	WithText(text string) QuoteBuilder
	WithTimestamp(timestamp int64) QuoteBuilder
	Build() Quote
}

QuoteBuilder is the interface that builds a quote.

func NewQuoteBuilder

func NewQuoteBuilder() QuoteBuilder

NewQuoteBuilder creates a new quote builder.

Jump to

Keyboard shortcuts

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