Documentation ¶
Index ¶
- type Model
- func (m *Model) FirstItem() int
- func (m *Model) GetCurrItem() int
- func (m *Model) LastItem() int
- func (m *Model) NextItem() int
- func (m *Model) PrevItem() int
- func (m *Model) ResetCurrItem()
- func (m *Model) SetDimensions(dimensions constants.Dimensions)
- func (m *Model) SetNumItems(numItems int)
- func (m *Model) SetTotalItems(total int)
- func (m *Model) SyncViewPort(content string)
- func (m *Model) UpdateProgramContext(ctx *context.ProgramContext)
- func (m *Model) View() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Model ¶
type Model struct { ListItemHeight int NumCurrentItems int NumTotalItems int LastUpdated time.Time ItemTypeLabel string // contains filtered or unexported fields }
func NewModel ¶
func NewModel( ctx context.ProgramContext, dimensions constants.Dimensions, lastUpdated time.Time, itemTypeLabel string, numItems, listItemHeight int, ) Model
func (*Model) GetCurrItem ¶
func (*Model) ResetCurrItem ¶
func (m *Model) ResetCurrItem()
func (*Model) SetDimensions ¶
func (m *Model) SetDimensions(dimensions constants.Dimensions)
func (*Model) SetNumItems ¶
func (*Model) SetTotalItems ¶
func (*Model) SyncViewPort ¶
func (*Model) UpdateProgramContext ¶
func (m *Model) UpdateProgramContext(ctx *context.ProgramContext)
Click to show internal directories.
Click to hide internal directories.