@Service(value=org.osgi.service.event.EventHandler.class)
@Property(name="event.topics",
value={"org/liveSense/thumbnail/generate","org/liveSense/thumbnail/remove"})
public class ThumbnailGeneratorJobEventHandler
extends Object
implements org.apache.sling.event.jobs.JobProcessor, org.osgi.service.event.EventHandler
| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_THUMBNAIL_FOLDER |
static String[] |
DEFAULT_THUMBNAIL_RESOLUTIONS |
static String |
PARAM_THUMBNAIL_FOLDER |
static String |
PARAM_THUMBNAIL_RESOLUTIONS |
static String |
THUMBNAIL_RESOLUTION_100_0 |
static String |
THUMBNAIL_RESOLUTION_200_0 |
static String |
THUMBNAIL_RESOLUTION_50_0 |
| Constructor and Description |
|---|
ThumbnailGeneratorJobEventHandler() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
activate(org.osgi.service.component.ComponentContext componentContext)
Activates this component.
|
boolean |
createThumbnailsForImage(org.apache.sling.api.resource.Resource resource) |
void |
deleteThumbnailsForImage(javax.jcr.Session session,
String resourcePath) |
void |
handleEvent(org.osgi.service.event.Event event) |
boolean |
process(org.osgi.service.event.Event event) |
public static final String PARAM_THUMBNAIL_RESOLUTIONS
public static final String THUMBNAIL_RESOLUTION_50_0
public static final String THUMBNAIL_RESOLUTION_100_0
public static final String THUMBNAIL_RESOLUTION_200_0
public static final String[] DEFAULT_THUMBNAIL_RESOLUTIONS
public static final String PARAM_THUMBNAIL_FOLDER
public static final String DEFAULT_THUMBNAIL_FOLDER
protected void activate(org.osgi.service.component.ComponentContext componentContext)
throws javax.jcr.RepositoryException
componentContext - The OSGi ComponentContext of this component.javax.jcr.RepositoryExceptionpublic void handleEvent(org.osgi.service.event.Event event)
handleEvent in interface org.osgi.service.event.EventHandlerpublic boolean process(org.osgi.service.event.Event event)
process in interface org.apache.sling.event.jobs.JobProcessorpublic boolean createThumbnailsForImage(org.apache.sling.api.resource.Resource resource)
throws javax.jcr.RepositoryException,
Exception
javax.jcr.RepositoryExceptionExceptionCopyright © 2010–2014 liveSense.org. All rights reserved.