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

blended.container.context.internal.ContainerIdentifierServiceImpl.scala Maven / Gradle / Ivy

There is a newer version: 2.4.0-RC4
Show newest version
package blended.container.context.internal

import blended.container.context.ContainerIdentifierService
import blended.container.context.ContainerContext
import java.util.Properties

object ContainerIdentifierServiceImpl {

  val PROP_UUID = "UUID"
  val PROP_PROPERTY = "property."

}

class ContainerIdentifierServiceImpl(containerContext: ContainerContext, uuid: String, props: Map[String, String])
    extends ContainerIdentifierService {

  override def getContainerContext(): ContainerContext = containerContext

  override def getUUID(): String = uuid

  override def getProperties(): Properties = {
    // always create a new Properties, as it is mutable
    val export = new Properties()
    props.foreach {
      case (k, v) =>
        export.setProperty(k, v)
    }
    export
  }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy