Package org.apache.lenya.ac

Examples of org.apache.lenya.ac.AccessController


        UsecaseMessage[] messages;

        ServiceSelector selector = null;
        AccessControllerResolver acResolver = null;
        AccessController accessController = null;
        UsecaseResolver usecaseResolver = null;
        UsecaseAuthorizer authorizer = null;
       
        String usecaseName = tab.getUsecase();
        if (usecaseName == null) {
            throw new IllegalArgumentException("The usecase name of the tab [" + tab.getName() + "] is null.");
        }
       
        try {

            selector = (ServiceSelector) this.manager.lookup(AccessControllerResolver.ROLE
                    + "Selector");
            acResolver = (AccessControllerResolver) selector.select(AccessControllerResolver.DEFAULT_RESOLVER);
            accessController = acResolver.resolveAccessController(this.webappUrl);

            Authorizer[] authorizers = accessController.getAuthorizers();
            for (int i = 0; i < authorizers.length; i++) {
                if (authorizers[i] instanceof UsecaseAuthorizer) {
                    authorizer = (UsecaseAuthorizer) authorizers[i];
                }
            }
View Full Code Here


            if (getLogger().isDebugEnabled()) {
                getLogger().debug("    Resolved AC resolver [" + this.acResolver + "]");
            }
            String webappUrl = ServletHelper.getWebappURI(request);
            AccessController accessController = this.acResolver.resolveAccessController(webappUrl);
            if (accessController instanceof DefaultAccessController) {
                DefaultAccessController defaultAccessController = (DefaultAccessController) accessController;
                this.accreditableManager = defaultAccessController.getAccreditableManager();
                Authorizer[] authorizers = defaultAccessController.getAuthorizers();
                for (int i = 0; i < authorizers.length; i++) {
View Full Code Here

            serviceSelector = (ServiceSelector) this.manager.lookup(AccessControllerResolver.ROLE
                    + "Selector");
            acResolver = (AccessControllerResolver) serviceSelector
                    .select(AccessControllerResolver.DEFAULT_RESOLVER);

            AccessController accessController = acResolver.resolveAccessController(canonicalUrl);
            if (accessController instanceof DefaultAccessController) {
                DefaultAccessController defaultAccessController = (DefaultAccessController) accessController;
                accreditableManager = defaultAccessController.getAccreditableManager();
                Authorizer[] authorizers = defaultAccessController.getAuthorizers();
                for (int i = 0; i < authorizers.length; i++) {
View Full Code Here

            if (getLogger().isDebugEnabled()) {
                getLogger().debug("    Resolved AC resolver [" + acResolver + "]");
            }

            String webappUrl = ServletHelper.getWebappURI(request);
            AccessController accessController = acResolver.resolveAccessController(webappUrl);

            if (accessController instanceof DefaultAccessController) {
                DefaultAccessController defaultAccessController =
                    (DefaultAccessController) accessController;
View Full Code Here

                (AccessControllerResolver) selector.select(
                    AccessControllerResolver.DEFAULT_RESOLVER);
            getLogger().debug("Resolved AC resolver [" + acResolver + "]");

            String webappUrl = ServletHelper.getWebappURI(request);
            AccessController accessController = acResolver.resolveAccessController(webappUrl);

            if (accessController instanceof DefaultAccessController) {
                DefaultAccessController defaultAccessController =
                    (DefaultAccessController) accessController;
                Authorizer[] authorizers = defaultAccessController.getAuthorizers();
View Full Code Here

    /**
     * @see org.apache.lenya.cms.ac2.AbstractAccessControllerResolver#doResolveAccessController(java.lang.String)
     */
    public AccessController doResolveAccessController(String webappUrl)
        throws AccessControlException {
        AccessController accessController = null;

        try {
            accessController =
                (AccessController) getManager().lookup(
                    AccessController.ROLE + "/" + accessControllerType);
View Full Code Here

    /**
     * @see org.apache.lenya.cms.ac2.AbstractAccessControllerResolver#doResolveAccessController(java.lang.String)
     */
    public AccessController doResolveAccessController(String url) throws AccessControlException {

        AccessController controller = null;

        try {
           
            if (selector == null) {
                selector =
View Full Code Here

     */
    public AccessController resolveAccessController(String webappUrl)
        throws AccessControlException {

        SourceResolver resolver = null;
        AccessController controller = null;
        Object key = null;

        try {
            resolver = (SourceResolver) getManager().lookup(SourceResolver.ROLE);
            key = generateCacheKey(webappUrl, resolver);
View Full Code Here

     * @return An item manager.
     * @throws ConfigurationException when something went wrong.
     */
    protected ItemManager getItemManager(Request request, String name)
        throws ConfigurationException {
        AccessController accessController = null;
        ServiceSelector selector = null;
        AccessControllerResolver resolver = null;
        ItemManager itemManager = null;

        try {
View Full Code Here

                    AccessControllerResolver.DEFAULT_RESOLVER);

                getLogger().debug("    Resolved AC resolver [" + acResolver + "]");

            String webappUrl = ServletHelper.getWebappURI(request);
            AccessController accessController = acResolver.resolveAccessController(webappUrl);

            if (accessController instanceof DefaultAccessController) {
                DefaultAccessController defaultAccessController =
                    (DefaultAccessController) accessController;
View Full Code Here

TOP

Related Classes of org.apache.lenya.ac.AccessController

Copyright © 2018 www.massapicom. 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.