Interface EventQuery

All Known Implementing Classes:
JpaEventQuery

public interface EventQuery
Author:
Stian Thorgersen
  • Method Details

    • type

      EventQuery type(EventType... types)
      Search events with given types
      Parameters:
      types - requested types
      Returns:
      this object for method chaining
    • realm

      EventQuery realm(String realmId)
      Search events within realm
      Parameters:
      realmId - id of realm
      Returns:
      this object for method chaining
    • client

      EventQuery client(String clientId)
      Search events for only one client
      Parameters:
      clientId - id of client
      Returns:
      this object for method chaining
    • user

      EventQuery user(String userId)
      Search events for only one user
      Parameters:
      userId - id of user
      Returns:
      this object for method chaining
    • fromDate

      EventQuery fromDate(Date fromDate)
      Search events that are newer than fromDate
      Parameters:
      fromDate - date
      Returns:
      this object for method chaining
    • toDate

      EventQuery toDate(Date toDate)
      Search events that are older than toDate
      Parameters:
      toDate - date
      Returns:
      this object for method chaining
    • ipAddress

      EventQuery ipAddress(String ipAddress)
      Search events from ipAddress
      Parameters:
      ipAddress - ip
      Returns:
      this object for method chaining
    • firstResult

      EventQuery firstResult(int firstResult)
      Index of the first result to return.
      Parameters:
      firstResult - the index. Ignored if negative.
      Returns:
      this object for method chaining
    • maxResults

      EventQuery maxResults(int max)
      Maximum number of results to return.
      Parameters:
      max - a number. Ignored if negative.
      Returns:
      this object for method chaining
    • orderByDescTime

      EventQuery orderByDescTime()
      Order the result by descending time
      Returns:
      this for method chaining
    • orderByAscTime

      EventQuery orderByAscTime()
      Order the result by ascending time
      Returns:
      this for method chaining
    • getResultStream

      Stream<Event> getResultStream()
      Returns requested results that match given criteria as a stream.
      Returns:
      Stream of events. Never returns null.