Documentation
¶
Index ¶
- type DBTX
- type Database
- type GetNoteAccessRow
- type GetNoteRow
- type GetNoteTagsParams
- type GetTagAccessRow
- type GetUserNoteAccessParams
- type GetUserTagAccessParams
- type ListNotesParams
- type ListNotesRow
- type ListTagsParams
- type ListTagsRow
- type NotesAccessLevel
- type NotesTag
- type NotesUser
- type NullNotesAccessLevel
- type Queries
- func (q *Queries) DeleteNote(ctx context.Context, db DBTX, noteID uuid.UUID) (int64, error)
- func (q *Queries) DeleteTag(ctx context.Context, db DBTX, tagID uuid.UUID) (int64, error)
- func (q *Queries) DeleteUser(ctx context.Context, db DBTX, userID uuid.UUID) (int64, error)
- func (q *Queries) GetNote(ctx context.Context, db DBTX, noteID uuid.UUID) (GetNoteRow, error)
- func (q *Queries) GetNoteAccess(ctx context.Context, db DBTX, noteID uuid.UUID) ([]GetNoteAccessRow, error)
- func (q *Queries) GetNoteTags(ctx context.Context, db DBTX, arg GetNoteTagsParams) ([]NotesTag, error)
- func (q *Queries) GetTag(ctx context.Context, db DBTX, tagID uuid.UUID) (NotesTag, error)
- func (q *Queries) GetTagAccess(ctx context.Context, db DBTX, tagID uuid.UUID) ([]GetTagAccessRow, error)
- func (q *Queries) GetUser(ctx context.Context, db DBTX, noteID uuid.UUID) (NotesUser, error)
- func (q *Queries) GetUserNoteAccess(ctx context.Context, db DBTX, arg GetUserNoteAccessParams) (NotesAccessLevel, error)
- func (q *Queries) GetUserTagAccess(ctx context.Context, db DBTX, arg GetUserTagAccessParams) (NotesAccessLevel, error)
- func (q *Queries) ListNotes(ctx context.Context, db DBTX, arg ListNotesParams) ([]ListNotesRow, error)
- func (q *Queries) ListTags(ctx context.Context, db DBTX, arg ListTagsParams) ([]ListTagsRow, error)
- func (q *Queries) SaveNote(ctx context.Context, db DBTX, arg SaveNoteParams) error
- func (q *Queries) SaveTag(ctx context.Context, db DBTX, arg SaveTagParams) error
- func (q *Queries) SaveUser(ctx context.Context, db DBTX, arg SaveUserParams) error
- func (q *Queries) SearchNotesWithTag(ctx context.Context, db DBTX, arg SearchNotesWithTagParams) ([]SearchNotesWithTagRow, error)
- func (q *Queries) SearchNotesWithText(ctx context.Context, db DBTX, arg SearchNotesWithTextParams) ([]SearchNotesWithTextRow, error)
- func (q *Queries) SearchNotesWithTextAndTag(ctx context.Context, db DBTX, arg SearchNotesWithTextAndTagParams) ([]SearchNotesWithTextAndTagRow, error)
- func (q *Queries) SetNoteAccess(ctx context.Context, db DBTX, arg SetNoteAccessParams) error
- func (q *Queries) SetNoteTags(ctx context.Context, db DBTX, arg SetNoteTagsParams) error
- func (q *Queries) SetTagAccess(ctx context.Context, db DBTX, arg SetTagAccessParams) error
- type SaveNoteParams
- type SaveTagParams
- type SaveUserParams
- type SearchNotesWithTagParams
- type SearchNotesWithTagRow
- type SearchNotesWithTextAndTagParams
- type SearchNotesWithTextAndTagRow
- type SearchNotesWithTextParams
- type SearchNotesWithTextRow
- type SetNoteAccessParams
- type SetNoteTagsParams
- type SetTagAccessParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GetNoteAccessRow ¶
type GetNoteAccessRow struct {
UserID uuid.UUID
Access NotesAccessLevel
}
type GetNoteRow ¶
type GetTagAccessRow ¶
type GetTagAccessRow struct {
UserID uuid.UUID
Access NotesAccessLevel
}
type GetUserNoteAccessParams ¶
type GetUserTagAccessParams ¶
type ListNotesParams ¶
type ListNotesRow ¶
type ListTagsParams ¶
type ListTagsRow ¶
type ListTagsRow struct {
TagID uuid.UUID
Name string
Access NotesAccessLevel
}
type NotesAccessLevel ¶
type NotesAccessLevel string
const ( NotesAccessLevelOwner NotesAccessLevel = "owner" NotesAccessLevelEditor NotesAccessLevel = "editor" NotesAccessLevelViewer NotesAccessLevel = "viewer" )
func (*NotesAccessLevel) Scan ¶
func (e *NotesAccessLevel) Scan(src interface{}) error
func (NotesAccessLevel) Valid ¶
func (e NotesAccessLevel) Valid() bool
type NotesUser ¶
type NotesUser struct {
UserID uuid.UUID
Name string
CreatedAt pgtype.Timestamptz
LastSignIn pgtype.Timestamptz
Active bool
}
type NullNotesAccessLevel ¶
type NullNotesAccessLevel struct {
NotesAccessLevel NotesAccessLevel
Valid bool // Valid is true if NotesAccessLevel is not NULL
}
func (*NullNotesAccessLevel) Scan ¶
func (ns *NullNotesAccessLevel) Scan(value interface{}) error
Scan implements the Scanner interface.
type Queries ¶
type Queries struct {
}
func (*Queries) DeleteNote ¶
func (*Queries) DeleteUser ¶
func (*Queries) GetNoteAccess ¶
func (*Queries) GetNoteTags ¶
func (*Queries) GetTagAccess ¶
func (*Queries) GetUserNoteAccess ¶
func (q *Queries) GetUserNoteAccess(ctx context.Context, db DBTX, arg GetUserNoteAccessParams) (NotesAccessLevel, error)
func (*Queries) GetUserTagAccess ¶
func (q *Queries) GetUserTagAccess(ctx context.Context, db DBTX, arg GetUserTagAccessParams) (NotesAccessLevel, error)
func (*Queries) ListNotes ¶
func (q *Queries) ListNotes(ctx context.Context, db DBTX, arg ListNotesParams) ([]ListNotesRow, error)
func (*Queries) ListTags ¶
func (q *Queries) ListTags(ctx context.Context, db DBTX, arg ListTagsParams) ([]ListTagsRow, error)
func (*Queries) SearchNotesWithTag ¶
func (q *Queries) SearchNotesWithTag(ctx context.Context, db DBTX, arg SearchNotesWithTagParams) ([]SearchNotesWithTagRow, error)
func (*Queries) SearchNotesWithText ¶
func (q *Queries) SearchNotesWithText(ctx context.Context, db DBTX, arg SearchNotesWithTextParams) ([]SearchNotesWithTextRow, error)
func (*Queries) SearchNotesWithTextAndTag ¶
func (q *Queries) SearchNotesWithTextAndTag(ctx context.Context, db DBTX, arg SearchNotesWithTextAndTagParams) ([]SearchNotesWithTextAndTagRow, error)
func (*Queries) SetNoteAccess ¶
func (*Queries) SetNoteTags ¶
func (*Queries) SetTagAccess ¶
type SaveNoteParams ¶
type SaveTagParams ¶
type SaveUserParams ¶
type SaveUserParams struct {
UserID uuid.UUID
Name string
CreatedAt pgtype.Timestamptz
LastSignIn pgtype.Timestamptz
Active bool
}
type SearchNotesWithTagRow ¶
type SearchNotesWithTextRow ¶
type SetNoteAccessParams ¶
type SetNoteAccessParams struct {
Column1 uuid.NullUUID
Column2 NullNotesAccessLevel
Column3 uuid.NullUUID
}
type SetNoteTagsParams ¶
type SetTagAccessParams ¶
type SetTagAccessParams struct {
Column1 uuid.NullUUID
Column2 NullNotesAccessLevel
Column3 uuid.NullUUID
}
Click to show internal directories.
Click to hide internal directories.