Documentation
¶
Index ¶
- Constants
- type Manager
- func (m *Manager) OpsSince(padId string, sinceRev int) ([]sheet.Op, error)
- func (m *Manager) SetWorkbook(padId string, wb *sheet.Workbook) error
- func (m *Manager) Snapshot(padId string) (sheet.WorkbookSnapshot, int, error)
- func (m *Manager) Submit(padId string, op sheet.Op, authorId *string, tsMillis int64) (sheet.Op, int, error)
Constants ¶
View Source
const DefaultSheetID = "s1"
DefaultSheetID is the id of the single sheet created for a brand-new workbook.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager owns the in-memory sheet documents and serializes operations per document (total order), persisting each op and a workbook snapshot.
func NewManager ¶
func (*Manager) SetWorkbook ¶
SetWorkbook replaces the document's workbook (e.g. from an xlsx import), resetting it to revision 0 with an empty op-log. Existing persisted ops are cleared so the write-once sheet_op primary key does not block later edits.
Click to show internal directories.
Click to hide internal directories.