Class JDBCPushRepository

java.lang.Object
tigase.push.repositories.AbstractPushRepository<tigase.db.DataRepository>
tigase.push.repositories.JDBCPushRepository
All Implemented Interfaces:
tigase.db.DataSourceAware<tigase.db.DataRepository>, tigase.db.util.RepositoryVersionAware, IPushRepository<tigase.db.DataRepository>

public class JDBCPushRepository extends AbstractPushRepository<tigase.db.DataRepository> implements tigase.db.util.RepositoryVersionAware
Created by andrzej on 05.01.2017.
  • Field Details

    • repo

      protected tigase.db.DataRepository repo
  • Constructor Details

    • JDBCPushRepository

      public JDBCPushRepository()
  • Method Details

    • registerDevice

      public IPushSettings registerDevice(tigase.xmpp.jid.BareJID serviceJid, tigase.xmpp.jid.BareJID userJid, String provider, String deviceId, String deviceSecondId) throws tigase.component.exceptions.RepositoryException
      Specified by:
      registerDevice in interface IPushRepository<tigase.db.DataRepository>
      Throws:
      tigase.component.exceptions.RepositoryException
    • unregisterDevice

      public IPushSettings unregisterDevice(tigase.xmpp.jid.BareJID serviceJid, tigase.xmpp.jid.BareJID userJid, String provider, String deviceId) throws tigase.component.exceptions.RepositoryException, tigase.component.exceptions.ComponentException
      Specified by:
      unregisterDevice in interface IPushRepository<tigase.db.DataRepository>
      Throws:
      tigase.component.exceptions.RepositoryException
      tigase.component.exceptions.ComponentException
    • unregisterDeviceOld

      public IPushSettings unregisterDeviceOld(tigase.xmpp.jid.BareJID serviceJid, tigase.xmpp.jid.BareJID userJid, String provider, String deviceId) throws tigase.component.exceptions.RepositoryException, tigase.component.exceptions.ComponentException
      Throws:
      tigase.component.exceptions.RepositoryException
      tigase.component.exceptions.ComponentException
    • getNodeSettings

      public IPushSettings getNodeSettings(tigase.xmpp.jid.BareJID serviceJid, String node) throws tigase.component.exceptions.RepositoryException
      Specified by:
      getNodeSettings in interface IPushRepository<tigase.db.DataRepository>
      Throws:
      tigase.component.exceptions.RepositoryException
    • getNodeSettings

      public Stream<IPushSettings> getNodeSettings(String provider, String deviceId) throws tigase.component.exceptions.RepositoryException
      Specified by:
      getNodeSettings in interface IPushRepository<tigase.db.DataRepository>
      Throws:
      tigase.component.exceptions.RepositoryException
    • getStatistics

      public Map<String,IPushRepository.Statistics> getStatistics() throws tigase.component.exceptions.RepositoryException
      Specified by:
      getStatistics in interface IPushRepository<tigase.db.DataRepository>
      Throws:
      tigase.component.exceptions.RepositoryException
    • setDataSource

      public void setDataSource(tigase.db.DataRepository dataSource)
      Specified by:
      setDataSource in interface tigase.db.DataSourceAware<tigase.db.DataRepository>
    • readDevice

      protected IPushSettings.IDevice readDevice(ResultSet rs, int i) throws SQLException
      Throws:
      SQLException
    • initRepo

      protected void initRepo(tigase.db.DataRepository repo) throws SQLException
      Throws:
      SQLException