com.github.dynamicextensionsalfresco.quartz.GenericQuartzJob.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of annotations-runtime Show documentation
Show all versions of annotations-runtime Show documentation
Adds an OSGi container to alfresco repository supporting dynamic code reloading, classpath isolation and a bunch of other useful features
package com.github.dynamicextensionsalfresco.quartz
import org.quartz.Job
import org.quartz.JobExecutionContext
import org.quartz.JobExecutionException
/**
* Quartz requires a Job class, not an instance, so we use this generic delegate.
* @author Laurent Van der Linden
*/
public class GenericQuartzJob : Job {
@Throws(JobExecutionException::class)
override fun execute(jobExecutionContext: JobExecutionContext) {
val lockedJob = jobExecutionContext.jobDetail.jobDataMap.get(BEAN_ID) as Job
lockedJob.execute(jobExecutionContext)
}
companion object {
public val BEAN_ID: String = "bean"
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy