@Service public class ResourceModelCaches extends Object
resource model cache services.
caches.| Constructor and Description |
|---|
ResourceModelCaches() |
| Modifier and Type | Method and Description |
|---|---|
void |
add(io.neba.api.resourcemodels.ResourceModelCache cache) |
<T> T |
lookup(Key key)
Looks up the
cached model
of the given type for the given resource. |
void |
remove(io.neba.api.resourcemodels.ResourceModelCache cache) |
<T> void |
store(org.apache.sling.api.resource.Resource resource,
T model,
Key key)
Stores the model representing the result of the
adaptation of the given resource
to the given target type. |
public <T> T lookup(Key key)
cached model
of the given type for the given resource.
Returns the first model found in the caches.key - must not be null.null.public <T> void store(org.apache.sling.api.resource.Resource resource,
T model,
Key key)
adaptation of the given resource
to the given target type.resource - must not be null.model - can be null.key - must not be null.public void add(io.neba.api.resourcemodels.ResourceModelCache cache)
public void remove(io.neba.api.resourcemodels.ResourceModelCache cache)
Copyright © 2014–2015. All rights reserved.