Class ContributorsListProvider

java.lang.Object
org.opencastproject.list.common.provider.ContributorsListProvider
All Implemented Interfaces:
ResourceListProvider

public class ContributorsListProvider extends Object implements ResourceListProvider
  • Field Details

  • Constructor Details

    • ContributorsListProvider

      public ContributorsListProvider()
  • Method Details

    • activate

      protected void activate(Map<String,Object> properties)
    • modified

      public void modified(Map<String,Object> properties)
    • setUserDirectoryService

      public void setUserDirectoryService(UserDirectoryService userDirectoryService)
      OSGi callback for users services.
    • setIndex

      public void setIndex(ElasticsearchIndex index)
      OSGi callback for the search index.
    • getListNames

      public String[] getListNames()
      Description copied from interface: ResourceListProvider
      Returns the names of the list(s) provided
      Specified by:
      getListNames in interface ResourceListProvider
      Returns:
      an array containing the lists available
    • getList

      public Map<String,String> getList(String listName, ResourceListQuery query)
      Description copied from interface: ResourceListProvider
      Returns the key-value list for the generator resource filtered with the given filter and based on the given organization context.
      Specified by:
      getList in interface ResourceListProvider
      Parameters:
      listName - the list name
      query - the list query
      Returns:
      the key-value list for the generator resource
    • getList

      protected Map<String,String> getList(ResourceListQuery query)
      Get all of the contributors with friendly printable names.
      Parameters:
      query - The query for the list including limit and offset.
      Returns:
      The Map including all of the contributors.
    • getListWithTechnicalPresenters

      protected Map<String,String> getListWithTechnicalPresenters(ResourceListQuery query)
      Get the contributors list including usernames and organizations for the users available.
      Parameters:
      query - The query for the list including limit and offset.
      Returns:
      The Map including all of the contributors.
    • getListWithUserNames

      protected Map<String,String> getListWithUserNames(ResourceListQuery query)
      Get the contributors list including usernames and organizations for the users available.
      Parameters:
      query - The query for the list including limit and offset.
      Returns:
      The Map including all of the contributors.
    • addIndexNamesToMap

      protected void addIndexNamesToMap(Set<String> userLabels, Collection<org.opencastproject.list.common.provider.ContributorsListProvider.Contributor> contributors, List<String> indexNames)
      Add all names in the index to the map if they aren't already present as a user.
      Parameters:
      userLabels - The collection of user labels, the full names of the users.
      contributors - The collection of all contributors including the index names that will be added.
      indexNames - The list of new names from the index.
    • isTranslatable

      public boolean isTranslatable(String listName)
      Description copied from interface: ResourceListProvider
      Defines if keys and values of the given list should be translated in the administrative user interface.
      Specified by:
      isTranslatable in interface ResourceListProvider
      Parameters:
      listName - the name of the list
      Returns:
      if the results should be translated
    • getDefault

      public String getDefault()
      Description copied from interface: ResourceListProvider
      Returns the key of the default value in the list if customized, else null.
      Specified by:
      getDefault in interface ResourceListProvider
      Returns:
      key of default value or null