Package org.pentaho.platform.engine.security

Examples of org.pentaho.platform.engine.security.SecurityParameterProvider


    parameterProviders = new HashMap<String, IParameterProvider>();
    this.session = pSession;
    this.setParameterProvider( SolutionEngine.JVM_PARAMETER_PROVIDER, new JVMParameterProvider() );
    setForcePrompt( false );
    // Provide the security parameter provider to the parameter provider map in the super class
    SecurityParameterProvider provider = new SecurityParameterProvider( pSession );
    this.setParameterProvider( SecurityParameterProvider.SCOPE_SECURITY, provider );
  }
View Full Code Here


  private void processComments( final IParameterProvider params, final OutputStream out ) throws JSONException {

    JSONObject result = null;

    SecurityParameterProvider securityParams = new SecurityParameterProvider( userSession );
    boolean isAdministrator = Boolean.valueOf( (String) securityParams.getParameter( "principalAdministrator" ) );
    boolean isAuthenticated = userSession.isAuthenticated();

    try {
      final CommentsEngine engine = CommentsEngine.getInstance();
View Full Code Here

      contextObj.put( "user", getUserSession().getName() );
      contextObj.put( "locale", CdfEngine.getEnvironment().getLocale() );

      buildContextPaths( contextObj, path, parameters );

      SecurityParameterProvider securityParams = new SecurityParameterProvider( getUserSession() );
      contextObj.put( "roles", securityParams.getParameter( "principalRoles" ) );

      if ( APPLY_LEGACY_DASHBOARD_CONTEXT ) {
        buildLegacyStructure( contextObj, path, securityParams );
      }
View Full Code Here

  public IRWAccess getWriter() {
    return this.writer;
  }

  protected boolean isAdmin() {
    SecurityParameterProvider securityParams = new SecurityParameterProvider( PentahoSessionHolder.getSession() );
    return securityParams.getParameter( "principalAdministrator" ).equals( "true" );
  }
View Full Code Here

   * checks is the current user is administrator
   *
   * @return true if the current user is administrator, false otherwise
   */
  protected boolean isAdministrator() {
    SecurityParameterProvider securityParams = new SecurityParameterProvider( userSession );
    return Boolean.valueOf( (String) securityParams.getParameter( "principalAdministrator" ) );
  }
View Full Code Here

TOP

Related Classes of org.pentaho.platform.engine.security.SecurityParameterProvider

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.