bijection icon indicating copy to clipboard operation
bijection copied to clipboard

Reversible conversions between types

Results 72 bijection issues
Sort by recently updated
recently updated
newest added

The [algebird-test](https://github.com/twitter/algebird/tree/develop/algebird-test) artifact distributes scalacheck properties which allow users of the library to ensure they are implmenting traits defined in the library sucessfully. Similarly, the properties defined in `BaseProperties.scala` should...

Now we really just use Bijections or Injections, so having Rep's too just leads to confusion. We should just remove all instances

we should turn on wart-remover: https://github.com/puffnfresh/wartremover to disable some aspects of scala that lead to bad errors or unsafe code. Inferring Any, any2addString, Unit coercion are a few that look...

see https://github.com/twitter/bijection/pull/197 ``` [info] Compiling 1 Scala source to bijection/bijection-finagle-mysql/target/scala-2.10/test-classes... [info] MySqlConversionLaws: [info] - Byte [info] - Short [info] - Int [info] - Long [info] - Float [info] - Double...

Bufferable is a somewhat under used typeclass, but with macros, this could change. The idea was a composable binary serialization type that could be used in conjunction with Injections and...

see the comments here: https://github.com/twitter/bijection/pull/183 Ordering, Numeric, Equiv (and any other scala defaults) should probably be added to the companion object. For algebird-bijection we should support this approach as well.

Scrooge generated ThriftEnum does extend the apache TEnum, e.g. https://github.com/twitter/scrooge/blob/master/scrooge-core/src/main/scala/com/twitter/scrooge/ThriftEnum.scala#L5 sealed trait EngagementType extends ThriftEnum with Serializable But the com.twitter.bijection.thrift.TEnumCodec.toBinary[T import com.twitter.discover.summingbird.common.thriftscala.EngagementType import com.twitter.discover.summingbird.common.thriftscala.EngagementType scala> import EngagementType._ import EngagementType._ scala>...

Something like: ``` scala trait Encoder[T, U] { def apply(t: T): U // and andThen, toFn, } trait Decoder[U, T] { def apply(u: U): Try[T] } // composition might be...

have to be careful with cycles in the implicit resolution.

Bijection that moves between deflated and inflated bytes. Here's the idea (please forgive my lack of wrapper classes): ``` scala import java.util.zip.{ Deflater, Inflater, InflaterInputStream, DeflaterOutputStream } import java.io.{ ByteArrayInputStream,...