This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--============================== | |
-- Send Keynote Text to Desktop Markdown File | |
-- Writted By: Richard Dooling https://github.com/RichardDooling/ | |
-- Based on | |
-- Send Keynote Presenter Notes to Evernote | |
-- Version 1.0.1 | |
-- Written By: Ben Waldie <[email protected]> | |
-- http://www.automatedworkflows.com | |
-- Version 1.0.0 - Initial release |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scalaz.{-\/, Applicative, Coproduct, Free, FreeAp, Inject, Monad, NaturalTransformation, Nondeterminism, \/-, ~>} | |
import scala.language.{higherKinds, reflectiveCalls} | |
import scalaz.concurrent.Task | |
import Task._ | |
import scala.util.Random | |
case class User(name: String, age: Int) | |
sealed trait UserOperation[T] | |
case class CreateUser(name: String, age: Int) extends UserOperation[User] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util | |
import com.sksamuel.avro4s.RecordFormat | |
import org.apache.avro.generic.GenericRecord | |
import org.apache.kafka.common.serialization.{Deserializer, Serde, Serializer} | |
object Avro4s { | |
implicit class CaseClassSerde(inner: Serde[GenericRecord]) { | |
def forCaseClass[T](implicit recordFormat: RecordFormat[T]): Serde[T] = { | |
val caseClassSerializer: Serializer[T] = new Serializer[T] { |