Class DisplayerManager


  • public final class DisplayerManager
    extends java.lang.Object
    Read in and provide access to report page displayers. Displayers are constructed based on entries in webconfig-model.xml and cached. On creation config is copied to subclasses.
    Author:
    Richard Smith
    • Field Detail

      • LOG

        protected static final org.apache.log4j.Logger LOG
    • Method Detail

      • getInstance

        public static DisplayerManager getInstance​(WebConfig webConfig,
                                                   InterMineAPI im)
        Fetch the DisplayerManager, a single instance is held.
        Parameters:
        webConfig - web configuration
        im - the InterMine API
        Returns:
        the DisplayerManager
      • getAllReportDisplayersForType

        public java.util.Set<ReportDisplayer> getAllReportDisplayersForType​(java.lang.String type)
        Get all displayers for the given type regardless of placement.
        Parameters:
        type - an unqualified class name to look up
        Returns:
        a set of displayers or an empty set if there are none
      • getReportDisplayersForType

        public java.util.Map<java.lang.String,​java.util.List<ReportDisplayer>> getReportDisplayersForType​(java.lang.String type)
        Get a map from placement string (a data category or summary) to displayers for the given type. Returns null if there are no displayers for the type.
        Parameters:
        type - an unqualified class name
        Returns:
        a map from placement to displayers or null
      • getReportDisplayerByName

        public ReportDisplayer getReportDisplayerByName​(java.lang.String objectType,
                                                        java.lang.String name)
        Get a specific ReportDisplayer by its name for a given ReportObject type
        Parameters:
        objectType - object type (Gene etc)
        name - of the displayer
        Returns:
        Displayer