Class CodecsKt

  • All Implemented Interfaces:

    
    public final class CodecsKt
    
                        
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final static <A extends Any> Codec<List<A>> listOf(Codec<A> $self, IntRange range) このCodecをListのCodecに変換します。
      final static <A extends Any> Codec<List<A>> listOrElement(Codec<A> $self) このCodecを,要素が一つの場合はそのままコーデックするListのCodecに変換します。
      final static <A extends Any> Codec<List<A>> listOrElement(Codec<A> $self, IntRange range) このCodecを,要素が一つの場合はそのままコーデックするListのCodecに変換します。
      final static <A extends Any> Codec<List<A>> listOrElement(Codec<A> $self, Integer min, Integer max) このCodecを,要素が一つの場合はそのままコーデックするListのCodecに変換します。
      final static <A extends Any> Codec<Set<A>> setOf(Codec<List<A>> $self) このCodecをSetのCodecに変換します。
      • Methods inherited from class java.lang.Object

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

    • Method Detail

      • listOf

         final static <A extends Any> Codec<List<A>> listOf(Codec<A> $self, IntRange range)

        このCodecをListのCodecに変換します。

        Parameters:
        range - リストの長さの範囲
        Returns:

        リストの長さが制限されたListのCodec

        Since:

        0.16.0

      • listOrElement

         final static <A extends Any> Codec<List<A>> listOrElement(Codec<A> $self)

        このCodecを,要素が一つの場合はそのままコーデックするListのCodecに変換します。

        Since:

        0.1.0

      • listOrElement

         final static <A extends Any> Codec<List<A>> listOrElement(Codec<A> $self, IntRange range)

        このCodecを,要素が一つの場合はそのままコーデックするListのCodecに変換します。

        Parameters:
        range - リストの長さの範囲
        Returns:

        リストの長さが制限されたListのCodec

        Since:

        0.16.0

      • listOrElement

         final static <A extends Any> Codec<List<A>> listOrElement(Codec<A> $self, Integer min, Integer max)

        このCodecを,要素が一つの場合はそのままコーデックするListのCodecに変換します。

        Parameters:
        min - リストの長さの最小値
        max - リストの長さの最大値
        Returns:

        リストの長さが制限されたListのCodec

        Since:

        0.1.0

      • setOf

         final static <A extends Any> Codec<Set<A>> setOf(Codec<List<A>> $self)

        このCodecをSetのCodecに変換します。

        Returns:

        SetのCodec

        Since:

        0.16.0