Examples of Topic


Examples of ch.interlis.ili2c.metamodel.Topic

                Iterator topici = model.iterator();
                while (topici.hasNext()) {
                    Object tObj = topici.next();

                    if (tObj instanceof Topic) {
                        Topic topic = (Topic) tObj;
                        Iterator iter = topic.getViewables().iterator();

                        while (iter.hasNext()) {
                            Object obj = iter.next();

                            if (obj instanceof Viewable) {
View Full Code Here

Examples of cn.iver.model.Topic

        render("/topic/add.html");
    }

    @Before({LoginInterceptor.class, TopicValidator.class, PostValidator.class})
    public void save(){
        Topic topic = getModel(Topic.class);
        topic.set("userID", getSessionAttr("userID")).set("id", null);
        Post post = getModel(Post.class);
        post.set("userID", getSessionAttr("userID"));
        topic.save(post);
        redirect("/post/" + topic.getInt("id"));
    }
View Full Code Here

Examples of com.amazonaws.services.sns.model.Topic

        throw new ServletException(ex);
      }
     
      for (int i = 0; topics != null && i < topics.size(); i++) {
           
            Topic t = topics.get(i);

            try {
          DeleteTopicRequest deleteTopicRequest = new DeleteTopicRequest(t.getTopicArn());
          sns.deleteTopic(deleteTopicRequest);
          logger.debug("event=delete_topic topic_arn=" + (t != null ? t.getTopicArn() : "null") + " user_id= " + userId);
        } catch (Exception ex) {
          logger.error("event=delete_topic topic_arn=" + (t != null ? t.getTopicArn() : "null") + " user_id= " + userId, ex);
        }
      }     
    }
   
    out.println("<html>");
   
    header(request, out, "Topics");
   
    out.println("<body>");

    out.println("<h2>Topics</h2>");
   
    long numTopics = 0;
   
    try {
      numTopics = PersistenceFactory.getUserPersistence().getNumUserTopics(userId);
    } catch (PersistenceException ex) {
      logger.warn("event=queue_count_failure", ex);
    }
   
    if (user != null) {
      out.println("<table><tr><td><b>User Name:</b></td><td>"+ user.getUserName()+"</td></tr>");
      out.println("<tr><td><b>User ID:</b></td><td>"+ user.getUserId()+"</td></tr>");
      out.println("<tr><td><b>Access Key:</b></td><td>"+user.getAccessKey()+"</td></tr>");
      out.println("<tr><td><b>Access Secret:</b></td><td>"+user.getAccessSecret()+"</td>");
      out.println("<tr><td><b>Topic Count</b></td><td>"+numTopics+"</td></tr></table>");
    }
       
    out.println("<p><table>");
    out.println("<tr><td><b>Topic Name</b></td><td><b>Topic Display Name</b></td><td></td></tr>");
        out.println("<form action=\"/webui/cnsuser?userId=" + userId + "\" " + "method=POST>");
        out.println("<tr><td><input type='text' name='topic' /></td><td><input type='text' name='display'><input type='hidden' name='userId' value='"+ userId + "'></td><td><input type='submit' value='Create' name='Create' /></td></tr></form></table></p>");
   
    out.println("<p><table>");
        out.println("<form action=\"/webui/cnsuser?userId=" + userId + "\" " + "method=POST>");
      out.println("<tr><td><input type='hidden' name='userId' value='"+ userId + "'></td><td><input type='submit' value='Delete All' name='DeleteAll' onclick=\"return confirm('Are you sure you want to delete all topics?')\" /></td></tr></form></table></p>");

        ListTopicsResult listTopicResult = null;
       
        try {
         
      ListTopicsRequest listTopicRequest = new ListTopicsRequest();
     
      if (nextToken != null) {
        listTopicRequest.setNextToken(nextToken);
      }

      listTopicResult = sns.listTopics(listTopicRequest);
      topics = listTopicResult.getTopics();

    } catch (Exception ex) {
      logger.error("event=list_topics user_id= " + userId, ex);
      throw new ServletException(ex);
    }
       
    out.println("<p><hr width='100%' align='left' /></p>");
    out.println("<p><table class = 'alternatecolortable' border='1'>");
    out.println("<tr><th>&nbsp;</th>");
    out.println("<th>Topic Arn</th>");
    out.println("<th>Topic Name</th>");
    out.println("<th>Topic Display Name</th>");
    out.println("<th>User ID</th>");
    out.println("<th>Subscriptions Pending</th>");
    out.println("<th>Subscriptions Confirmed</th>");
    out.println("<th>&nbsp;</th>");
    out.println("<th>&nbsp;</th>");
    out.println("<th>&nbsp;</th>");
    out.println("<th>&nbsp;</th>");
    out.println("<th>&nbsp;</th></tr>");

    for (int i = 0; topics != null && i < topics.size(); i++) {
         
          Topic t = topics.get(i);
        
      GetTopicAttributesRequest getTopicAttributesRequest = new GetTopicAttributesRequest(t.getTopicArn());
      GetTopicAttributesResult getTopicAttributesResult = sns.getTopicAttributes(getTopicAttributesRequest);
      Map<String, String> attributes = getTopicAttributesResult.getAttributes();

      out.println("<tr>");
      out.println("<form action=\"/webui/cnsuser?userId="+userId+"\" method=POST>");
          out.println("<td>"+i+"</td>");
          out.println("<td>"+t.getTopicArn() +"<input type='hidden' name='arn' value="+t.getTopicArn()+"></td>");
          out.println("<td>"+Util.getNameFromTopicArn(t.getTopicArn())+"</td>");
          out.println("<td><a href='' onclick=\"window.open('/webui/cnsuser/editdisplayname?topicArn="+ t.getTopicArn() + "&userId="+userId+"', 'EditDisplayName', 'height=300,width=700,toolbar=no')\">"+(attributes.get("DisplayName") == null ? "{unset}" : attributes.get("DisplayName"))+"</a></td>");
          out.println("<td>"+user.getUserId()+"<input type='hidden' name='userId' value="+user.getUserId()+"></td>");
          out.println("<td>"+attributes.get("SubscriptionsPending")+"</td>");
          out.println("<td>"+attributes.get("SubscriptionsConfirmed")+"</td>");
          out.println("<td><a href='/webui/cnsuser/subscription?userId="+ userId + "&topicArn=" + t.getTopicArn() + "'>Subscriptions</a></td>");
          out.println("<td><a href='/webui/cnsuser/publish?userId="+ userId + "&topicArn="+ t.getTopicArn() + "' target='_blank'>Publish</a></td>");
          out.println("<td><a href='' onclick=\"window.open('/webui/cnsuser/editdeliverypolicy?topicArn="+ t.getTopicArn() + "&userId="+userId+"', 'EditDeliveryPolicy', 'height=630,width=580,toolbar=no')\">View/Edit Topic Delivery Policy</a></td>");
        out.println("<td><a href='/webui/cnsuser/permission?topicArn="+ t.getTopicArn() + "&userId=" + userId + "'>Permission</a></td>");
             out.println("<td><input type='submit' value='Delete' name='Delete' onclick=\"return confirm('Are you sure you want to delete topic "+Util.getNameFromTopicArn(t.getTopicArn())+"?')\" /></td></form></tr>");
    }
       
        out.println("</table></p>");
       
        if (listTopicResult != null && listTopicResult.getNextToken() != null) {
View Full Code Here

Examples of com.coherentlogic.wb.client.core.domain.Topic

        List<Topic> topicList = result.getTopicList();

        assertNotNull(topicList);
        assertEquals(21, topicList.size());

        Topic thirdTopic = topicList.get(2);

        reviewIdValuePair("3", "Economy & Growth", thirdTopic);

        String expected =
            "Economic growth is central to economic development. When " +
            "national income grows, real people benefit. While there is no " +
            "known formula for stimulating economic growth, data can help " +
            "policy-makers better understand their countries' economic " +
            "situations and guide any work toward improvement. Data here " +
            "covers measures of economic growth, such as gross domestic " +
            "product (GDP) and gross national income (GNI). It also includes " +
            "indicators representing factors known to be relevant to " +
            "economic growth, such as capital stock, employment, " +
            "investment, savings, consumption, government spending, imports, " +
            "and exports.";

        String actual = thirdTopic.getSourceNote();

        assertEquals (expected, actual);
    }
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201402.video.Topic

    addGenderCriterionOp.setOperator(Operator.ADD);

    // Create a topic criterion for the Autos & Vehicles topic.
    // See ConstantDataService for a list of verticals.
    TargetingGroupCriterion topicCriterion = new TargetingGroupCriterion();
    Topic topic = new Topic();
    topic.setVerticalId(47L);
    topicCriterion.setCampaignId(campaignId);
    topicCriterion.setTargetingGroupId(targetingGroupId);
    topicCriterion.setCriterion(topic);

    TargetingGroupCriterionOperation addTopicCriterionOp =
View Full Code Here

Examples of com.google.api.ads.adwords.axis.v201406.video.Topic

    addGenderCriterionOp.setOperator(Operator.ADD);

    // Create a topic criterion for the Autos & Vehicles topic.
    // See ConstantDataService for a list of verticals.
    TargetingGroupCriterion topicCriterion = new TargetingGroupCriterion();
    Topic topic = new Topic();
    topic.setVerticalId(47L);
    topicCriterion.setCampaignId(campaignId);
    topicCriterion.setTargetingGroupId(targetingGroupId);
    topicCriterion.setCriterion(topic);

    TargetingGroupCriterionOperation addTopicCriterionOp =
View Full Code Here

Examples of com.googlecode.mgwt.examples.showcase.client.activities.home.Topic

    super(clientFactory.getPullToRefreshDisplay(), "nav");
    this.clientFactory = clientFactory;

    list = new LinkedList<Topic>();
    while (counter < 20) {
      list.add(new Topic("Topic " + (counter + 1), counter));
      counter++;
    }

  }
View Full Code Here

Examples of com.intellij.util.messages.Topic

  void deliverMessage(Message message) {
    final Message messageOnLocalQueue = myPendingMessages.get().poll();
    assert messageOnLocalQueue == message;

    final Topic topic = message.getTopic();
    final Object handler = mySubscriptions.get(topic);

    try {
      Method listenerMethod = message.getListenerMethod();
View Full Code Here

Examples of com.iqbon.jcms.domain.Topic

  private TopicDAO topicDAO;
  private Topic topic;
 
  protected void setUp() throws Exception {
    topicDAO = (TopicDAO) BeanFactory.getBean("topicDAO");
    topic = new Topic();
    String topicid = JCMSConstant.createTopicId();
    topic.setTopicId(topicid);
    topic.setTopicName("主栏目");
    topic.setTopicTree(topicid+";");
    topic.setModifyUser("testuser");
View Full Code Here

Examples of com.l2jfrozen.gameserver.communitybbs.BB.Topic

      activeChar.sendPacket(new ShowBoard(null, "102"));
      activeChar.sendPacket(new ShowBoard(null, "103"));
    }
    else
    {
      Topic t = f.gettopic(idt);
      if(t == null)
      {
        ShowBoard sb = new ShowBoard("<html><body><br><br><center>the topic: " + idt + " does not exist !</center><br><br></body></html>", "101");
        activeChar.sendPacket(sb);
        sb = null;
        activeChar.sendPacket(new ShowBoard(null, "102"));
        activeChar.sendPacket(new ShowBoard(null, "103"));
      }
      else
      {
        CPost cp = null;
        Post p = getGPosttByTopic(t);
        if(p != null)
        {
          cp = p.getCPost(idp);
        }

        if(cp == null)
        {
          ShowBoard sb = new ShowBoard("<html><body><br><br><center>the post: " + idp + " does not exist !</center><br><br></body></html>", "101");
          activeChar.sendPacket(sb);
          activeChar.sendPacket(new ShowBoard(null, "102"));
          activeChar.sendPacket(new ShowBoard(null, "103"));
        }
        else if(p != null)
        {
          p.getCPost(idp).postTxt = ar4;
          p.updatetxt(idp);
          parsecmd("_bbsposts;read;" + f.getID() + ";" + t.getID(), activeChar);
        }

        cp = null;
        p = null;
      }
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.