com.ibm.dbb.build

Class PropertyMappings

  • java.lang.Object
    • com.ibm.dbb.build.PropertyMappings


  • public class PropertyMappings
    extends java.lang.Object
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void addFilePattern(java.lang.String value, java.lang.String filePattern)
      Appends a file pattern to the list of associated file patterns for the script mapping
      void addFilePatterns(java.lang.String value, java.util.List<java.lang.String> filePatterns)
      Appends a list of file patterns to the list of associated file patterns for the script mapping
      java.lang.String getKeyName() 
      java.util.List<java.lang.String> getMappedList(java.lang.String value, java.io.File file)
      Returns a sublist of files that are mapped the value name
      java.util.List<java.lang.String> getMappedList(java.lang.String value, java.io.File file, java.lang.String encoding)
      Returns a sublist of files that are mapped the value
      java.util.List<java.lang.String> getMappedList(java.lang.String value, java.util.List<java.lang.String> files)
      Returns a sublist of files that are mapped the value name
      java.lang.String getValue(java.lang.String file)
      Returns the value associated to the relative path file or NULL if no value is found for the file.
      java.util.Set<java.lang.String> getValues()
      Returns all the values of the map
      boolean isMapped(java.lang.String value, java.lang.String file)
      Returns true if the list contains the value mapping
      void setKeyName(java.lang.String newKeyName) 
      void setValue(java.lang.String value, java.util.List<java.lang.String> filePatterns)
      Sets a value association.
      • Methods inherited from class java.lang.Object

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

      • getValue

        public java.lang.String getValue(java.lang.String file)
        Returns the value associated to the relative path file or NULL if no value is found for the file.
        Parameters:
        file - : The relative path of the file to search for.
        Returns:
        The name of the value associated to the file or NULL if none found
      • setValue

        public void setValue(java.lang.String value,
                             java.util.List<java.lang.String> filePatterns)
        Sets a value association. If the value already exists, the existing file pattern associations are replaced with the new file patterns
        Parameters:
        value - : The name of the value to associate
        filePatterns - The list of file patterns to associate to this value
      • addFilePattern

        public void addFilePattern(java.lang.String value,
                                   java.lang.String filePattern)
        Appends a file pattern to the list of associated file patterns for the script mapping
        Parameters:
        value - : The name of the value
        filePattern - : The file pattern to add to the script mapping
      • addFilePatterns

        public void addFilePatterns(java.lang.String value,
                                    java.util.List<java.lang.String> filePatterns)
        Appends a list of file patterns to the list of associated file patterns for the script mapping
        Parameters:
        value - : The name of the value
        filePatterns - : The list of file patterns to add to the script mapping
      • isMapped

        public boolean isMapped(java.lang.String value,
                                java.lang.String file)
        Returns true if the list contains the value mapping
        Parameters:
        value - : The name of the value
        file - : The relative file associated to the value name
        Returns:
        true if the list contains the value mapping
      • getMappedList

        public java.util.List<java.lang.String> getMappedList(java.lang.String value,
                                                              java.util.List<java.lang.String> files)
        Returns a sublist of files that are mapped the value name
        Parameters:
        value - : The name of the value be matched
        files - : The list of files to match
        Returns:
        A list of relative path files that are associated to the value name
      • getMappedList

        public java.util.List<java.lang.String> getMappedList(java.lang.String value,
                                                              java.io.File file)
                                                       throws java.io.IOException
        Returns a sublist of files that are mapped the value name
        Parameters:
        value - : The name of the value be matched
        file - : An external file containing a list of files to match
        Returns:
        A list of relative path files that are associated to the value name
        Throws:
        java.io.IOException - If an error occurred when reading the file.
      • getMappedList

        public java.util.List<java.lang.String> getMappedList(java.lang.String value,
                                                              java.io.File file,
                                                              java.lang.String encoding)
                                                       throws java.io.IOException
        Returns a sublist of files that are mapped the value
        Parameters:
        value - : The name of the value be matched
        file - : An external file containing a list of files to match
        encoding - : The encoding of the input file
        Returns:
        A list of relative path files that are associated to the value
        Throws:
        java.io.IOException - If an error occurred when reading the file.
      • getValues

        public java.util.Set<java.lang.String> getValues()
        Returns all the values of the map
        Returns:
        A set of all values
      • setKeyName

        public void setKeyName(java.lang.String newKeyName)
        Parameters:
        newKeyName - : the new name of the BuildProperties key
      • getKeyName

        public java.lang.String getKeyName()
        Returns:
        the name of the BuildProperties key

<IBM Copyright © 2018 IBM Corp. All Rights Reserved.