Class View

  • All Implemented Interfaces:
    java.io.Serializable

    public class View
    extends java.lang.Object
    implements java.io.Serializable
    View definition
    See Also:
    Serialized Form
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      class  View.Item  
    • Constructor Summary

      Constructors 
      Constructor Description
      View()
      Generated view without id
      View​(View view)
      Copy constructor
      View​(java.lang.String id)
      Constructor
    • Method Summary

      Modifier and Type Method Description
      void addGroup​(java.lang.String group)
      Set the groups to activate (home page only)
      View.Item addItem​(java.lang.String id, int pos, char type, java.lang.String content, java.util.Map<java.lang.String,​java.lang.String> params, java.lang.String searchSpec, boolean title, java.util.HashMap<java.lang.String,​java.lang.String> display)
      Add one item to the view
      void collapse​(ObjectDB obj)  
      void extend​(ObjectDB obj)  
      java.lang.String getDisplay​(java.lang.String lang)
      Name to display
      java.lang.String getDisposition()
      Get the disposition to activate when this home page is selected
      java.lang.String getFaviconURL​(int size)
      Theme favicon URL
      java.lang.String getFont()
      Get the font name
      java.util.List<java.lang.String> getGroups()
      Get the groups to activate when this home page is selected
      DocumentDB getHeaderLogo()
      Logo for header usage (horizontal)
      java.lang.String getHelp​(java.lang.String lang)
      Help to display (HTML content)
      java.lang.String getIcon()
      Get the icon code
      java.lang.String getIcon​(Grant g, java.lang.String defaultIcon, java.lang.String size, java.lang.String cls)
      Get the icon as i, span or img
      java.lang.String getIconSet()
      Get the icon set name
      java.lang.String getIconURL​(Grant g, java.lang.String defaultIcon)
      Get the icon URL
      java.lang.String getId()
      View id (or null in case of generated view of link)
      View.Item getItem​(int i)
      Get one item at index
      View.Item getItemAtPos​(int pos)
      Get one item at position
      java.util.List<View.Item> getItems()
      Get all items
      DocumentDB getLogo()
      Theme logo for scope usage (plain or large)
      java.lang.String getLogo​(boolean header)
      Logo inlined source in base64
      java.lang.String getName()
      View name
      int getOrder()
      Order in link panels
      java.lang.String getReference()
      Get the reference field name when view contains a link
      java.lang.String getScope()
      Get the view scope
      DocumentDB getStyles()
      Styles from theme
      java.lang.String getTarget()
      Get the view name or the object name when view contains a link
      java.lang.String getTemplate()
      Template HTML
      java.lang.String getTheme()
      Get the theme name
      java.lang.String getUITemplate()
      UI Template for front usage
      static java.lang.String getViewId​(java.lang.String name)
      Get View row Id from name
      boolean isCollapsed()
      Is the object view collapsed ?
      boolean isExtended()
      Is the object view extended ?
      boolean isFormEmbedded()
      Is embedded in object form ?
      boolean isVisible()
      Is the view visible ?
      void setCollapsed​(ObjectDB obj, boolean collapse)
      Change the collapse flag of the object view
      void setDisplay​(java.lang.String lang, java.lang.String disp, java.lang.String help)  
      void setDisplay​(java.util.HashMap<java.lang.String,​java.lang.String> h)  
      void setDisposition​(java.lang.String disp)
      Set the home page disposition (home page only)
      void setFavicon​(java.lang.String docId)  
      void setFaviconURL​(int size, java.lang.String url)  
      void setFont​(java.lang.String name)
      Set the font
      void setFormEmbedded​(boolean b)
      Set embedded in object form ?
      void setHeaderLogo​(java.lang.String docId)  
      void setHelp​(java.util.HashMap<java.lang.String,​java.lang.String> h)  
      void setIcon​(java.lang.String icon)
      Set the icon code
      void setIconSet​(java.lang.String name)
      Set the icon set
      void setLogo​(java.lang.String docId)  
      void setName​(java.lang.String d)  
      void setOrder​(int i)  
      void setScope​(java.lang.String scope)
      Set the view scope
      void setStyles​(java.lang.String docId)  
      void setTemplate​(java.lang.String t)  
      void setTheme​(java.lang.String name)
      Set the theme
      void setUITemplate​(java.lang.String t)  
      void setVisible​(boolean vis)  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • View

        public View()
        Generated view without id
      • View

        public View​(java.lang.String id)
        Constructor
        Parameters:
        id - View id or null if generated
      • View

        public View​(View view)
        Copy constructor
        Parameters:
        view - View to copy
    • Method Detail

      • getId

        public java.lang.String getId()
        View id (or null in case of generated view of link)
      • getViewId

        public static java.lang.String getViewId​(java.lang.String name)
        Get View row Id from name
        Parameters:
        name - Name
        Returns:
        Row Id
      • getName

        public java.lang.String getName()
        View name
      • setName

        public void setName​(java.lang.String d)
      • getTarget

        public java.lang.String getTarget()
        Get the view name or the object name when view contains a link
      • getReference

        public java.lang.String getReference()
        Get the reference field name when view contains a link
      • getDisplay

        public java.lang.String getDisplay​(java.lang.String lang)
        Name to display
      • setDisplay

        public void setDisplay​(java.util.HashMap<java.lang.String,​java.lang.String> h)
      • getHelp

        public java.lang.String getHelp​(java.lang.String lang)
        Help to display (HTML content)
      • setHelp

        public void setHelp​(java.util.HashMap<java.lang.String,​java.lang.String> h)
      • setDisplay

        public void setDisplay​(java.lang.String lang,
                               java.lang.String disp,
                               java.lang.String help)
      • getOrder

        public int getOrder()
        Order in link panels
      • setOrder

        public void setOrder​(int i)
      • getTemplate

        public java.lang.String getTemplate()
        Template HTML
      • setTemplate

        public void setTemplate​(java.lang.String t)
      • getUITemplate

        public java.lang.String getUITemplate()
        UI Template for front usage
      • setUITemplate

        public void setUITemplate​(java.lang.String t)
      • getHeaderLogo

        public DocumentDB getHeaderLogo()
        Logo for header usage (horizontal)
      • setHeaderLogo

        public void setHeaderLogo​(java.lang.String docId)
      • getLogo

        public DocumentDB getLogo()
        Theme logo for scope usage (plain or large)
      • setLogo

        public void setLogo​(java.lang.String docId)
      • getLogo

        public java.lang.String getLogo​(boolean header)
        Logo inlined source in base64
        Parameters:
        header - get the small logo for header?
      • getStyles

        public DocumentDB getStyles()
        Styles from theme
      • setStyles

        public void setStyles​(java.lang.String docId)
      • addItem

        public View.Item addItem​(java.lang.String id,
                                 int pos,
                                 char type,
                                 java.lang.String content,
                                 java.util.Map<java.lang.String,​java.lang.String> params,
                                 java.lang.String searchSpec,
                                 boolean title,
                                 java.util.HashMap<java.lang.String,​java.lang.String> display)
        Add one item to the view
        Parameters:
        id - Item ID
        pos - Item position
        type - Item type
        content - Content
        searchSpec - Search spec
        title - True to display the title
        display - Item translations
      • getItem

        public View.Item getItem​(int i)
        Get one item at index
      • getItemAtPos

        public View.Item getItemAtPos​(int pos)
        Get one item at position
      • getItems

        public java.util.List<View.Item> getItems()
        Get all items
      • isVisible

        public boolean isVisible()
        Is the view visible ?
      • setVisible

        public void setVisible​(boolean vis)
      • isCollapsed

        public boolean isCollapsed()
        Is the object view collapsed ?
      • isExtended

        public boolean isExtended()
        Is the object view extended ?
      • setCollapsed

        public void setCollapsed​(ObjectDB obj,
                                 boolean collapse)
        Change the collapse flag of the object view
      • collapse

        public void collapse​(ObjectDB obj)
      • extend

        public void extend​(ObjectDB obj)
      • getIcon

        public java.lang.String getIcon()
        Get the icon code
      • setIcon

        public void setIcon​(java.lang.String icon)
        Set the icon code
      • getIconURL

        public java.lang.String getIconURL​(Grant g,
                                           java.lang.String defaultIcon)
        Get the icon URL
      • getIcon

        public java.lang.String getIcon​(Grant g,
                                        java.lang.String defaultIcon,
                                        java.lang.String size,
                                        java.lang.String cls)
        Get the icon as i, span or img
      • isFormEmbedded

        public boolean isFormEmbedded()
        Is embedded in object form ?
      • setFormEmbedded

        public void setFormEmbedded​(boolean b)
        Set embedded in object form ?
      • getDisposition

        public java.lang.String getDisposition()
        Get the disposition to activate when this home page is selected
      • setDisposition

        public void setDisposition​(java.lang.String disp)
        Set the home page disposition (home page only)
      • getGroups

        public java.util.List<java.lang.String> getGroups()
        Get the groups to activate when this home page is selected
      • addGroup

        public void addGroup​(java.lang.String group)
        Set the groups to activate (home page only)
      • setScope

        public void setScope​(java.lang.String scope)
        Set the view scope
        Parameters:
        scope - scope name
      • getScope

        public java.lang.String getScope()
        Get the view scope
      • setTheme

        public void setTheme​(java.lang.String name)
        Set the theme
        Parameters:
        name -
      • getTheme

        public java.lang.String getTheme()
        Get the theme name
      • setFont

        public void setFont​(java.lang.String name)
        Set the font
        Parameters:
        name - Google font
      • getFont

        public java.lang.String getFont()
        Get the font name
      • setIconSet

        public void setIconSet​(java.lang.String name)
        Set the icon set
        Parameters:
        name -
      • getIconSet

        public java.lang.String getIconSet()
        Get the icon set name
      • getFaviconURL

        public java.lang.String getFaviconURL​(int size)
        Theme favicon URL
      • setFaviconURL

        public void setFaviconURL​(int size,
                                  java.lang.String url)
      • setFavicon

        public void setFavicon​(java.lang.String docId)