HTMLRenderedCacheImpl.java 7.02 KB
/*
 * Decompiled with CFR 0_118.
 * 
 * Could not load the following classes:
 *  org.apache.felix.scr.annotations.Activate
 *  org.apache.felix.scr.annotations.Component
 *  org.apache.felix.scr.annotations.Reference
 *  org.apache.felix.scr.annotations.ReferencePolicy
 *  org.apache.felix.scr.annotations.Service
 *  org.slf4j.Logger
 *  scala.Function1
 *  scala.Option
 *  scala.ScalaObject
 *  scala.reflect.ScalaSignature
 */
package com.adobe.forms.cache.impl;

import com.adobe.forms.cache.CacheStore;
import com.adobe.forms.cache.CacheStoreProvider;
import com.adobe.forms.cache.CacheStrategy;
import com.adobe.forms.cache.CacheStrategy$;
import com.adobe.forms.cache.CacheStrategyAggressive$;
import com.adobe.forms.cache.Cacheable;
import com.adobe.forms.cache.HTMLRenderedCache;
import com.adobe.forms.cache.LCFormsCacheConfig;
import com.adobe.forms.cache.ResourceCache;
import com.adobe.forms.cache.ResourceCache$class;
import java.util.Set;
import org.apache.felix.scr.annotations.Activate;
import org.apache.felix.scr.annotations.Component;
import org.apache.felix.scr.annotations.Reference;
import org.apache.felix.scr.annotations.ReferencePolicy;
import org.apache.felix.scr.annotations.Service;
import org.slf4j.Logger;
import scala.Function1;
import scala.Option;
import scala.ScalaObject;
import scala.reflect.ScalaSignature;

/*
 * This class specifies class file version 49.0 but uses Java 6 signatures.  Assumed Java 6.
 */
@Component(immediate=1)
@Service(value={HTMLRenderedCache.class})
@ScalaSignature(bytes="\u0006\u0001\u0005\u001da\u0001B\u0001\u0003\u00015\u0011Q\u0003\u0013+N\u0019J+g\u000eZ3sK\u0012\u001c\u0015m\u00195f\u00136\u0004HN\u0003\u0002\u0004\t\u0005!\u0011.\u001c9m\u0015\t)a!A\u0003dC\u000eDWM\u0003\u0002\b\u0011\u0005)am\u001c:ng*\u0011\u0011BC\u0001\u0006C\u0012|'-\u001a\u0006\u0002\u0017\u0005\u00191m\\7\u0004\u0001M!\u0001A\u0004\f\u001b!\tyA#D\u0001\u0011\u0015\t\t\"#\u0001\u0003mC:<'\"A\n\u0002\t)\fg/Y\u0005\u0003+A\u0011aa\u00142kK\u000e$\bCA\f\u0019\u001b\u0005!\u0011BA\r\u0005\u0005EAE+\u0014'SK:$WM]3e\u0007\u0006\u001c\u0007.\u001a\t\u00037yi\u0011\u0001\b\u0006\u0002;\u0005)1oY1mC&\u0011q\u0004\b\u0002\f'\u000e\fG.Y(cU\u0016\u001cG\u000fC\u0003\"\u0001\u0011\u0005!%\u0001\u0004=S:LGO\u0010\u000b\u0002GA\u0011A\u0005A\u0007\u0002\u0005!9a\u0005\u0001a\u0001\n#9\u0013AB0ti>\u0014X-F\u0001)!\t9\u0012&\u0003\u0002+\t\tQ1)Y2iKN#xN]3\t\u000f1\u0002\u0001\u0019!C\t[\u0005Qql\u001d;pe\u0016|F%Z9\u0015\u00059\n\u0004CA\u000e0\u0013\t\u0001DD\u0001\u0003V]&$\bb\u0002\u001a,\u0003\u0003\u0005\r\u0001K\u0001\u0004q\u0012\n\u0004B\u0002\u001b\u0001A\u0003&\u0001&A\u0004`gR|'/\u001a\u0011\t\u000fY\u0002\u0001\u0019!C\u0001o\u0005\u00112-Y2iKN#xN]3Qe>4\u0018\u000eZ3s+\u0005A\u0004CA\f:\u0013\tQDA\u0001\nDC\u000eDWm\u0015;pe\u0016\u0004&o\u001c<jI\u0016\u0014\bb\u0002\u001f\u0001\u0001\u0004%\t!P\u0001\u0017G\u0006\u001c\u0007.Z*u_J,\u0007K]8wS\u0012,'o\u0018\u0013fcR\u0011aF\u0010\u0005\bem\n\t\u00111\u00019\u0011\u0019\u0001\u0005\u0001)Q\u0005q\u0005\u00192-Y2iKN#xN]3Qe>4\u0018\u000eZ3sA!\"qH\u0011)R!\t\u0019e*D\u0001E\u0015\t)e)A\u0006b]:|G/\u0019;j_:\u001c(BA$I\u0003\r\u00198M\u001d\u0006\u0003\u0013*\u000bQAZ3mSbT!a\u0013'\u0002\r\u0005\u0004\u0018m\u00195f\u0015\u0005i\u0015aA8sO&\u0011q\n\u0012\u0002\n%\u00164WM]3oG\u0016\fa\u0001]8mS\u000eLH%\u0001*\n\u0005M#\u0016a\u0002#Z\u001d\u0006k\u0015j\u0011\u0006\u0003+\u0012\u000bqBU3gKJ,gnY3Q_2L7-\u001f\u0005\b/\u0002\u0001\r\u0011\"\u0001Y\u0003Ia7MR8s[N\u001c\u0015m\u00195f\u0007>tg-[4\u0016\u0003e\u0003\"a\u0006.\n\u0005m#!A\u0005'D\r>\u0014Xn]\"bG\",7i\u001c8gS\u001eDq!\u0018\u0001A\u0002\u0013\u0005a,\u0001\fmG\u001a{'/\\:DC\u000eDWmQ8oM&<w\fJ3r)\tqs\fC\u000439\u0006\u0005\t\u0019A-\t\r\u0005\u0004\u0001\u0015)\u0003Z\u0003Ma7MR8s[N\u001c\u0015m\u00195f\u0007>tg-[4!Q\u0011\u0001'\tU)\t\u000b\u0011\u0004A\u0011A3\u0002\u0011\u0005\u001cG/\u001b<bi\u0016$\u0012A\f\u0015\u0003G\u001e\u0004\"a\u00115\n\u0005%$%\u0001C!di&4\u0018\r^3\t\u000b-\u0004A\u0011\u00037\u0002\u0013%\u001cXI\\1cY\u0016$W#A7\u0011\u0005mq\u0017BA8\u001d\u0005\u001d\u0011un\u001c7fC:DQ!\u001d\u0001\u0005\u0012I\f\u0011bY1dQ\u0016t\u0015-\\3\u0016\u0003M\u0004\"a\u0004;\n\u0005U\u0004\"AB*ue&tw\r\u000b\u0003\u0001oj\\\bCA\"y\u0013\tIHIA\u0004TKJ4\u0018nY3\u0002\u000bY\fG.^3-\u0003q\u001c\u0013A\u0006\u0015\u0007\u0001y\f\u0019!!\u0002\u0011\u0005\r{\u0018bAA\u0001\t\nI1i\\7q_:,g\u000e^\u0001\nS6lW\rZ5bi\u0016L\u0012!\u0001")
public class HTMLRenderedCacheImpl
implements HTMLRenderedCache,
ScalaObject {
    private CacheStore _store;
    @Reference(policy=ReferencePolicy.DYNAMIC)
    private CacheStoreProvider cacheStoreProvider;
    @Reference(policy=ReferencePolicy.DYNAMIC)
    private LCFormsCacheConfig lcFormsCacheConfig;
    private Logger logger;

    @Override
    public CacheStore _store() {
        return this._store;
    }

    public void _store_$eq(CacheStore cacheStore) {
        this._store = cacheStore;
    }

    public CacheStoreProvider cacheStoreProvider() {
        return this.cacheStoreProvider;
    }

    public void cacheStoreProvider_$eq(CacheStoreProvider cacheStoreProvider) {
        this.cacheStoreProvider = cacheStoreProvider;
    }

    @Override
    public LCFormsCacheConfig lcFormsCacheConfig() {
        return this.lcFormsCacheConfig;
    }

    public void lcFormsCacheConfig_$eq(LCFormsCacheConfig lCFormsCacheConfig) {
        this.lcFormsCacheConfig = lCFormsCacheConfig;
    }

    @Activate
    public void activate() {
        this._store_$eq(this.cacheStoreProvider().create(this.cacheName(), this.cacheSize()));
    }

    /*
     * Enabled force condition propagation
     * Lifted jumps to return sites
     */
    @Override
    public boolean isEnabled() {
        CacheStrategy cacheStrategy = CacheStrategy$.MODULE$.apply(this.lcFormsCacheConfig().getCacheStrategy());
        CacheStrategyAggressive$ cacheStrategyAggressive$ = CacheStrategyAggressive$.MODULE$;
        if (cacheStrategy != null) {
            if (!cacheStrategy.equals(cacheStrategyAggressive$)) return false;
            return true;
        }
        if (cacheStrategyAggressive$ == null) return true;
        return false;
    }

    @Override
    public String cacheName() {
        return "com_adobe_forms_HTML_RENDERED_CACHE";
    }

    public HTMLRenderedCacheImpl() {
        ResourceCache$class.$init$(this);
        this._store = null;
        this.cacheStoreProvider = null;
        this.lcFormsCacheConfig = null;
    }

    protected void bindCacheStoreProvider(CacheStoreProvider cacheStoreProvider) {
        this.cacheStoreProvider = cacheStoreProvider;
    }

    protected void unbindCacheStoreProvider(CacheStoreProvider cacheStoreProvider) {
        if (this.cacheStoreProvider == cacheStoreProvider) {
            this.cacheStoreProvider = null;
        }
    }

    protected void bindLcFormsCacheConfig(LCFormsCacheConfig lCFormsCacheConfig) {
        this.lcFormsCacheConfig = lCFormsCacheConfig;
    }

    protected void unbindLcFormsCacheConfig(LCFormsCacheConfig lCFormsCacheConfig) {
        if (this.lcFormsCacheConfig == lCFormsCacheConfig) {
            this.lcFormsCacheConfig = null;
        }
    }
}