Interface Anonymizer


public interface Anonymizer
Provides API for Anonymizer implementation. Anonymizer implementation (AnonymizerClass) can be specified for each model field except the default fields. If specified then field will be participating in the Anonymization process and anonymized value will be fetched from anonymizeSql method call. A typical implementation would look something like below:
   public class UserNameAnonymizer implements Anonymizer {
    @Override
    public String anonymizeSql(ModelLevelType modelLevelType, String fieldName, List<String> columns, String params) {
      return "ANONMYIZED || SYS_GUID()";
    }
   }
 
  • Field Summary

    Fields 
    Modifier and Type Field Description
    static java.lang.String ANONYMIZED  
  • Method Summary

    Modifier and Type Method Description
    java.lang.String anonymizeSql​(com.onenetwork.platform.data.model.impl.ModelLevelType modelLevelType, java.lang.String fieldName, java.util.List<java.lang.String> columns, java.lang.String params)
    Return the SQL function or SQL to anonymize the column value
  • Field Details

  • Method Details

    • anonymizeSql

      java.lang.String anonymizeSql​(com.onenetwork.platform.data.model.impl.ModelLevelType modelLevelType, java.lang.String fieldName, java.util.List<java.lang.String> columns, java.lang.String params)
      Return the SQL function or SQL to anonymize the column value
      Parameters:
      modelLevelType - model's level type
      fieldName - name of the field within the level
      columns - column names of field for which data anonymization will be done
      params - if the anonymization query requires bound params, this should contain those values. If it does not require params, pass null.
      Returns:
      SQL which will be used to set anonymized value.