org.dps.core.model
Class HibernateCachedData

java.lang.Object
  extended by org.dps.core.model.CachedData
      extended by org.dps.core.model.HibernateCachedData
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
CharacterContactNotifications, CharacterIndustryJobs, CharacterKillLog, CharacterMailMessageBodies, CharacterMailMessages, CharacterMarketOrders, CharacterNotifications, CharacterNotificationTexts, CharacterWalletJournal, CharacterWalletTransactions, CorporationContainerLog, CorporationIndustryJobs, CorporationKillLog, CorporationMarketOrders, CorporationMemberSecurityLog, CorporationWalletJournal, CorporationWalletTransactions

public abstract class HibernateCachedData
extends CachedData

Superclass for model objects backed by database storage. Static data for this class must be initialized by the IEveData implementation at startup.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.dps.core.model.CachedData
apiVersion, cachedUntil, currentTime, dataMap, lock
 
Constructor Summary
HibernateCachedData(int keyID)
           
 
Method Summary
 void begin()
           
 void close()
           
 void commit()
           
 org.hibernate.Session getSession()
           
 void rollback()
           
static void setPersistenceFactory(IEvePersistenceFactory f)
           
 ICharacterMailMessageBodyRecord storeEntry(ICharacterMailMessageBodyRecord entry)
          Convenience method for the common action of adding a new entry to the character mail message bodies table.
 ICharacterMailMessageRecord storeEntry(ICharacterMailMessageRecord entry)
          Convenience method for the common action of adding a new entry to the character mail messages table.
 ICharacterNotificationRecord storeEntry(ICharacterNotificationRecord entry)
          Convenience method for the common action of adding a new entry to the character notifications table.
 ICharacterNotificationTextRecord storeEntry(ICharacterNotificationTextRecord entry)
          Convenience method for the common action of adding a new entry to the character notification texts table.
 IKillAttackerRecord storeEntry(IKillAttackerRecord entry)
          Convenience method for the common action of adding a new entry to the kill attacker record table.
 IKillItemRecord storeEntry(IKillItemRecord entry)
          Convenience method for the common action of adding a new entry to the kill item record table.
 IKillRecord storeEntry(IKillRecord entry)
          Convenience method for the common action of adding a new entry to the kill record table.
 IKillVictimRecord storeEntry(IKillVictimRecord entry)
          Convenience method for the common action of adding a new entry to the kill victim record table.
 IWalletJournalRecord storeEntry(IWalletJournalRecord entry)
          Convenience method for the common action of adding a new entry to a the wallet journal table.
 IWalletTransactionRecord storeEntry(IWalletTransactionRecord entry)
          Convenience method for the common action of adding a new entry to a the wallet transactions table.
 java.lang.String toString()
           
 
Methods inherited from class org.dps.core.model.CachedData
expiresIn, getMeta, getMeta, isExpired, putMeta
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HibernateCachedData

public HibernateCachedData(int keyID)
Method Detail

setPersistenceFactory

public static void setPersistenceFactory(IEvePersistenceFactory f)

getSession

public org.hibernate.Session getSession()

begin

public void begin()

commit

public void commit()

rollback

public void rollback()

close

public void close()

storeEntry

public IWalletJournalRecord storeEntry(IWalletJournalRecord entry)
                                throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to a the wallet journal table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet journal table.
Throws:
org.hibernate.HibernateException

storeEntry

public IWalletTransactionRecord storeEntry(IWalletTransactionRecord entry)
                                    throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to a the wallet transactions table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

storeEntry

public ICharacterNotificationRecord storeEntry(ICharacterNotificationRecord entry)
                                        throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to the character notifications table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

storeEntry

public ICharacterNotificationTextRecord storeEntry(ICharacterNotificationTextRecord entry)
                                            throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to the character notification texts table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

storeEntry

public ICharacterMailMessageRecord storeEntry(ICharacterMailMessageRecord entry)
                                       throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to the character mail messages table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

storeEntry

public ICharacterMailMessageBodyRecord storeEntry(ICharacterMailMessageBodyRecord entry)
                                           throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to the character mail message bodies table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

storeEntry

public IKillRecord storeEntry(IKillRecord entry)
                       throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to the kill record table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

storeEntry

public IKillAttackerRecord storeEntry(IKillAttackerRecord entry)
                               throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to the kill attacker record table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

storeEntry

public IKillItemRecord storeEntry(IKillItemRecord entry)
                           throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to the kill item record table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

storeEntry

public IKillVictimRecord storeEntry(IKillVictimRecord entry)
                             throws org.hibernate.HibernateException
Convenience method for the common action of adding a new entry to the kill victim record table. If the specified entry already exists in the table, then the existing row is updated according to the fields of the new entry. Otherwise, the entry is added as a new row to the table. In either case, a persisted version of the entry is returned. The caller should normally replace the entry passed as an argument with the entry returned by the call.

Returns:
the persisted instance which was stored to the wallet transactions table.
Throws:
org.hibernate.HibernateException

toString

public java.lang.String toString()
Overrides:
toString in class CachedData