Interface LiveDataEntriesResource


  • public interface LiveDataEntriesResource
    Provides the list of entries from an existing LiveDataSource.
    Since:
    12.10
    Version:
    $Id: bc13a295c7511c0d74c143022a061277e9de0cb4 $
    • Method Detail

      • getEntries

        Entries getEntries​(String sourceId,
                           String namespace,
                           List<String> properties,
                           List<String> matchAll,
                           List<String> sort,
                           List<Boolean> descending,
                           long offset,
                           int limit)
                    throws Exception
        Provides the list of live data entries. Here's an example URL:
        
         /liveData/sources/liveTable/entries?
         
           namespace=wiki%3Axwiki&
         
           sourceParams.className=Help.Applications.Movies.Code.MoviesClass&
           sourceParams.translationPrefix=movies.livetable.&
         
           properties=doc.title&
           properties=genre&
           properties=releaseDate&
           properties=director&
           properties=_actions&
         
           filters.doc.title=contains%3Amee&
           matchAll=doc.title&
         
           sort=releaseDate&
           descending=false&
         
           offset=0&
           limit=10
         
        Parameters:
        sourceId - indicates the LiveDataSource component implementation
        namespace - the component manager name-space where to look for LiveDataSource implementations; if not specified then the context / current name-space is used
        properties - the list of properties to include in the returned live data entries
        matchAll - the list of properties for which to match all filter constraints
        sort - the list of properties to sort on
        descending - indicates the sort direction for the properties specified by the sort parameter
        offset - the index of the first entry to return
        limit - the maximum number of entries to return
        Returns:
        the list of live data entries that match the query
        Throws:
        Exception - if retrieving the live data entries fails
      • addEntry

        javax.ws.rs.core.Response addEntry​(String sourceId,
                                           String namespace,
                                           Entry entry)
                                    throws Exception
        Adds the given entry to the specified live data source.
        Parameters:
        sourceId - indicates the LiveDataSource component implementation
        namespace - the component manager name-space where to look for LiveDataSource implementations; if not specified then the context / current name-space is used
        entry - the entry to add
        Returns:
        the response
        Throws:
        Exception - if adding the entry fails