Class CallDAO

  • All Implemented Interfaces:
    org.exoplatform.commons.api.persistence.GenericDAO<CallEntity,​String>

    public class CallDAO
    extends org.exoplatform.commons.persistence.impl.GenericDAOJPAImpl<CallEntity,​String>
    Created by The eXo Platform SAS.
    Version:
    $Id: CallDAO.java 00000 Dec 22, 2017 pnedonosko $
    Author:
    Peter Nedonosko
    • Field Detail

      • USER_CALL_DAYS_LIVETIME

        public static final int USER_CALL_DAYS_LIVETIME
        The Constant USER_CALL_DAYS_LIVETIME.
        See Also:
        Constant Field Values
    • Constructor Detail

      • CallDAO

        public CallDAO()
        Instantiates a new call DAO.
    • Method Detail

      • findGroupCallByOwnerTypeId

        public CallEntity findGroupCallByOwnerTypeId​(String ownerId,
                                                     String ownerType)
                                              throws javax.persistence.PersistenceException,
                                                     IllegalStateException,
                                                     IllegalArgumentException
        Find group call by owner type and id.
        Parameters:
        ownerId - the owner id
        ownerType - the owner type
        Returns:
        the list with call entities or empty list if nothing found
        Throws:
        javax.persistence.PersistenceException - the persistence exception
        IllegalStateException - the illegal state exception
        IllegalArgumentException - the illegal argument exception
      • findGroupCallsByState

        public List<CallEntity> findGroupCallsByState​(String state)
        Find all group calls by specific state
        Parameters:
        state -
        Returns:
        list of group calls, or empty list if no matched result
      • updateStartedCallState

        public int updateStartedCallState​(String state)
        Update Call state
        Parameters:
        state -
        Returns:
        Number of updated calls
      • clear

        public void clear()
        Clear the storage.