Package edu.umbc.ultra.logic

Examples of edu.umbc.ultra.logic.Comment


    ArrayList<Comment> comments = new ArrayList<Comment>();

    // Iterate over the results from the query
    for (Entity result : pq.asIterable()) {
      User author = RightsManagementController.getInstance().getUser(result.getProperty("Author").toString());
      Comment comment = new Comment(result.getProperty("Text").toString(),
                    (Date) result.getProperty("Timestamp"),
                    author, result.getProperty("Title").toString());
      comments.add(comment);
    }
View Full Code Here


    UserService userService = UserServiceFactory.getUserService();
    String userEmail = userService.getCurrentUser().getEmail();
    RightsManagementController rightsController = RightsManagementController
        .getInstance();
    User user = rightsController.getUser(userEmail);
    Comment newc = new Comment(req.getParameter("newcomment"), user, "Later Interpretation");
    ArrayList<Comment> comList = new ArrayList<Comment>();
    comList.add(newc);
    UploadComments(KeyFactory.stringToKey(req.getParameter("entry")), comList);
    res.sendRedirect("/viewrecord?entry=" + req.getParameter("entry"));
  }
View Full Code Here

        || (req.getParameter("complaint").length() == 0)) {
      redirect(res, blobKey);
      return;
    }
    else {
      comments.add(new Comment(req.getParameter("complaint"), user, "Complaint"));
    }

    // Makes sure there is a value in reason.
    if ((req.getParameter("reason") == null)
        || (req.getParameter("reason").length() == 0)) {
      redirect(res, blobKey);
      return;
    }
    else {
      comments.add(new Comment(req.getParameter("reason"), user, "Reason"));
    }
    String rInterp = req.getParameter("resInterp");
    String aInterp = req.getParameter("attendInterp");

    // Tests to make sure that there is an entry in the Resident or
    // Attending physician's interpretation textarea.
    if (((aInterp == null) || (aInterp.length() == 0))
        && ((rInterp == null) || (rInterp.length() == 0))) {
      redirect(res, blobKey);
      return;
    }
    else if ((aInterp == null) || (aInterp.length() == 0)) {
      aInterp = "No Attending Physician interpretation.";
    }
    else if ((rInterp == null) || (rInterp.length() == 0)) {
      rInterp = "No Resident Physician interpretation.";
    }

    comments.add(new Comment(rInterp, user, "Attending Physician interpretation."));
    comments.add(new Comment(aInterp, user, "Resident Physician interpretation."));
    DataEntry data = new DataEntry(comments, patient, user, blobKey, null);
    UploadEntry(data);
    res.sendRedirect("/viewrecord?entry=" + data.getKey());
  }
View Full Code Here

TOP

Related Classes of edu.umbc.ultra.logic.Comment

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.