Help us shape the future of Go! Take the 2026 Go Developer Survey

write

package
v0.1.58 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const WriterDatlyResourceNamespace = "agui_thread_write_writer"

DatlyResourceNamespace identifies this package's generated resource filesystem.

Variables

View Source
var LifecycleDatly = LifecycleDatlyType()
View Source
var WriterDatly = new(WriterComponent)

The public value supports explicit component wiring.

View Source
var WriterDatlyResources embed.FS

Functions

func LifecycleDatlyType

func LifecycleDatlyType() reflect.Type

func WriterDatlyType

func WriterDatlyType() reflect.Type

WriterDatlyType returns the public component type.

func WriterHandlerCurrentWriterIndexByCreatedByUserIdKey

func WriterHandlerCurrentWriterIndexByCreatedByUserIdKey(value *CurrentWriterView) (string, bool)

func WriterHandlerCurrentWriterIndexByIdKey

func WriterHandlerCurrentWriterIndexByIdKey(value *CurrentWriterView) (string, bool)

func WriterHandlerCurrentWriterIndexByPrincipalKey

func WriterHandlerCurrentWriterIndexByPrincipalKey(value *CurrentWriterView) (string, bool)

func WriterHandlerCurrentWriterIndexByProtocolOnlyKey

func WriterHandlerCurrentWriterIndexByProtocolOnlyKey(value *CurrentWriterView) (bool, bool)

func WriterHandlerCurrentWriterIndexByRevisionKey

func WriterHandlerCurrentWriterIndexByRevisionKey(value *CurrentWriterView) (int64, bool)

func WriterHandlerCurrentWriterIndexByThreadIdKey

func WriterHandlerCurrentWriterIndexByThreadIdKey(value *CurrentWriterView) (string, bool)

func WriterHandlerCurrentWriterIndexByThreadKeyKey

func WriterHandlerCurrentWriterIndexByThreadKeyKey(value *CurrentWriterView) (string, bool)

Types

type CurrentWriterView

type CurrentWriterView struct {
	Id              *string `sqlx:"id,primaryKey=true,required=true" json:"id,omitempty"`
	Revision        int64   `sqlx:"protocol_revision,required=true" json:"revision,omitempty"`
	ThreadId        *string `sqlx:"protocol_thread_id" json:"threadId,omitempty"`
	Principal       *string `sqlx:"protocol_principal" json:"principal,omitempty"`
	StateJson       []byte  `sqlx:"protocol_state_json" json:"stateJson,omitempty"`
	MessagesJson    []byte  `sqlx:"protocol_messages_json" json:"messagesJson,omitempty"`
	ProtocolOnly    bool    `sqlx:"protocol_only,required=true" json:"protocolOnly,omitempty"`
	ThreadKey       *string `sqlx:"protocol_thread_key" json:"threadKey,omitempty"`
	CreatedByUserId *string `sqlx:"created_by_user_id" json:"createdByUserId,omitempty"`
}

CurrentWriterView is generated canonical view metadata for writer.

type Input

type Input struct {
	Principal       string               `` /* 133-byte string literal not displayed */
	Mode            string               `parameter:"Mode,kind=query,in=mode,dataType=string,required=true"`
	DesiredRevision int64                `parameter:"DesiredRevision,kind=query,in=desiredRevision,dataType=int64,required=false"`
	Rows            []*Thread            `` /* 190-byte string literal not displayed */
	WriterKeys      []WriterKeysRow      `` /* 126-byte string literal not displayed */
	CurrentWriter   []*CurrentWriterView `` /* 167-byte string literal not displayed */

	Has *InputHas `setMarker:"true" typeName:"InputHas" json:"-" sqlx:"-"`
	// contains filtered or unexported fields
}

Input is the generated input scaffold for writer.

func (*Input) PrepareReadIndexes

func (input *Input) PrepareReadIndexes(ctx context.Context) error

func (*Input) ReadIndexes

func (input *Input) ReadIndexes(ctx context.Context) (*WriterHandlerReadIndexes, error)

func (*Input) SetCurrentWriter

func (input *Input) SetCurrentWriter(value []*CurrentWriterView)

func (*Input) SetDesiredRevision

func (input *Input) SetDesiredRevision(value int64)

func (*Input) SetMode

func (input *Input) SetMode(value string)

func (*Input) SetPrincipal

func (input *Input) SetPrincipal(value string)

func (*Input) SetRows

func (input *Input) SetRows(value []*Thread)

func (*Input) SetWriterKeys

func (input *Input) SetWriterKeys(value []WriterKeysRow)

type InputHas

type InputHas struct {
	Principal       bool
	Mode            bool
	DesiredRevision bool
	Rows            bool
	WriterKeys      bool
	CurrentWriter   bool
}

type Lifecycle

type Lifecycle struct {
	Input *Input `bind:"kind=input"`
}

func (*Lifecycle) Finalize

func (*Lifecycle) Init

type Output

type Output struct {
	Data []*Thread `parameter:"Data,kind=output,in=body,dataType=[]*Thread" json:"data"`
}

Output is the generated output scaffold for writer.

type Thread

type Thread struct {
	Id              *string    `sqlx:"id,primaryKey=true,required=true" json:"id,omitempty"`
	Revision        int64      `sqlx:"protocol_revision,required=true" writer:"concurrency" json:"revision,omitempty"`
	ThreadId        *string    `sqlx:"protocol_thread_id" json:"threadId,omitempty"`
	Principal       *string    `sqlx:"protocol_principal" json:"principal,omitempty"`
	StateJson       []byte     `sqlx:"protocol_state_json" json:"stateJson,omitempty"`
	MessagesJson    []byte     `sqlx:"protocol_messages_json" json:"messagesJson,omitempty"`
	ProtocolOnly    bool       `sqlx:"protocol_only,required=true" json:"protocolOnly,omitempty"`
	ThreadKey       *string    `sqlx:"protocol_thread_key" json:"threadKey,omitempty"`
	CreatedByUserId *string    `sqlx:"created_by_user_id" json:"createdByUserId,omitempty"`
	Has             *ThreadHas `setMarker:"true" format:"-" sqlx:"-" diff:"-" json:"-" typeName:"ThreadHas"`
}

Thread is generated canonical view metadata for writer.

func (*Thread) GetCreatedByUserId

func (entity *Thread) GetCreatedByUserId() *string

func (*Thread) GetId

func (entity *Thread) GetId() *string

func (*Thread) GetMessagesJson

func (entity *Thread) GetMessagesJson() []byte

func (*Thread) GetPrincipal

func (entity *Thread) GetPrincipal() *string

func (*Thread) GetProtocolOnly

func (entity *Thread) GetProtocolOnly() bool

func (*Thread) GetRevision

func (entity *Thread) GetRevision() int64

func (*Thread) GetStateJson

func (entity *Thread) GetStateJson() []byte

func (*Thread) GetThreadId

func (entity *Thread) GetThreadId() *string

func (*Thread) GetThreadKey

func (entity *Thread) GetThreadKey() *string

func (*Thread) SetCreatedByUserId

func (entity *Thread) SetCreatedByUserId(value *string)

func (*Thread) SetId

func (entity *Thread) SetId(value *string)

func (*Thread) SetMessagesJson

func (entity *Thread) SetMessagesJson(value []byte)

func (*Thread) SetPrincipal

func (entity *Thread) SetPrincipal(value *string)

func (*Thread) SetProtocolOnly

func (entity *Thread) SetProtocolOnly(value bool)

func (*Thread) SetRevision

func (entity *Thread) SetRevision(value int64)

func (*Thread) SetStateJson

func (entity *Thread) SetStateJson(value []byte)

func (*Thread) SetThreadId

func (entity *Thread) SetThreadId(value *string)

func (*Thread) SetThreadKey

func (entity *Thread) SetThreadKey(value *string)

type ThreadHas

type ThreadHas struct {
	Id              bool
	Revision        bool
	ThreadId        bool
	Principal       bool
	StateJson       bool
	MessagesJson    bool
	ProtocolOnly    bool
	ThreadKey       bool
	CreatedByUserId bool
}

type WriterComponent

type WriterComponent struct {
	Contract xdatly.Component[Input, Output] "" /* 174-byte string literal not displayed */
}

Component is the generated component scaffold for writer.

func (WriterComponent) EmbedFS

func (WriterComponent) EmbedFS() *embed.FS

func (WriterComponent) EmbedNamespace

func (WriterComponent) EmbedNamespace() string

type WriterHandlerCurrentWriterGroupedByCreatedByUserId

type WriterHandlerCurrentWriterGroupedByCreatedByUserId map[string][]*CurrentWriterView

func (WriterHandlerCurrentWriterGroupedByCreatedByUserId) Has

type WriterHandlerCurrentWriterGroupedById

type WriterHandlerCurrentWriterGroupedById map[string][]*CurrentWriterView

func (WriterHandlerCurrentWriterGroupedById) Has

type WriterHandlerCurrentWriterGroupedByPrincipal

type WriterHandlerCurrentWriterGroupedByPrincipal map[string][]*CurrentWriterView

func (WriterHandlerCurrentWriterGroupedByPrincipal) Has

type WriterHandlerCurrentWriterGroupedByProtocolOnly

type WriterHandlerCurrentWriterGroupedByProtocolOnly map[bool][]*CurrentWriterView

func (WriterHandlerCurrentWriterGroupedByProtocolOnly) Has

type WriterHandlerCurrentWriterGroupedByRevision

type WriterHandlerCurrentWriterGroupedByRevision map[int64][]*CurrentWriterView

func (WriterHandlerCurrentWriterGroupedByRevision) Has

type WriterHandlerCurrentWriterGroupedByThreadId

type WriterHandlerCurrentWriterGroupedByThreadId map[string][]*CurrentWriterView

func (WriterHandlerCurrentWriterGroupedByThreadId) Has

type WriterHandlerCurrentWriterGroupedByThreadKey

type WriterHandlerCurrentWriterGroupedByThreadKey map[string][]*CurrentWriterView

func (WriterHandlerCurrentWriterGroupedByThreadKey) Has

type WriterHandlerCurrentWriterIndexedByCreatedByUserId

type WriterHandlerCurrentWriterIndexedByCreatedByUserId map[string]*CurrentWriterView

func (WriterHandlerCurrentWriterIndexedByCreatedByUserId) Has

type WriterHandlerCurrentWriterIndexedById

type WriterHandlerCurrentWriterIndexedById map[string]*CurrentWriterView

func (WriterHandlerCurrentWriterIndexedById) Has

type WriterHandlerCurrentWriterIndexedByPrincipal

type WriterHandlerCurrentWriterIndexedByPrincipal map[string]*CurrentWriterView

func (WriterHandlerCurrentWriterIndexedByPrincipal) Has

type WriterHandlerCurrentWriterIndexedByProtocolOnly

type WriterHandlerCurrentWriterIndexedByProtocolOnly map[bool]*CurrentWriterView

func (WriterHandlerCurrentWriterIndexedByProtocolOnly) Has

type WriterHandlerCurrentWriterIndexedByRevision

type WriterHandlerCurrentWriterIndexedByRevision map[int64]*CurrentWriterView

func (WriterHandlerCurrentWriterIndexedByRevision) Has

type WriterHandlerCurrentWriterIndexedByThreadId

type WriterHandlerCurrentWriterIndexedByThreadId map[string]*CurrentWriterView

func (WriterHandlerCurrentWriterIndexedByThreadId) Has

type WriterHandlerCurrentWriterIndexedByThreadKey

type WriterHandlerCurrentWriterIndexedByThreadKey map[string]*CurrentWriterView

func (WriterHandlerCurrentWriterIndexedByThreadKey) Has

type WriterHandlerCurrentWriterSlice

type WriterHandlerCurrentWriterSlice []*CurrentWriterView

func (WriterHandlerCurrentWriterSlice) GroupByCreatedByUserId

func (WriterHandlerCurrentWriterSlice) GroupById

func (WriterHandlerCurrentWriterSlice) GroupByPrincipal

func (WriterHandlerCurrentWriterSlice) GroupByProtocolOnly

func (WriterHandlerCurrentWriterSlice) GroupByRevision

func (WriterHandlerCurrentWriterSlice) GroupByThreadId

func (WriterHandlerCurrentWriterSlice) GroupByThreadKey

func (WriterHandlerCurrentWriterSlice) IndexByCreatedByUserId

func (WriterHandlerCurrentWriterSlice) IndexById

func (WriterHandlerCurrentWriterSlice) IndexByPrincipal

func (WriterHandlerCurrentWriterSlice) IndexByProtocolOnly

func (WriterHandlerCurrentWriterSlice) IndexByRevision

func (WriterHandlerCurrentWriterSlice) IndexByThreadId

func (WriterHandlerCurrentWriterSlice) IndexByThreadKey

type WriterHandlerReadIndexes

type WriterHandlerReadIndexes struct {
	CurrentWriter     WriterHandlerCurrentWriterSlice
	CurrentWriterById WriterHandlerCurrentWriterIndexedById
}

func BuildWriterHandlerReadIndexes

func BuildWriterHandlerReadIndexes(ctx context.Context, input *Input) (*WriterHandlerReadIndexes, error)

type WriterKeysRow

type WriterKeysRow struct {
	Id *string `sqlx:"id"`
}

Jump to

Keyboard shortcuts

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