A relatively simple akka server with a few bells and whistes.
package example
import scala.language._
import akka.actor._
import akka.http.scaladsl
import scaladsl._
(* ::Package:: *) | |
(* :Title: Import Delimited *) | |
(* :Summary: Containts declarations for importing a delimited text file into a session. *) | |
BeginPackage["ImportUtilities`"] | |
(* Canned functions that can be used as arguments. *) |
package org.im | |
package output | |
package prettyprinter | |
import scala.language._ | |
import java.io.Writer | |
import java.time._ | |
/** |
package tutorial.webapp | |
import language._ | |
import scala.scalajs.js | |
import scala.scalajs.js.JSApp | |
import scala.scalajs.js.annotation.JSName | |
import org.scalajs.dom | |
import org.scalajs.jquery.jQuery | |
import dom.document | |
import scala.scalajs.js.timers._ |
# -*- Mode:Python; indent-tabs-mode:nil; tab-width:4 -*- | |
# | |
# Copyright 2015 aappddeevv <aappddeevv@gmail.com> | |
# | |
# This file is part of duplicity. | |
# | |
# Duplicity is free software; you can redistribute it and/or modify it | |
# under the terms of the GNU General Public License as published by the | |
# Free Software Foundation; either version 2 of the License, or (at your | |
# option) any later version. |
A relatively simple akka server with a few bells and whistes.
package example
import scala.language._
import akka.actor._
import akka.http.scaladsl
import scaladsl._
If you use "readers" similar to play's json reader framework, you know that its a nice framework to compose your json converters. There is a similar framework for reading XML from lucidchart called xtract.
xtract only provides XML reading. Its very similar to play json. Many of the examples that demonstrate the play json or xtract library are fairly simple and did not help me understand how to compose readers that need to have alternatives. For example, an XML fragment may have an element called Fault
or an element called Data
and you want to compose a reader that
automatically handles both in one reader instance. How do you do that?
Here's some scalatest examples that show one way to do that. You have some choices about how to navigate and how to compose so pay special attention to the details in the tests. I prefer to compose by using readers at the top element and use and/or on the builders, but you can choose to do it anyway you wish.
import org.scalatest._
class readerspecs extends FlatSp
If you need a redux reducer that adds some "injectables" as the third argument to the reducers normally combined in redux's combineReducers, try this one:
/**
* A combineReducers replacement that adds additional arguments
* to the reduction call to inject different values a reducer
* might need, read-only, from other parts of the tree. Reducer
* order calling is not specified. If no injectables are provided
* the overall state is included under the key "_root_".
*
* @param {Object} reducers Reducer object. Each key with a function is included in a final reducer.
Hi!
My background:
package test | |
import zio._ | |
import zio.console._ | |
type FakeExchange = Has[FakeExchange.Service] | |
object FakeExchange: | |
trait Service: | |
def blah(): UIO[Unit] |