object FieldDecoder extends MidPriorityFieldDecoder with Serializable
- Grouped
- Alphabetic
- By Inheritance
- FieldDecoder
- Serializable
- Serializable
- MidPriorityFieldDecoder
- LowPriorityFieldDecoder
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
case class
FieldTag extends Product with Serializable
- Attributes
- protected[io.protoless]
- Definition Classes
- LowPriorityFieldDecoder
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
apply[A](implicit instance: FieldDecoder[A]): FieldDecoder[A]
Return a FieldDecoder instance for a given type
A
. -
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
final
def
const[A](a: A): FieldDecoder[A]
Generate a FieldDecoder that always return a single value.
-
implicit final
def
decodeArray[A](implicit dec: RepeatableFieldDecoder[A], cbf: CanBuildFrom[Nothing, A, Seq[A]], tp: ClassTag[A]): RepeatableFieldDecoder[Array[A]]
Decode a repeating field of type
A
into an Array.Decode a repeating field of type
A
into an Array.TODO: Improve performance by not depending on
decodeTraversable
- Definition Classes
- LowPriorityFieldDecoder
- implicit final val decodeBigDecimal: RepeatableFieldDecoder[BigDecimal]
- implicit final val decodeBigInt: RepeatableFieldDecoder[BigInt]
- implicit final val decodeBoolean: RepeatableFieldDecoder[Boolean]
- implicit final val decodeByteString: RepeatableFieldDecoder[ByteString]
- implicit final val decodeChar: RepeatableFieldDecoder[Char]
- implicit final val decodeDouble: RepeatableFieldDecoder[Double]
-
final
def
decodeEnum[E <: Enumeration](enum: E): RepeatableFieldDecoder[FieldDecoder.decodeEnum.E.Value]
Generate a FieldDecoder allowing to parse Enumerations.
Generate a FieldDecoder allowing to parse Enumerations.
object WeekDay extends Enumeration { ... } implicit val weekDayDecoder: RepeatableFieldDecoder[WeekDay.Value] = FieldDecoder.decodeEnum(WeekDay)
- implicit final val decodeFInt: RepeatableFieldDecoder[@@[Int, Fixed]]
- implicit final val decodeFLong: RepeatableFieldDecoder[@@[Long, Fixed]]
- implicit final val decodeFloat: RepeatableFieldDecoder[Float]
- implicit final val decodeInt: RepeatableFieldDecoder[Int]
- implicit final val decodeLong: RepeatableFieldDecoder[Long]
-
implicit final
def
decodeNestedMessage[A](implicit dec: Decoder[A]): RepeatableFieldDecoder[A]
Allow to decode a message
A
as a nested field if we have aDecoder[A]
.Allow to decode a message
A
as a nested field if we have aDecoder[A]
.- Definition Classes
- MidPriorityFieldDecoder
- implicit final def decodeNonEmptyList[A](implicit dec: FieldDecoder[List[A]]): FieldDecoder[NonEmptyList[A]]
- implicit final def decodeOption[A](implicit dec: RepeatableFieldDecoder[A]): RepeatableFieldDecoder[Option[A]]
- implicit final val decodeSFInt: RepeatableFieldDecoder[@@[Int, Signed with Fixed]]
- implicit final val decodeSFLong: RepeatableFieldDecoder[@@[Long, Signed with Fixed]]
- implicit final val decodeSInt: RepeatableFieldDecoder[@@[Int, Signed]]
- implicit final val decodeSLong: RepeatableFieldDecoder[@@[Long, Signed]]
- implicit final val decodeShort: RepeatableFieldDecoder[Short]
- implicit final val decodeString: RepeatableFieldDecoder[String]
-
implicit final
def
decodeTraversable[A, C[A] <: Traversable[A]](implicit dec: RepeatableFieldDecoder[A], cbf: CanBuildFrom[Nothing, A, C[A]]): RepeatableFieldDecoder[C[A]]
Decode a repeating field of type
A
into a Traversable collectionC
.Decode a repeating field of type
A
into a Traversable collectionC
.- Definition Classes
- LowPriorityFieldDecoder
- implicit final val decodeUInt: RepeatableFieldDecoder[@@[Int, Unsigned]]
- implicit final val decodeULong: RepeatableFieldDecoder[@@[Long, Unsigned]]
-
implicit final
val
decodeUUID: FieldDecoder[UUID]
Decode an UUID from a
repeated sint64
field, containing themostSignificantBits
andLeastSignificantBits
of the 128 bits UUID. -
implicit final
def
decodeValueClass[A, R](implicit ev: <:<[A, AnyVal], unwrapped: Aux[A, R], dec: FieldDecoder[R]): FieldDecoder[A]
Automatically decode a value wrapped in a value class
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
failed[A](failure: String): FieldDecoder[A]
Generate a FieldDecoder that always return a single failure.
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
readTag(input: CodedInputStream, currentIndex: Int): FieldTag
Read the next field tag and extract the FieldNumber / WireType.
Read the next field tag and extract the FieldNumber / WireType.
Detect if the tag has already been read by checking the
lastTag
in priority. If the field number read from the lastTag is different that the currentIndex, so read the next tag from the stream.- Attributes
- protected[io.protoless]
- Definition Classes
- LowPriorityFieldDecoder
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
object
FieldTag extends Serializable
- Attributes
- protected[io.protoless]
- Definition Classes
- LowPriorityFieldDecoder
This is the API documentation for Protoless, a Protobuf library for Scala.
The main entry point to use protoless is the io.protoless.generic package object, which allow to derive encoders and decoders for your case classes.
The library is split in several modules:
Please see the guide for more information on how to use protoless.