Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RosterEdit ¶
type RosterEdit struct { // FileName is the name of the file containing the roster information. FileName string // Roster contains the state of the roster at the time of writing the // file. It's what we diff against when reading the file. Roster []data.RosterEntry // isComplete is true if this is the result of reading an edited // roster, rather than a report that the file has been written. IsComplete bool // contents contains the edited roster, if isComplete is true. Contents []byte }
RosterEdit contains information about a pending roster edit. Roster edits occur by writing the roster to a file and inviting the user to edit the file.
type RosterEditor ¶
type RosterEditor struct { Roster []data.RosterEntry // pendingRosterEdit, if non-nil, contains information about a pending // roster edit operation. PendingRosterEdit *RosterEdit // pendingRosterChan is the channel over which roster edit information // is received. PendingRosterChan chan *RosterEdit }
RosterEditor represents an edit of a Roster in progress
func (*RosterEditor) EditRoster ¶
func (s *RosterEditor) EditRoster(roster []data.RosterEntry) error
EditRoster runs in a goroutine and writes the roster to a file that the user can edit.
func (*RosterEditor) LoadEditedRoster ¶
func (s *RosterEditor) LoadEditedRoster(edit RosterEdit) error
LoadEditedRoster loads the edits from the given roster
Source Files ¶
Click to show internal directories.
Click to hide internal directories.