Interface PlainStringBuilder

All Superinterfaces:
DataContentBuilder<PlainString>
All Known Implementing Classes:
PlainStringBuilder.DefaultPlainStringBuilder

public interface PlainStringBuilder extends DataContentBuilder<PlainString>
Builder interface for constructing PlainString instances, which represent unencrypted textual content.

This builder supports specifying a string value to be encapsulated and optionally used in cryptographic processing pipelines, although the value itself remains unencrypted.

The DataContentBuilder.build(boolean) method accepts an encrypt flag to comply with the DataContentBuilder interface. However, this flag is ignored because PlainString represents unencrypted data.

Usage example:

PlainString plainText = PlainStringBuilder.builder()
    .value("Hello, World!")
    .build(true); // encrypt flag is ignored for PlainString
  • Method Details

    • builder

      static PlainStringBuilder builder()
      Creates a new instance of the default builder implementation.
      Returns:
      a new PlainStringBuilder
    • value

      PlainStringBuilder value(String value)
      Sets the string value that the PlainString instance will contain.
      Parameters:
      value - the string value; may be null or empty depending on usage
      Returns:
      this builder instance