Examples of fetchFile()


Examples of pt.webdetails.cpf.repository.api.IUserContentAccess.fetchFile()

      if( !access.fileExists(file) && access.hasAccess(file, FileAccess.READ)) {
        log.error("Access to Repository has failed File does not exist: " + file);
        throw new NullPointerException("Access to Repository has failed");
      }
      IBasicFile bf = access.fetchFile(file);

      String doc = IOUtils.toString(bf.getContents());
      if (doc == null) {
        throw new SaikuServiceException("Error retrieving saiku document from solution repository: " + file);
      }
View Full Code Here

Examples of pt.webdetails.cpf.repository.api.IUserContentAccess.fetchFile()

    };
    List<IBasicFile> files = new ArrayList<IBasicFile>();
    IUserContentAccess access = contentAccessFactory.getUserContentAccess(null);
        path = path.replace(":", "/");
    if (access.fileExists(path)) {
      IBasicFile bf = access.fetchFile(path);
      if (!bf.isDirectory()) {
        files.add(bf);
        log.debug("Found file in " + path);
      } else {
        files = root.listFiles(path, txtFilter, 0, true, hidden);
View Full Code Here

Examples of pt.webdetails.cpf.repository.api.IUserContentAccess.fetchFile()

        throw new InvalidCdfOperationException( "Access denied" );
      }

      try {

        Document doc = XmlDom4JUtils.getDocumentFromFile( access.fetchFile( dashboard ) );

        if ( doc.selectSingleNode( NODE_TEMPLATE ) != null ) {
          template = XmlDom4JUtils.getNodeText( NODE_TEMPLATE, doc, "" );
        }else{
          template = defaultTemplate;
View Full Code Here

Examples of pt.webdetails.cpf.repository.api.IUserContentAccess.fetchFile()

    if ( !StringUtils.isEmpty( templatePath ) && repoAccess.fileExists( templatePath ) ) {

      // Check for access permissions
      if ( repoAccess.hasAccess( templatePath, FileAccess.EXECUTE ) ) {
        dashboardTemplateFile = repoAccess.fetchFile( templatePath );
      } else {
        logger.error( "Access Denied to " + templatePath );
      }
    } else {
      dashboardTemplateFile = systemAccess.fetchFile( CdfConstants.DEFAULT_DASHBOARD_TEMPLATE_HTML );
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.