PrivateParlorXT::SQLiteHistory
Inherits PrivateParlorXT::History < Reference < Object
An implementation of History using the SQLite Database for storing message data
Constructors
Initialize a SQLiteHistory where messages older than lifespan are considered expired
Generally this should use the same connection that was used for the database
Instance methods
Adds a rating entry to the database with the given data
Returns true if the user's rating was successfully added; false if the user's rating already exists.
Add a receiver message to the History
Delete a message group from the History
Ensures that there are message_group, receivers, and karma tables in the Database
Get all message IDs sent by a given user for purging messages
Create a new message group and add it to the History
Get the message ID of the original message associated with the given message ID
Get a hash containing an array of message IDs to delete associated with the users who received a message in the given set.
Used for the PurgeCommand
NOTE: The returned array of message IDs should be sorted in descending order (most recent messages first)
Get the original message ID associated with the given message ID and receiver ID
Get a hash of all users and receiver message IDs associated with the given message ID
Get the sender of the original message referenced by the given message ID
Returns true if the given message was already warned; false or nil otherwise