Class SynonymAwarePresentationProvider

    • Constructor Detail

      • SynonymAwarePresentationProvider

        public SynonymAwarePresentationProvider​(IBmModelManager bmModelManager)
        Constructs the instance of the provider.
        Parameters:
        bmModelManager - The IBmModelManager reference.
    • Method Detail

      • addAdapter

        public static void addAdapter​(IBmObject target,
                                      org.eclipse.emf.ecore.EObject objectWithSynonym)
        Adds adapter data for the given context.
        Parameters:
        target - The target object to store context in (not null)
        objectWithSynonym - - the object with synonym (not null)
      • addAdapter

        public static void addAdapter​(IBmObject target,
                                      org.eclipse.emf.ecore.EObject objectWithSynonym,
                                      String separator,
                                      String suffix)
        Adds adapter data for the given context.
        Parameters:
        target - The target object to store context in (not null)
        objectWithSynonym - The object with synonym (not null)
        separator - The separator (not null)
        suffix - - the suffix (not null)
      • getFieldName

        protected String getFieldName​(DbViewFieldDef field)
        Gets the field display name.
        Parameters:
        field - The field.
        Returns:
        The display name of the field.
      • getFromSynonym

        protected String getFromSynonym​(IBmObject synonymSource,
                                        String languageCode)
        Gets the name information from the synonym.
        Parameters:
        synonymSource - The source of the synonym data.
        languageCode - The code of the language to get synonym data for.
        Returns:
        The synonym data that corresponds the given language code.
      • getLocalizedSuffix

        protected String getLocalizedSuffix​(String suffix)
        Gets the UI-localized representation of the suffix.
        Parameters:
        suffix - The suffix.
        Returns:
        The localized representation of the suffix, never null