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

com.github.dynamicextensionsalfresco.osgi.BundleExtensions.kt Maven / Gradle / Ivy

Go to download

Adds an OSGi container to alfresco repository supporting dynamic code reloading, classpath isolation and a bunch of other useful features

There is a newer version: 3.1.0
Show newest version
package com.github.dynamicextensionsalfresco.osgi

import com.springsource.util.osgi.manifest.BundleManifest
import com.springsource.util.osgi.manifest.BundleManifestFactory
import org.osgi.framework.Bundle
import kotlin.properties.Delegates

val Bundle.stateDescription: String
    get() = when (this.state) {
    Bundle.UNINSTALLED -> "uninstalled"
    Bundle.INSTALLED -> "installed"
    Bundle.RESOLVED -> "resolved"
    Bundle.STARTING -> "starting"
    Bundle.STOPPING -> "stopping"
    Bundle.ACTIVE -> "active"
    else -> "unknown"
}

val Bundle.isActive: Boolean
    get() = state == Bundle.ACTIVE

val Bundle.manifest: BundleManifest
    get() = BundleManifestFactory.createBundleManifest(headers)




© 2015 - 2025 Weber Informatics LLC | Privacy Policy