For IntelliJ IDEA and
Android Studio


object BiDictionary { /** * Append new keys to an existing BiDictionary and return the result. The values will start * at m.size and increase to create a continuous non-zero value set from 0 to size - 1 * @param keys new keys to append, not checked for uniqueness so may be dangerous * @param biDi merge keys to this BiDictionary and create new values buy incremeting from the highest Int value * @return a BiDictionary with added mappings */ /*def append(keys: Seq[String], biDi: BiDictionary): BiDictionary = { val hm = HashMap(keys.view.zip (Stream from biDi.size): _*) new BiDictionary(biDi.m ++ hm) }*/ }
final case class ProductNode(children: ConstArray[Node]) extends SimplyTypedNode { type Self = ProductNode override def getDumpInfo = super.getDumpInfo.copy(name = "ProductNode", mainInfo = "") protected[this] def rebuild(ch: ConstArray[Node]): Self = copy(ch) override def childNames: Iterable[String] = Stream.from(1).map(_.toString) protected def buildType: Type = ProductType(children.map { ch => val t = ch.nodeType if(t == UnassignedType) throw new SlickException(s"ProductNode child $ch has UnassignedType") t }) def flatten: ProductNode = { def f(n: Node): ConstArray[Node] = n match { case ProductNode(ns) => ns.flatMap(f) case StructNode(els) => els.flatMap(el => f(el._2)) case n => ConstArray(n) } ProductNode(f(this)) } }
def childNames: Iterable[String] = Stream.from(0).map(_.toString)
val serverNodes = ic.ignite().cluster().forCacheNodes(cacheName).forServers().nodes() Array(IgniteDataFramePartition(0, serverNodes.head, Stream.from(0).take(1024).toList))
val aff = ic.ignite().affinity[IgniteUuid](cacheName) Stream.from(1, Math.max(1000, aff.partitions() * 2)) .map(_ ⇒ IgniteUuid.randomUuid()).find(node == null || aff.mapKeyToNode(_).eq(node)) .getOrElse(IgniteUuid.randomUuid())