All Downloads are FREE. Search and download functionalities are using the official Maven repository.

jove.notebook.components.Cluster.scala Maven / Gradle / Ivy

The newest version!
package jove.notebook.components

class Cluster {
  private val _clustersLock = new AnyRef
  private var _clusters = Map.empty[String, jove.Cluster]

  def addCluster(id: String, cluster: jove.Cluster): Unit =
    _clustersLock.synchronized {
      _clusters += id -> cluster
    }

  def clusters: Map[String, jove.Cluster] =
    _clustersLock.synchronized(_clusters)
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy