Examples of PublisherData


Examples of org.olat.core.util.notifications.PublisherData

      // subscription
      subsContext = new SubscriptionContext(course, courseNode.getIdent());
      // if sc is null, then no subscription is desired
      if (subsContext != null) {
        String businessPath = wControl.getBusinessControl().getAsString();
        PublisherData pdata = new PublisherData(OresHelper.calculateTypeName(DENCourseNode.class), String.valueOf(course.getResourceableId()), businessPath);
        csc = new ContextualSubscriptionController(ureq, getWindowControl(), subsContext, pdata);
        runVC.put("subscription", csc.getInitialComponent());
      }
     
      authorOptions = new AuthorOptionsForm(ureq, getWindowControl());
View Full Code Here

Examples of org.olat.core.util.notifications.PublisherData

      @Override
      public Long getResourceableId() { return 0l; }
      @Override
      public String getResourceableTypeName() { return "NewIdentityCreated"; }
    });
    PublisherData publisherData = new PublisherData(RES_NAME, NEW, ce.toString());
    return publisherData;
  }
View Full Code Here

Examples of org.olat.core.util.notifications.PublisherData

 
  /**
   * Subscribe to notifications of new identity created
   */
  public void subscribe(Identity identity) {
    PublisherData data = getNewUsersPublisherData();
    SubscriptionContext context = getNewUsersSubscriptionContext();
    NotificationsManager.getInstance().subscribe(identity, context, data);
  }
View Full Code Here

Examples of org.olat.core.util.notifications.PublisherData

   *
   *
   */
  public void testSubscriptions() {
    SubscriptionContext sc = new SubscriptionContext("Course", new Long(123), "676");
    PublisherData pd = new PublisherData("Forum", "e.g. forumdata=keyofforum", null);

    SubscriptionContext sc2 = new SubscriptionContext("Course2", new Long(123), "6762");
    PublisherData pd2 = new PublisherData("Forum", "e.g. forumdata=keyofforum2", null);

    //Publisher p = nm.getPublisher(sc);
    //assertNull(p);
    DBFactory.getInstance().closeSession();
   
View Full Code Here

Examples of org.olat.core.util.notifications.PublisherData

   * Start 2 threads which call 'subscribe' with same SubscriptionContext.
   * Breakpoint at doInSync, second thread must wait until thread 1 has released the breakpoint.
   */
  public void testConcurrentFindOrCreatePublisher() {
    final SubscriptionContext sc = new SubscriptionContext("Course", new Long(1238778565), "676");
    final PublisherData pd = new PublisherData("Forum", "e.g. forumdata=keyofforum", null );

    final List<Exception> exceptionHolder = Collections.synchronizedList(new ArrayList<Exception>(1));
    final List<Boolean> statusList = Collections.synchronizedList(new ArrayList<Boolean>(1));

    // enable breakpoint
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.