Interface DesensitizeStrategy

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface DesensitizeStrategy
Desensitize Strategy - Functional interface for custom desensitization logic. 脱敏策略 - 用于自定义脱敏逻辑的函数式接口。

Features | 主要功能:

  • Functional interface for lambda-based strategies - 函数式接口支持Lambda策略
  • Custom desensitization logic - 自定义脱敏逻辑

Usage Examples | 使用示例:

DesensitizeStrategy strategy = original -> original.substring(0, 1) + "***";
String masked = strategy.desensitize("secret"); // "s***"

Security | 安全性:

  • Thread-safe: Depends on implementation - 线程安全: 取决于实现
Since:
JDK 25, opencode-base-string V1.0.0
Author:
Leon Soo www.LeonSoo.com
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    desensitize(String original)
     
  • Method Details