Module life.expert

Class SolidString

  • All Implemented Interfaces:
    java.lang.Comparable<SolidString>

    public final class SolidString
    extends java.lang.Object
    implements java.lang.Comparable<SolidString>
    Simple immutable String holder class Class invariant: non blank and stripped String - pattern new-call - not for inheritance - only the monoOf.. factory methods is allowed, because it allows you to lazily create objects only with a real subscription - 'of' - factory method is prohibited because it is intended only for easy creation of objects in tests, please use pure functional methods monoOf.., without raise exceptions.
    
          var s=SolidString.tryOf( goodString );
     ******
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  SolidString.SolidStringBuilder
      The type Non blank string builder.
    • Constructor Summary

      Constructors 
      Constructor Description
      SolidString()  
    • Method Summary

      Modifier and Type Method Description
      static SolidString.SolidStringBuilder builder()
      Builder non blank string builder.
      int compareTo​(SolidString o)  
      static reactor.core.publisher.Mono<SolidString> copyOf​(SolidString other)
      Standard Copy Factory
      static reactor.core.publisher.Mono<SolidString> monoOf​(java.lang.String string)
      Create SolidString from String Only the monoOf..
      static reactor.core.publisher.Mono<SolidString> monoOfMono​(reactor.core.publisher.Mono<java.lang.String> string)
      Create SolidString from Mono with String inside The method helps chaining flows together
      static reactor.core.publisher.Mono<SolidString> monoOfMonoWithTuple​(reactor.core.publisher.Mono<io.vavr.Tuple1<java.lang.String>> tuple)
      Create SolidString from Mono with Tuple inside The method helps chaining flows together
      static reactor.core.publisher.Mono<SolidString> monoOfTuple​(io.vavr.Tuple1<java.lang.String> tuple)
      Create SolidString from Tuple The method helps with conversion operations Tuple->SolidString
      static SolidString of​(java.lang.String string)
      Deprecated.
      please use pure functional methods monoOf.., without raise exceptions.
      static io.vavr.Tuple1<java.lang.String> SolidString​(SolidString object)
      pattern matching in vavr - you need add static import to method with pattern matching import static life.expert.value.string.NonBlankStringPatterns.*;
      SolidString.SolidStringBuilder toBuilder()
      To builder non blank string builder.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • SolidString

        public SolidString()
    • Method Detail

      • monoOf

        public static reactor.core.publisher.Mono<SolidString> monoOf​(java.lang.String string)
        Create SolidString from String Only the monoOf.. factory methods is allowed, because it allows you to lazily create objects only with a real subscription
        Parameters:
        string - the string
        Returns:
        the Mono with lazyli created object
        Implementation Note:
        to create objects, this method calls the private factory monoOf_
      • of

        @Deprecated
        public static SolidString of​(java.lang.String string)
        Deprecated.
        please use pure functional methods monoOf.., without raise exceptions.
         Classic fabric method for creating non blank string.
         This factory method is prohibited because it is intended only for easy creation of objects in tests
        Parameters:
        string - the string
        Returns:
        the non blank string
        Throws:
        java.lang.IllegalArgumentException - if string non blank or nullable
      • monoOfTuple

        public static reactor.core.publisher.Mono<SolidString> monoOfTuple​(io.vavr.Tuple1<java.lang.String> tuple)
        Create SolidString from Tuple The method helps with conversion operations Tuple->SolidString
        Parameters:
        tuple - the tuple
        Returns:
        the Mono with lazyli created object
      • monoOfMonoWithTuple

        public static reactor.core.publisher.Mono<SolidString> monoOfMonoWithTuple​(reactor.core.publisher.Mono<io.vavr.Tuple1<java.lang.String>> tuple)
        Create SolidString from Mono with Tuple inside The method helps chaining flows together
        Parameters:
        tuple - the tuple
        Returns:
        the Mono with lazyli created object
      • monoOfMono

        public static reactor.core.publisher.Mono<SolidString> monoOfMono​(reactor.core.publisher.Mono<java.lang.String> string)
        Create SolidString from Mono with String inside The method helps chaining flows together
        Parameters:
        string - the string
        Returns:
        the Mono with lazyli created object
      • copyOf

        public static reactor.core.publisher.Mono<SolidString> copyOf​(SolidString other)
        Standard Copy Factory
        Parameters:
        other - the other
        Returns:
        the Mono with lazyli created object
        Implementation Note:
        to create objects, this method calls the private factory monoOf_
      • compareTo

        public int compareTo​(SolidString o)
        Specified by:
        compareTo in interface java.lang.Comparable<SolidString>
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • SolidString

        public static io.vavr.Tuple1<java.lang.String> SolidString​(SolidString object)
        pattern matching in vavr - you need add static import to method with pattern matching import static life.expert.value.string.NonBlankStringPatterns.*;
        Parameters:
        object - the object
        Returns:
        the tuple 1