package com.scoopit.example;

import com.scoopit.client.ScoopApiExecutionException;
import com.scoopit.client.ScoopClient;
import com.scoopit.model.Post;
import com.scoopit.model.Topic;
import com.scoopit.model.User;

public class GetTopicAndUser {
	public static void main(String[] args) {
		//get yours on https://www.scoop.it/dev/apps
		ScoopClient scoopit = new ScoopClient(
				"<yourkey>",
				"<yoursecret>");
		
		
		try {
			Topic t = scoopit.getTopic(9014);
			System.out.println(t);
			for (Post p : t.curatedPosts) {
				System.out.println(p);
			}
			System.out.println("============******===========");
			User u = scoopit.getUser((long) 0);
			System.out.println(u);

		} catch (ScoopApiExecutionException e) {
			e.printStackTrace();
		}

	}
}

@@ -242,17 +242,20 @@
 dUser %7B%0A
-%09
+    
 public s
@@ -289,14 +289,55 @@
 gs) 
-%7B%0A%09%09
+throws ScoopApiExecutionException %7B%0A        
 //
+ 
 get 
@@ -375,18 +375,24 @@
 ev/apps%0A
-%09%09
+        
 ScoopCli
@@ -425,36 +425,31 @@
 ent(
-%0A%09%09%09%09
 %22%3Cyou
-r
+api
 key%3E%22,
-%0A%09%09%09%09
+ 
 %22%3Cyou
-r
+api
 secr
@@ -459,25 +459,78 @@
 %22);%0A
-%09%09%0A%09%09%0A%09%09try %7B%0A%09%09%09
+%0A        System.out.println(%22============******===========%22);%0A        
 Topi
@@ -559,19 +559,24 @@
 (9014);%0A
-%09%09%09
+        
 System.o
@@ -590,19 +590,24 @@
 tln(t);%0A
-%09%09%09
+        
 for (Pos
@@ -634,12 +634,20 @@
 ) %7B%0A
-%09%09%09%09
+            
 Syst
@@ -669,16 +669,26 @@
 p);%0A
-%09%09%09%7D%0A%09%09%09
+        %7D%0A        
 Syst
@@ -736,19 +736,24 @@
 ====%22);%0A
-%09%09%09
+        
 User u =
@@ -773,22 +773,21 @@
 ser(
-(long) 0);%0A%09%09%09
+0l);%0A        
 Syst
@@ -810,81 +810,12 @@
 );%0A%0A
-%09%09%7D catch (ScoopApiExecutionException e) %7B%0A%09%09%09e.printStackTrace();%0A%09%09%7D%0A%0A%09
+    
 %7D%0A%7D%0A

Remove try{}catch{}