Examples of InMemoryStateRepository


Examples of org.togglz.core.repository.mem.InMemoryStateRepository

        return ProxyFeatures.class;
    }

    @Override
    public StateRepository getStateRepository() {
        return new InMemoryStateRepository();
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

        return Features.class;
    }

    @Override
    public StateRepository getStateRepository() {
        return new InMemoryStateRepository();
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

    @ApplicationScoped
    public FeatureManager produce() {
        return new FeatureManagerBuilder()
            .featureEnum(Features.class)
            .userProvider(new NoOpUserProvider())
            .stateRepository(new InMemoryStateRepository())
            .name("I'm managed by CDI")
            .build();
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

        return GuiceFeatures.class;
    }

    @Override
    public StateRepository getStateRepository() {
        return new InMemoryStateRepository();
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

        return JspTaglibFeature.class;
    }

    @Override
    public StateRepository getStateRepository() {
        InMemoryStateRepository repository = new InMemoryStateRepository();
        repository.setFeatureState(new FeatureState(JspTaglibFeature.ACTIVE_FEATURE, true));
        repository.setFeatureState(new FeatureState(JspTaglibFeature.INACTIVE_FEATURE, false));
        return repository;
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

        return JSFFeatures.class;
    }

    @Override
    public StateRepository getStateRepository() {
        return new InMemoryStateRepository();
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

        return BasicFeatures.class;
    }

    @Override
    public StateRepository getStateRepository() {
        return new InMemoryStateRepository();
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

        return BasicFeatures.class;
    }

    @Override
    public StateRepository getStateRepository() {
        return new InMemoryStateRepository();
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

        return UserDependentFeature.class;
    }

    @Override
    public StateRepository getStateRepository() {
        InMemoryStateRepository repository = new InMemoryStateRepository();
        repository.setFeatureState(new FeatureState(UserDependentFeature.DISABLED, false));
        repository.setFeatureState(new FeatureState(UserDependentFeature.ENABLED_FOR_ALL, true));
        repository.setFeatureState(new FeatureState(UserDependentFeature.ENABLED_FOR_CK, true)
            .setStrategyId(UsernameActivationStrategy.ID)
            .setParameter(UsernameActivationStrategy.PARAM_USERS, "ck"));
        return repository;
    }
View Full Code Here

Examples of org.togglz.core.repository.mem.InMemoryStateRepository

     */
    @Before
    public void before() {
        FeatureManager featureManager = new FeatureManagerBuilder()
                .featureEnum(MyFeature.class)
                .stateRepository(new InMemoryStateRepository())
                .userProvider(new NoOpUserProvider())
                .build();
        ThreadLocalFeatureManagerProvider.bind(featureManager);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.