Package ch.entwine.weblounge.common.impl.content.page

Examples of ch.entwine.weblounge.common.impl.content.page.PageSecurityContext


    this.uri = uri;
    this.content = new HashMap<Language, T>();
    this.creationCtx = new CreationContext();
    this.modificationCtx = new ModificationContext();
    this.publishingCtx = new PublishingContext();
    this.securityCtx = new PageSecurityContext();
    this.subjects = new ArrayList<String>();
    this.series = new ArrayList<String>();
    this.title = new LocalizableContent<String>(this);
    this.description = new LocalizableContent<String>(this);
    this.coverage = new LocalizableContent<String>(this);
View Full Code Here


    // Initialize the weblounge admin
    // WebloungeAdminImpl.init("admin", "weblounge".getBytes(),
    // "admin@weblounge.org");

    // Create the security context
    SecurityContextImpl context = new PageSecurityContext();
    context.init(path, config);

    // Deny all
    context.allow(publish, editor);

    // Test (publish, editor) - expected: success
    if (!context.check(publish, editor)) {
      fail("Check for permission " + publish + " and role " + editor + " failed while it shouldn't");
    }
  }
View Full Code Here

TOP

Related Classes of ch.entwine.weblounge.common.impl.content.page.PageSecurityContext

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.