From 92533c0b5dffdecc8b4f0235760a41d071233b41 Mon Sep 17 00:00:00 2001 From: Scala Steward Date: Thu, 19 Aug 2021 05:45:21 +0200 Subject: [PATCH 1/2] Update scalafmt-core to 3.0.0 --- .scalafmt.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.scalafmt.conf b/.scalafmt.conf index c91d0d6..48223e9 100644 --- a/.scalafmt.conf +++ b/.scalafmt.conf @@ -1,4 +1,4 @@ -version = 2.7.5 +version = 3.0.0 style = default From 23c2319b1d5aa783fd43542bd11e2325227136f8 Mon Sep 17 00:00:00 2001 From: Scala Steward Date: Thu, 19 Aug 2021 05:45:29 +0200 Subject: [PATCH 2/2] Reformat with scalafmt 3.0.0 --- .../scala/sangria/marshalling/ArrayMapBuilder.scala | 3 ++- .../sangria/marshalling/InputUnmarshaller.scala | 11 +++++++---- .../scala/sangria/marshalling/ResultMarshaller.scala | 12 ++++++++---- 3 files changed, 17 insertions(+), 9 deletions(-) diff --git a/src/main/scala/sangria/marshalling/ArrayMapBuilder.scala b/src/main/scala/sangria/marshalling/ArrayMapBuilder.scala index 7b44d49..bd686fe 100644 --- a/src/main/scala/sangria/marshalling/ArrayMapBuilder.scala +++ b/src/main/scala/sangria/marshalling/ArrayMapBuilder.scala @@ -4,7 +4,8 @@ import scala.annotation.tailrec import scala.collection.immutable.{ListMap, VectorBuilder} import scala.collection.mutable.{Set => MutableSet} -/** GraphQL `Map` builder that knows keys in advance and able to preserve an original fields sort order +/** GraphQL `Map` builder that knows keys in advance and able to preserve an original fields sort + * order */ class ArrayMapBuilder[T](keys: Seq[String]) extends Iterable[(String, T)] { private val elements = new Array[(String, T)](keys.size) diff --git a/src/main/scala/sangria/marshalling/InputUnmarshaller.scala b/src/main/scala/sangria/marshalling/InputUnmarshaller.scala index 067e980..220f979 100644 --- a/src/main/scala/sangria/marshalling/InputUnmarshaller.scala +++ b/src/main/scala/sangria/marshalling/InputUnmarshaller.scala @@ -22,10 +22,12 @@ trait InputUnmarshaller[Node] { def isEnumNode(node: Node): Boolean def isVariableNode(node: Node): Boolean - /** @return Scalar values are Scala String, Int, Double, Boolean and Enum values defined in the schema - * as well as ast nodes if appropriate. + /** @return + * Scalar values are Scala String, Int, Double, Boolean and Enum values defined in the schema + * as well as ast nodes if appropriate. * - * TODO: find better approach. Ideally the should be only one `getScalarValue` method witch returns normal scala values + * TODO: find better approach. Ideally the should be only one `getScalarValue` method witch + * returns normal scala values */ def getScalarValue(node: Node): Any @@ -40,7 +42,8 @@ trait InputUnmarshaller[Node] { * - scala.BigInt * - scala.BigDecimal * - * @return Only normal scala scalar values + * @return + * Only normal scala scalar values */ def getScalaScalarValue(node: Node): Any diff --git a/src/main/scala/sangria/marshalling/ResultMarshaller.scala b/src/main/scala/sangria/marshalling/ResultMarshaller.scala index 6375aaa..21353e7 100644 --- a/src/main/scala/sangria/marshalling/ResultMarshaller.scala +++ b/src/main/scala/sangria/marshalling/ResultMarshaller.scala @@ -29,10 +29,13 @@ trait ResultMarshaller { * - scala.BigInt * - scala.BigDecimal * - * Implementation may also support additional scala types if underlying data format supports them (like Dates, or BLOBs). + * Implementation may also support additional scala types if underlying data format supports them + * (like Dates, or BLOBs). * - * @param value coerced scalar value - * @return marshaled node + * @param value + * coerced scalar value + * @return + * marshaled node */ def scalarNode(value: Any, typeName: String, info: Set[ScalarValueInfo]): Node @@ -60,7 +63,8 @@ object ResultMarshaller { scalaMarshalling.scalaResultMarshaller } -/** Alters the behaviour of the executor and marshals raw (in-scala coerced representation) or scalar values and enums. +/** Alters the behaviour of the executor and marshals raw (in-scala coerced representation) or + * scalar values and enums. */ trait RawResultMarshaller extends ResultMarshaller { def rawScalarNode(rawValue: Any): Node