Package com.google.gdata.data

Examples of com.google.gdata.data.Feed


        System.out.println("\n\n");
    }       
   
    @Test
    public void testClientGetFeed() throws Exception {
        Feed feed = testService.clientGetFeed();
        System.out.println("feed title: " + feed.getTitle().getPlainText());       
        Assert.assertEquals("gdata binding tuscany test", feed.getTitle().getPlainText());
     }
View Full Code Here


    public void testClientQuery() throws Exception {
        Query myQuery = new Query(new URL("http://haibotuscany.blogspot.com/feeds/posts/default"));
        myQuery.setMaxResults(100);
        //myQuery.setUpdatedMin(startTime);
        myQuery.setUpdatedMax(DateTime.now());
        Feed resultFeed = testService.clientQuery(myQuery);       
        System.out.println("Query result feed title: " + resultFeed.getTitle().getPlainText());   
        System.out.println("Query result entry number: "+ resultFeed.getEntries().size());
        //assertEquals("gdata binding tuscany test", resultFeed.getTitle().getPlainText());
     }
View Full Code Here

    /*
     * Test method for 'org.apache.lucene.gdata.server.GDataResponse.sendResponse(BaseFeed, ExtensionProfile)'
     */
    public void testSendResponseBaseFeedExtensionProfile() throws IOException {
        try{
            Feed f = null;
            this.response.sendResponse(f, new ProvidedServiceStub());
            fail("Exception expected");
        }catch (IllegalArgumentException e) {
            //
        }
        
        try{
            Feed f = createFeed();
            this.response.sendResponse(f,null);
            fail("Exception expected");
        }catch (IllegalArgumentException e) {
            //
        }
View Full Code Here

        
    }
    
    /* create a simple feed */
    private Feed createFeed(){
        Feed feed = new Feed();
        
        feed.getEntries().add(createEntry());
        
        return feed;
    }
View Full Code Here

    /**
     * Creates a new ServerBaseFeed and decorates a basic instance of {@link Feed}
     */
    @SuppressWarnings("unchecked")
    public ServerBaseFeed() {
        this.feed = new Feed();
       
    }
View Full Code Here

            System.out.println("[Debug Info] GdataBindingInvoker.GetAllInvoker.invoke---feedURL: " + uri);

            try {

                Feed feed = googleService.getFeed(new URL(uri), Feed.class);
                msg.setBody(feed);

            } catch (ResourceNotFoundException ex) {
                msg.setFaultBody(new ResourceNotFoundException("Invalid Resource at " + uri));
            } catch (ServiceException ex) {
View Full Code Here

           
            System.out.println("[Debug Info] GdataBindingInvoker.QueryInvoker.invoke---feedURL: " + uri);

            try {

              Feed resultFeed = googleService.query(myQuery, Feed.class);
                msg.setBody(resultFeed);

            } catch (ResourceNotFoundException ex) {
                msg.setFaultBody(new ResourceNotFoundException("Invalid Resource at " + uri));
            } catch (ServiceException ex) {
View Full Code Here

        System.out.println("\n\n");
    }       
   
    @Test
    public void testClientGetFeed() throws Exception {
        Feed feed = testService.clientGetFeed();
        System.out.println("feed title: " + feed.getTitle().getPlainText());       
        assertEquals("gdata binding tuscany test", feed.getTitle().getPlainText());
     }
View Full Code Here

    public void testClientQuery() throws Exception {
        Query myQuery = new Query(new URL("http://haibotuscany.blogspot.com/feeds/posts/default"));
        myQuery.setMaxResults(100);
        //myQuery.setUpdatedMin(startTime);
        myQuery.setUpdatedMax(DateTime.now());
        Feed resultFeed = testService.clientQuery(myQuery);       
        System.out.println("Query result feed title: " + resultFeed.getTitle().getPlainText());   
        System.out.println("Query result entry number: "+ resultFeed.getEntries().size());
        //assertEquals("gdata binding tuscany test", resultFeed.getTitle().getPlainText());
     }
View Full Code Here

        //Initialize the GData client service (Reference Binding test)
        SCADomain scaDomain = SCADomain.newInstance("org/apache/tuscany/sca/binding/gdata/ConsumerGoogleBlogger.composite");
        CustomerClient testService = scaDomain.getService(CustomerClient.class, "CustomerClient");         
       
       
        Feed feed = testService.clientGetFeed();
       
        System.out.println("#Entries(Before post): "+ testService.clientGetFeed().getEntries().size());
       
        /*
        String entryID = "tag:blogger.com,1999:blog-4520949313432095990.post-973462497533349425";
View Full Code Here

TOP

Related Classes of com.google.gdata.data.Feed

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.