org.sakaiproject.entity.api.EntityManager.newReferenceList()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(7.6k)|赞(0)|评价(0)|浏览(136)

本文整理了Java中org.sakaiproject.entity.api.EntityManager.newReferenceList()方法的一些代码示例,展示了EntityManager.newReferenceList()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。EntityManager.newReferenceList()方法的具体详情如下:
包路径:org.sakaiproject.entity.api.EntityManager
类名称:EntityManager
方法名:newReferenceList

EntityManager.newReferenceList介绍

[英]Create a new List specially designed to hold References.
[中]创建一个专为保存引用而设计的新列表。

代码示例

代码示例来源:origin: sakaiproject/sakai

  1. /**
  2. * Access the attachments of the event.
  3. *
  4. * @return An copy of the set of attachments (a ReferenceVector containing Reference objects) (may be empty).
  5. */
  6. public List getAttachments()
  7. {
  8. return m_entityManager.newReferenceList(m_attachments);
  9. } // getAttachments

代码示例来源:origin: org.sakaiproject.message/sakai-message-util

  1. /**
  2. * Access the attachments of the event.
  3. *
  4. * @return An copy of the set of attachments (a ReferenceVector containing Reference objects) (may be empty).
  5. */
  6. public List getAttachments()
  7. {
  8. return m_entityManager.newReferenceList(m_attachments);
  9. } // getAttachments

代码示例来源:origin: org.sakaiproject.message/sakai-message-impl

  1. /**
  2. * Access the attachments of the event.
  3. *
  4. * @return An copy of the set of attachments (a ReferenceVector containing Reference objects) (may be empty).
  5. */
  6. public List getAttachments()
  7. {
  8. return m_entityManager.newReferenceList(m_attachments);
  9. } // getAttachments

代码示例来源:origin: org.sakaiproject.kernel/sakai-kernel-api

  1. public static java.util.List newReferenceList()
  2. {
  3. org.sakaiproject.entity.api.EntityManager service = getInstance();
  4. if (service == null) return null;
  5. return service.newReferenceList();
  6. }

代码示例来源:origin: sakaiproject/sakai

  1. public static java.util.List newReferenceList(java.util.List param0)
  2. {
  3. org.sakaiproject.entity.api.EntityManager service = getInstance();
  4. if (service == null) return null;
  5. return service.newReferenceList(param0);
  6. }

代码示例来源:origin: sakaiproject/sakai

  1. public static java.util.List newReferenceList()
  2. {
  3. org.sakaiproject.entity.api.EntityManager service = getInstance();
  4. if (service == null) return null;
  5. return service.newReferenceList();
  6. }

代码示例来源:origin: org.sakaiproject.kernel/sakai-kernel-api

  1. public static java.util.List newReferenceList(java.util.List param0)
  2. {
  3. org.sakaiproject.entity.api.EntityManager service = getInstance();
  4. if (service == null) return null;
  5. return service.newReferenceList(param0);
  6. }

代码示例来源:origin: org.sakaiproject.assignment/sakai-assignment-impl

  1. m_submissionLog = new ArrayList();
  2. m_grades = new ArrayList();
  3. m_feedbackAttachments = m_entityManager.newReferenceList();
  4. m_submittedAttachments = m_entityManager.newReferenceList();
  5. m_submitted = false;
  6. m_returned = false;

代码示例来源:origin: sakaiproject/sakai

  1. m_attachments = m_entityManager.newReferenceList();

代码示例来源:origin: org.sakaiproject.message/sakai-message-impl

  1. m_attachments = m_entityManager.newReferenceList();

代码示例来源:origin: org.sakaiproject.message/sakai-message-util

  1. m_attachments = m_entityManager.newReferenceList();

代码示例来源:origin: org.sakaiproject.assignment/sakai-assignment-impl

  1. /**
  2. * Handle legacy submissions with no 'isUserSubmission' attribute gracefully.
  3. * You must ensure that both m_submittedText and m_sumbittedAttachments have
  4. * been set prior to calling this method. If they are not set, this algorithm
  5. * will likely return false negatives.
  6. *
  7. * @see SAK-30644
  8. */
  9. private void getIsUserSubmission( String isUserSubmission )
  10. {
  11. if( StringUtils.isBlank( isUserSubmission ) )
  12. {
  13. // Initialize the list if it's null, to avoid NPE's in check below
  14. if( m_submittedAttachments == null )
  15. {
  16. m_submittedAttachments = m_entityManager.newReferenceList();
  17. }
  18. // If there is submitted text, attachments, or if the type is 'non-electronic', this is considered an actual user submission
  19. m_isUserSubmission = StringUtils.isNotBlank( m_submittedText ) ||
  20. getAssignment().getContent().getTypeOfSubmission() == Assignment.NON_ELECTRONIC_ASSIGNMENT_SUBMISSION ||
  21. !m_submittedAttachments.isEmpty();
  22. }
  23. else
  24. {
  25. m_isUserSubmission = getBool( isUserSubmission );
  26. }
  27. }

代码示例来源:origin: org.sakaiproject.assignment/sakai-assignment-impl

  1. /**
  2. * Constructor used in addAssignmentContent.
  3. */
  4. public BaseAssignmentContent(String id, String context)
  5. {
  6. m_id = id;
  7. m_context = context;
  8. m_properties = new BaseResourcePropertiesEdit();
  9. addLiveProperties(m_properties);
  10. m_authors = new ArrayList();
  11. m_attachments = m_entityManager.newReferenceList();
  12. m_title = "";
  13. m_instructions = "";
  14. m_honorPledge = Assignment.HONOR_PLEDGE_NOT_SET;
  15. m_typeOfSubmission = Assignment.ASSIGNMENT_SUBMISSION_TYPE_NOT_SET;
  16. m_typeOfGrade = Assignment.GRADE_TYPE_NOT_SET;
  17. m_maxGradePoint = 0;
  18. m_factor = getScaleFactor();
  19. m_timeCreated = TimeService.newTime();
  20. m_timeLastModified = TimeService.newTime();
  21. }

代码示例来源:origin: sakaiproject/sakai

  1. /**
  2. * Construct. Time and From set automatically.
  3. *
  4. * @param id
  5. * The message id.
  6. */
  7. public BaseMessageHeaderEdit(Message msg, String id)
  8. {
  9. m_message = msg;
  10. m_id = id;
  11. m_message_order=0;
  12. m_date = m_timeService.newTime();
  13. try
  14. {
  15. m_from = m_userDirectoryService.getUser(m_sessionManager.getCurrentSessionUserId());
  16. }
  17. catch (UserNotDefinedException e)
  18. {
  19. m_from = m_userDirectoryService.getAnonymousUser();
  20. }
  21. // init the AttachmentContainer
  22. m_attachments = m_entityManager.newReferenceList();
  23. } // BaseMessageHeaderEdit

代码示例来源:origin: org.sakaiproject.message/sakai-message-impl

  1. /**
  2. * Construct. Time and From set automatically.
  3. *
  4. * @param id
  5. * The message id.
  6. */
  7. public BaseMessageHeaderEdit(Message msg, String id)
  8. {
  9. m_message = msg;
  10. m_id = id;
  11. m_message_order=0;
  12. m_date = m_timeService.newTime();
  13. try
  14. {
  15. m_from = m_userDirectoryService.getUser(m_sessionManager.getCurrentSessionUserId());
  16. }
  17. catch (UserNotDefinedException e)
  18. {
  19. m_from = m_userDirectoryService.getAnonymousUser();
  20. }
  21. // init the AttachmentContainer
  22. m_attachments = m_entityManager.newReferenceList();
  23. } // BaseMessageHeaderEdit

代码示例来源:origin: org.sakaiproject.message/sakai-message-util

  1. /**
  2. * Construct. Time and From set automatically.
  3. *
  4. * @param id
  5. * The message id.
  6. */
  7. public BaseMessageHeaderEdit(Message msg, String id)
  8. {
  9. m_message = msg;
  10. m_id = id;
  11. m_message_order=0;
  12. m_date = m_timeService.newTime();
  13. try
  14. {
  15. m_from = m_userDirectoryService.getUser(m_sessionManager.getCurrentSessionUserId());
  16. }
  17. catch (UserNotDefinedException e)
  18. {
  19. m_from = m_userDirectoryService.getAnonymousUser();
  20. }
  21. // init the AttachmentContainer
  22. m_attachments = m_entityManager.newReferenceList();
  23. } // BaseMessageHeaderEdit

代码示例来源:origin: sakaiproject/sakai

  1. /**
  2. * Construct as a copy of another header.
  3. *
  4. * @param other
  5. * The other message header to copy.
  6. */
  7. public BaseMessageHeaderEdit(Message msg, MessageHeader other)
  8. {
  9. m_message = msg;
  10. m_id = other.getId();
  11. m_date = m_timeService.newTime(other.getDate().getTime());
  12. m_from = other.getFrom();
  13. m_draft = other.getDraft();
  14. m_access = other.getAccess();
  15. m_message_order=other.getMessage_order();
  16. m_attachments = m_entityManager.newReferenceList();
  17. replaceAttachments(other.getAttachments());
  18. m_groups = new Vector(other.getGroups());
  19. } // BaseMessageHeaderEdit

代码示例来源:origin: org.sakaiproject.message/sakai-message-impl

  1. /**
  2. * Construct as a copy of another header.
  3. *
  4. * @param other
  5. * The other message header to copy.
  6. */
  7. public BaseMessageHeaderEdit(Message msg, MessageHeader other)
  8. {
  9. m_message = msg;
  10. m_id = other.getId();
  11. m_date = m_timeService.newTime(other.getDate().getTime());
  12. m_from = other.getFrom();
  13. m_draft = other.getDraft();
  14. m_access = other.getAccess();
  15. m_message_order=other.getMessage_order();
  16. m_attachments = m_entityManager.newReferenceList();
  17. replaceAttachments(other.getAttachments());
  18. m_groups = new Vector(other.getGroups());
  19. } // BaseMessageHeaderEdit

代码示例来源:origin: org.sakaiproject.message/sakai-message-util

  1. /**
  2. * Construct as a copy of another header.
  3. *
  4. * @param other
  5. * The other message header to copy.
  6. */
  7. public BaseMessageHeaderEdit(Message msg, MessageHeader other)
  8. {
  9. m_message = msg;
  10. m_id = other.getId();
  11. m_date = m_timeService.newTime(other.getDate().getTime());
  12. m_from = other.getFrom();
  13. m_draft = other.getDraft();
  14. m_access = other.getAccess();
  15. m_message_order=other.getMessage_order();
  16. m_attachments = m_entityManager.newReferenceList();
  17. replaceAttachments(other.getAttachments());
  18. m_groups = new Vector(other.getGroups());
  19. } // BaseMessageHeaderEdit

代码示例来源:origin: org.sakaiproject/sakai-syllabus-impl

  1. List<Reference> attachments = entityManager.newReferenceList();

相关文章