content: package org.alfresco.transform.pii;
  
  import org.alfresco.transform.base.TransformEngine;
  import org.alfresco.transform.base.probes.ProbeTransform;
  import org.alfresco.transform.config.reader.TransformConfigResourceReader;
  import org.alfresco.transform.config.TransformConfig;
  import org.springframework.beans.factory.annotation.Autowired;
  import org.springframework.stereotype.Component;
  
  import java.util.Map;
  
  @Component
  public class PIIRedactionTransformEngine implements TransformEngine
  {
  
      private static final String ENGINE_NAME = "pdf-pii";
      private static final String CONFIG_PATH = "classpath:pii_engine_config.json";
  
      private final TransformConfigResourceReader transformConfigResourceReader;
  
      @Autowired
      public PIIRedactionTransformEngine(TransformConfigResourceReader transformConfigResourceReader) {
          this.transformConfigResourceReader = transformConfigResourceReader;
      }
  
      @Override
      public String getTransformEngineName() {
          return ENGINE_NAME;
      }
  
      @Override
      public String getStartupMessage() {
          return String.format("Startup %s\nNo 3rd party licenses", ENGINE_NAME);
      }
  
      @Override
      public TransformConfig getTransformConfig() {
          return transformConfigResourceReader.read(CONFIG_PATH);
      }
  
      @Override
      public ProbeTransform getProbeTransform() {
          return new ProbeTransform(
                  "input.pdf", "application/pdf", "application/pdf", Map.of(),
                  60, 150, 1024, 1024 * 20, 1, 1);
      }
  
  }