@Override
 public View doGet() {
   // TODO Auto-generated method stub
   String param = this.getParam("v");
   String page = this.getParam("page");
   if (param != null) {
     String appid = this.getParam("appid");
     return Model.init(param, appid);
   }
   if (page != null) {
     return Model.nextPage(page);
   }
   return Model.init();
 }
Beispiel #2
0
  public void go() {
    model = new Model();
    view = new OpenGLView();

    model.init();

    view.add(new ThreeDView(0, 0));
    view.add(new DebugView());

    view.init(model);
  }
 @Override
 public View doPost() {
   // TODO Auto-generated method stub
   String apiName = getParam("list").trim();
   if (apiName != null) {
     if (apiName.equalsIgnoreCase("playlists")) {
       return Model.getPlayList(getDataPost(YoutubeForm.class));
     }
     if (apiName.equalsIgnoreCase("playlistItems")) {
       return Model.getPlaylistItems(getDataPost(YoutubeForm.class));
     }
     if (apiName.equalsIgnoreCase("subscriptions")) {
       return Model.getSubscriptionsList(getDataPost(YoutubeForm.class));
     }
   }
   return Model.init();
 }
 @Override
 public View doGet() {
   // TODO Auto-generated method stub
   return Model.init();
 }