Class: HistoryBuffer
Defined in: | lib/HistoryBuffer.coffee |
Overview
An object that holds all applied operations.
Instance Method Summary
- # (void) getUserId()
- # (void) getOperationCounter()
- # (void) toJson()
- # (void) getNextOperationIdentifier(user_id) Get the number of operations that were created by a user.
- # (void) getOperation(uid) Retrieve an operation from a unique id.
- # (void) addOperation(o) Add an operation to the HB.
Constructor Details
~
(void)
new HistoryBuffer()
~
(void)
new HistoryBuffer(initial_content)
Instance Method Details
#
(void)
getUserId()
#
(void)
getOperationCounter()
#
(void)
toJson()
#
(void)
getNextOperationIdentifier(user_id)
Get the number of operations that were created by a user. Accordingly you will get the next operation number that is expected from that user. You'll get new results only if you added the operation with $addOperation.
#
(void)
getOperation(uid)
Retrieve an operation from a unique id.
#
(void)
addOperation(o)
Add an operation to the HB. Note that this will not link it against other operations (it wont be executable)