From 0a153fa52f2f4b46aa0e6256f2288e0dee1fa599 Mon Sep 17 00:00:00 2001 From: Peter Vendamere Date: Tue, 22 Aug 2023 11:10:20 -0500 Subject: [PATCH] Formatting change and update conversion library --- .../com/banno/cosmos4s/BaseCosmosContainer.scala | 2 +- .../com/banno/cosmos4s/IndexedCosmosContainer.scala | 1 - .../com/banno/cosmos4s/RawCosmosContainer.scala | 1 - .../com/banno/cosmos4s/types/FeedResponse.scala | 2 +- .../banno/cosmos4s/types/ItemRequestOptions.scala | 12 ++++++------ .../com/banno/cosmos4s/types/ItemResponse.scala | 2 +- 6 files changed, 9 insertions(+), 11 deletions(-) diff --git a/core/src/main/scala/com/banno/cosmos4s/BaseCosmosContainer.scala b/core/src/main/scala/com/banno/cosmos4s/BaseCosmosContainer.scala index 819de0c..6248393 100644 --- a/core/src/main/scala/com/banno/cosmos4s/BaseCosmosContainer.scala +++ b/core/src/main/scala/com/banno/cosmos4s/BaseCosmosContainer.scala @@ -24,7 +24,7 @@ import com.azure.cosmos.models.{PartitionKey, SqlParameter, SqlQuerySpec} import com.banno.cosmos4s.types._ import com.fasterxml.jackson.databind.JsonNode import fs2.Stream -import collection.JavaConverters._ +import scala.jdk.CollectionConverters._ import io.circe.jackson._ import io.circe._ import com.azure.cosmos.implementation.NotFoundException diff --git a/core/src/main/scala/com/banno/cosmos4s/IndexedCosmosContainer.scala b/core/src/main/scala/com/banno/cosmos4s/IndexedCosmosContainer.scala index 244e429..707cbbc 100644 --- a/core/src/main/scala/com/banno/cosmos4s/IndexedCosmosContainer.scala +++ b/core/src/main/scala/com/banno/cosmos4s/IndexedCosmosContainer.scala @@ -24,7 +24,6 @@ import com.azure.cosmos.models._ import com.banno.cosmos4s.types._ import fs2.Stream import io.circe._ -import scala.jdk.CollectionConverters._ trait IndexedCosmosContainer[F[_], K, I, V] { def query( diff --git a/core/src/main/scala/com/banno/cosmos4s/RawCosmosContainer.scala b/core/src/main/scala/com/banno/cosmos4s/RawCosmosContainer.scala index e51734a..32de9d8 100644 --- a/core/src/main/scala/com/banno/cosmos4s/RawCosmosContainer.scala +++ b/core/src/main/scala/com/banno/cosmos4s/RawCosmosContainer.scala @@ -21,7 +21,6 @@ import cats.effect._ import com.banno.cosmos4s.types._ import fs2.Stream import io.circe._ -import scala.jdk.CollectionConverters._ trait RawCosmosContainer[F[_], V] { def queryRaw( diff --git a/core/src/main/scala/com/banno/cosmos4s/types/FeedResponse.scala b/core/src/main/scala/com/banno/cosmos4s/types/FeedResponse.scala index 063b9df..ed6b04f 100644 --- a/core/src/main/scala/com/banno/cosmos4s/types/FeedResponse.scala +++ b/core/src/main/scala/com/banno/cosmos4s/types/FeedResponse.scala @@ -16,7 +16,7 @@ package com.banno.cosmos4s.types -import collection.JavaConverters._ +import scala.jdk.CollectionConverters._ import com.azure.cosmos.CosmosDiagnostics object FeedResponse { diff --git a/core/src/main/scala/com/banno/cosmos4s/types/ItemRequestOptions.scala b/core/src/main/scala/com/banno/cosmos4s/types/ItemRequestOptions.scala index 4198e7f..ded09e9 100644 --- a/core/src/main/scala/com/banno/cosmos4s/types/ItemRequestOptions.scala +++ b/core/src/main/scala/com/banno/cosmos4s/types/ItemRequestOptions.scala @@ -17,7 +17,7 @@ package com.banno.cosmos4s.types import com.azure.cosmos.models.{CosmosItemRequestOptions, IndexingDirective} -import collection.JavaConverters._ +import scala.jdk.CollectionConverters._ final class ItemRequestOptions private ( private val ifMatchEtag: Option[String], @@ -62,11 +62,11 @@ final class ItemRequestOptions private ( o match { case x: ItemRequestOptions => (this.ifMatchEtag == x.ifMatchEtag) && - (this.ifNoneMatchEtag == x.ifNoneMatchEtag) && - (this.indexingDirective == x.indexingDirective) && - (this.postTriggerInclude == x.postTriggerInclude) && - (this.preTriggerInclude == x.preTriggerInclude) && - (this.sessionToken == x.sessionToken) + (this.ifNoneMatchEtag == x.ifNoneMatchEtag) && + (this.indexingDirective == x.indexingDirective) && + (this.postTriggerInclude == x.postTriggerInclude) && + (this.preTriggerInclude == x.preTriggerInclude) && + (this.sessionToken == x.sessionToken) case _ => false } diff --git a/core/src/main/scala/com/banno/cosmos4s/types/ItemResponse.scala b/core/src/main/scala/com/banno/cosmos4s/types/ItemResponse.scala index 56faf2f..216f695 100644 --- a/core/src/main/scala/com/banno/cosmos4s/types/ItemResponse.scala +++ b/core/src/main/scala/com/banno/cosmos4s/types/ItemResponse.scala @@ -20,7 +20,7 @@ import cats.Traverse import cats.syntax.all._ import com.azure.cosmos.CosmosDiagnostics import com.azure.cosmos.models.CosmosItemResponse -import collection.JavaConverters._ +import scala.jdk.CollectionConverters._ import scala.concurrent.duration.FiniteDuration import java.util.concurrent.TimeUnit import cats.Applicative