Package com.baasbox.dao

Examples of com.baasbox.dao.FileDao.save()


      ODocument doc=dao.create(fileName,contentType,contentLength,is,metadata,contentString);
      if (data!=null && !data.trim().isEmpty()) {
        ODocument metaDoc=(new ODocument()).fromJSON("{ '"+DATA_FIELD_NAME+"' : " + data + "}");
        doc.merge(metaDoc, true, false);
      }
      dao.save(doc);
      return doc;
    }
   
    public static ODocument createFile(String fileName, String dataJson,
        String aclJsonString, String contentType, long length,
View Full Code Here


      ODocument doc=dao.create(fileName,contentType,contentLength,content);  
      if (data!=null && !data.trim().isEmpty()) {
        ODocument metaDoc=(new ODocument()).fromJSON("{ '"+DATA_FIELD_NAME+"' : " + data + "}");
        doc.merge(metaDoc, true, false);
      }
      dao.save(doc);
      return doc;
   
   
    public static ODocument createFile(String fileName,String data,String contentType, HashMap<String,?> metadata,long contentLength , InputStream content) throws Throwable{
      FileDao dao = FileDao.getInstance();
View Full Code Here

      ODocument doc=dao.create(fileName,contentType,contentLength,content);
      if (data!=null && !data.trim().isEmpty()) {
        ODocument metaDoc=(new ODocument()).fromJSON("{ '"+DATA_FIELD_NAME+"' : " + data + "}");
        doc.merge(metaDoc, true, false);
      }
      dao.save(doc);
      return doc;
    }
   
    public static ODocument getById(String id) throws SqlInjectionException, InvalidModelException {
      FileDao dao = FileDao.getInstance();
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.