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

kreuzberg.HeadlessComponent.scala Maven / Gradle / Ivy

There is a newer version: 0.10.3
Show newest version
package kreuzberg

/**
 * A Headless is like a component, but without an HTML-Representation. However it can define EventHandlers and
 * Subscriptions.
 */
trait HeadlessComponent extends Identified {
  final val id: Identifier = Identifier.next()

  def assemble(using context: AssemblerContext): HeadlessAssembly
}

/** Assembled service. */
case class HeadlessAssembly(
    handlers: Vector[EventBinding] = Vector.empty,
    subscriptions: Vector[Subscribeable[_]] = Vector.empty,
    children: Vector[HeadlessComponent] = Vector.empty
)

/** Base trait for services. */
trait HeadlessComponentBase extends HeadlessComponent with ContextDsl




© 2015 - 2025 Weber Informatics LLC | Privacy Policy