Skip to content

leifwickland/magicString

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Magic String

An automatic toString generator using Shapeless.

Example:

    case class Bar(first: String, second: Int)
    case class Foo(s: String, i: Int, doubles: List[Double], bars: List[Bar])
    val foo = Foo("Hello", 1, List(3.0, 2.7), List(Bar("firstThing", 100), Bar("second", 200)))
    val bar = Bar("hello", 1)
    println(foo.magicString)
    // Foo(s=Hello, i=1, doubles=[3.0,2.7], bars=[Bar(first=firstThing, second=100),Bar(first=second, second=200)])

So far just an experiment, pushing to gather some feedback.

About

Automatic nice toString generation for case classes.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Scala 100.0%