Class InMemoryPropertyReplacement

java.lang.Object
flexagon.fd.core.utils.AbstractPropertyReplacement
flexagon.fd.core.utils.InMemoryPropertyReplacement

public class InMemoryPropertyReplacement extends AbstractPropertyReplacement
Concrete implementation for property replacement on a list of Strings. Properties are defined within a given source using the notation ${{PropertyName}}. This implementation is useful when the contents are of a file (as a List of String) are already available in memory, but may be utilized for any List of Strings. The property names are case-sensitive.
  • Constructor Details

    • InMemoryPropertyReplacement

      public InMemoryPropertyReplacement(WorkflowExecutionContext pWorkflowExecutionContext, List<String> pFileData)
      Constructs this utility for use with the given workflow execution context and source.
      Parameters:
      pWorkflowExecutionContext - the workflow execution context
      pFileData - the source containing properties to replace
    • InMemoryPropertyReplacement

      public InMemoryPropertyReplacement(PropertyReplacementContext pPropertyReplacementContext, List<String> pFileData)
      Constructs this utility for use with the given property replacement context and source.
      Parameters:
      pPropertyReplacementContext - the property replacement context
      pFileData - the source containing properties to replace
  • Method Details

    • replaceAll

      public List<String> replaceAll() throws FlexCheckedException
      Replaces all properties within the source with the key/values found in the WorkflowExecutionContext or PropertyReplacementContext.
      Throws:
      FlexCheckedException - if a property replacement fails