4 Replies Latest reply on Feb 8, 2008 11:59 AM by Norman Richards

    DocumentStore usage change - Urgent!!!

    Roberto Melo Cavalcante Newbie

      Hi folks,

      We are using Seam 2.0.1.CR1.
      We have to generate PDFs and put it into DocumentStore for latter use.
      I've found this bunch of code:

      String id = DocumentStore.instance().newId();
      DocumentData data = new DocumentData("manual.pdf",DocumentData.DocType.PDF, manualBytes);
      DocumentStore.instance().saveData(id, data);
      return DocumentStore.instance().preferredUrlForContent("manual.pdf", DocumentData.DocType.PDF, id);

      The problem is that DocumentData doen not have DocType inner class anymore and the actual inner class doesn't have a replacement constant for PDF's Doctype. So the code doesn't work anymore!

      Does anyone can provide an alternative to the code above for 2.0.1.CR1?

      any help you can give will be much appreciated!