Class DataSetsFieldsWrapperBase<T extends DataSetField>

    • Constructor Detail

      • DataSetsFieldsWrapperBase

        public DataSetsFieldsWrapperBase​(IDataSetWrapper dataSetWrapper,
                                         T field)
        Constructor
        Parameters:
        dataSetWrapper - data set wrapper, can't be null
        field - field, can't be null
    • Method Detail

      • setTitle

        protected IDataSetFieldsWrapper.FieldCommand setTitle​(String langTitle,
                                                              String languageCode)
        Set title
        Parameters:
        langTitle - title for current language, can't be null
        languageCode - current language code, can't be null
        Returns:
        command, never null
      • isNameUnique

        protected boolean isNameUnique​(String name)
        Check whether name is unique
        Parameters:
        name - name, can't be null
        Returns:
        whether name is unique
      • isPathUnique

        protected boolean isPathUnique​(String path)
        Check whether path is unique
        Parameters:
        path - path, can't be null
        Returns:
        whether path is unique
      • isStringEquals

        protected boolean isStringEquals​(String value1,
                                         String value2)
        Check whether strings equal
        Parameters:
        value1 - string, can be null
        value2 - other string, can be null
        Returns:
        whether strings is equals
      • startsWith

        protected boolean startsWith​(String value1,
                                     String value2)
        Check whether begining of string equals another string
        Parameters:
        value1 - string, can be null
        value2 - other string, can be null
        Returns:
        whether begining of string equals another string
      • getDuplicatedErrorMessage

        protected String getDuplicatedErrorMessage​(List<String> fieldsDuplicated)
        Create message for duplicated fields
        Parameters:
        fieldsDuplicated - fields names, can't be null
        Returns:
        message, never null
      • getCurrentLanguageCode

        protected String getCurrentLanguageCode()
        Get current language code
        Returns:
        language code, never null
      • getSynonym

        protected IDataSetWrapper.FieldSynonym getSynonym​(String path)
        Get field synonym by path
        Parameters:
        path - path, can't be null
        Returns:
        synonym, never null
      • getFieldsWrappers

        protected Collection<IDataSetFieldsWrapper> getFieldsWrappers()
        Get fields wrappers for this data set
        Returns:
        collection of fields wrappers, never null
      • getParentPath

        protected String getParentPath()
        Get path of field parent
        Returns:
        path of field parent
      • getFieldByPath

        protected DataSetField getFieldByPath​(String path)
        Get field by path
        Parameters:
        path - field path, can't be null
        Returns:
        field or null if field not found