M - Type used for the Edmx modelpublic class MetaDataAccessorImpl<M> extends Object implements MetaDataAccessor<M>
| Modifier and Type | Class and Description |
|---|---|
static interface |
MetaDataAccessorImpl.EdmxModelCreator<M> |
| Constructor and Description |
|---|
MetaDataAccessorImpl(SidecarAccess sidecarAccess,
CacheParams cacheParams,
MetaDataAccessorImpl.EdmxModelCreator<M> strToEdmx,
com.google.common.base.Ticker cacheTicker) |
| Modifier and Type | Method and Description |
|---|---|
void |
evict(String tenantId) |
CdsModel |
getCdsModel(ModelId key,
int maxAgeSeconds) |
M |
getEdmx(ModelId key,
int maxAgeSeconds) |
void |
refresh(String tenantId,
int maxAgeSeconds) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetCdsModel, getEdmx, refreshpublic MetaDataAccessorImpl(SidecarAccess sidecarAccess, CacheParams cacheParams, MetaDataAccessorImpl.EdmxModelCreator<M> strToEdmx, com.google.common.base.Ticker cacheTicker)
sidecarAccess - Object of type SidecarAccessthat provides access
to the node.js application sidecar/mtx via a rest APIcacheParams - Parameters that control size and lifecycle of cache for
cds and edmx modelsstrToEdmx - Function that converts an edmx model description given
as string into an edmx modelcacheTicker - Optional ticker used by guava cache for testing
purposes, use null for productive usepublic CdsModel getCdsModel(ModelId key, int maxAgeSeconds)
getCdsModel in interface MetaDataAccessor<M>public M getEdmx(ModelId key, int maxAgeSeconds) throws CdsException
getEdmx in interface MetaDataAccessor<M>CdsExceptionpublic void evict(String tenantId)
evict in interface MetaDataAccessor<M>public void refresh(String tenantId, int maxAgeSeconds)
refresh in interface MetaDataAccessor<M>Copyright © 2021 SAP. All rights reserved.