Class BooleanTransformer

java.lang.Object
de.craftsblock.craftsnet.api.transformers.builtin.BooleanTransformer
All Implemented Interfaces:
Transformable<Boolean,String>

public class BooleanTransformer extends Object implements Transformable<Boolean,String>
A transformer class for converting a string representation of a boolean value to a Boolean object. Implements the Transformable interface.
Since:
3.0.2-SNAPSHOT
See Also:
  • Constructor Details

    • BooleanTransformer

      public BooleanTransformer()
  • Method Details

    • transform

      public Boolean transform(String parameter)
      Transforms the provided string parameter into a Boolean object.
      Specified by:
      transform in interface Transformable<Boolean,String>
      Parameters:
      parameter - The string representation of the boolean value.
      Returns:
      The Boolean object representing the transformed value.
      Throws:
      NotTransformableException - If the parameter cannot be transformed to a Boolean.