code: private static PatternLayoutEncoder createPatternLayoutEncoder(LoggerContext context, String patternProperty) {
      final String pattern = context.getProperty(patternProperty);
      final PatternLayoutEncoder patternLayoutEncoder = new PatternLayoutEncoder();
      patternLayoutEncoder.setContext(context);
      patternLayoutEncoder.setPattern(pattern);
      patternLayoutEncoder.start();
      return patternLayoutEncoder;
    }
docs: Creates a {@link PatternLayoutEncoder} for the pattern specified for the pattern property.
  
  @param context Logger context to associate the pattern layout encoder with.
  @param patternProperty Logger context property that contains the required pattern.
  @return A {@link PatternLayoutEncoder} for the required pattern.