Google_Wave_Pune_GTUG
Upcoming SlideShare
Loading in...5
×

Like this? Share it with your network

Share
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
997
On Slideshare
778
From Embeds
219
Number of Embeds
1

Actions

Shares
Downloads
1
Comments
0
Likes
0

Embeds 219

http://rohitghatol.com 219

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Programming on Google Wave By Rohit Ghatol From Pune Google Technology User Group http://pune-gtug.blogspot.com http://blog.punegtug.org
  • 2. What is Pune-GTUG? GTUG stands for Google Technology User Group http://blog.punegtug.org
  • 3. Google Wave http://blog.punegtug.org
  • 4. Topics
      • What is Wave?
      • Anatomy of a Wave
      • What can be done on GoogleWave?
      • Extending Google Wave
      • Writing Gadgets
      • Writing Robots
    http://blog.punegtug.org
  • 5. What is Wave? http://blog.punegtug.org
    • A wave is equal parts conversation and document.
      • People can communicate and work together with richly formatted text, photos, videos, maps, and more.
    • A wave is shared.  
      • Any participant can reply anywhere in the message, edit the content and add participants at any point in the process. Then playback lets anyone rewind the wave to see who said what and when.
    • A wave is live.  
      • With live transmission as you type, participants on a wave can have faster conversations, see edits and interact with extensions in real-time.
  • 6. What is Wave? http://blog.punegtug.org Lets see Wave in action!
  • 7. Topics
      • What is Wave?
      • Anatomy of a Wave
      • What can be done on GoogleWave?
      • Extending Google Wave
      • Writing Gadgets
      • Writing Robots
    http://blog.punegtug.org
  • 8. Anatomy of a Wave http://blog.punegtug.org Wave A  wave  is a threaded conversation, consisting of one or more participants (which may include both human participants and  robots ). The wave is a dynamic entity which contains state and stores historical information. A wave is a living thing, with participants communicating and modifying the wave in real time. A wave serves as a container for one or more  wavelets  defined below.
  • 9. Anatomy of a Wave http://blog.punegtug.org Wavelet A  wavelet  is a threaded conversation that is spawned from a wave (including the initial conversation). Wavelets serve as the container for one or more messages, known as  blips . The wavelet is the basic unit of access control for data in the wave. All participants on a wavelet have full read/write access to all of the content within the wavelet.
  • 10. Anatomy of a Wave http://blog.punegtug.org Blip A  blip  is the basic unit of conversation and consists of a single messages which appears on a wavelet. Blips may either be  drafts  or  published  (by clicking "Done" within the Wave client). Blips manage their content through their  document , defined below. Blips may also contain other blips as children, forming a blip hierarchy. Each wavelet always consists of at least one root blip.
  • 11. Anatomy of a Wave http://blog.punegtug.org Document A  document  is the content attached to a blip. This document consists of XML which can be retrieved, modified or added by the API. Generally, you manage the document through convenience methods rather than through direct manipulation of the XML data structure.
  • 12. Topics
      • What is Wave?
      • Anatomy of a Wave
      • What can be done on GoogleWave?
      • Extending Google Wave
      • Writing Gadgets
      • Writing Robots
    http://blog.punegtug.org
  • 13. What can be done on Google Wave? http://blog.punegtug.org
      • Real time Chat
      • Editing as a Document
      • Real time collaboration
      • Robots participating
  • 14. Topics
      • What is Wave?
      • Anatomy of a Wave
      • What can be done on GoogleWave ?
      • Extending Google Wave
      • Writing Gadgets
      • Writing Robots
    http://blog.punegtug.org
  • 15. Extending Google Wave? http://blog.punegtug.org
      • Gadgets
        • Runs on the client.
        • Multiple instances per wave.
        • Not able to modify the wave, and has limited visibility into the wave. Is only able to detect changes in the wave's participants.
        • Not only can't modify a robot, has no way to know that the robot exists.
      • Robots
        • Runs in the cloud.
        • One instance of a given robot per wave. Remember that a robot is like a participant on a wave, so each participant/robot is a unique instance, but a wave can have many participants/robots.
        • Able to modify a wave and perform the same operations as a human participant.
        • Can modify a gadget.
  • 16. Topics
      • What is Wave?
      • Anatomy of a Wave
      • What can be done on GoogleWave?
      • Extending Google Wave
      • Writing Gadgets
      • Writing Robots
    http://blog.punegtug.org
  • 17. Writing Gadgets
      • Polling Gadget
        • Allows the host to set the title
        • All the participants can add Options
        • Everyone can vote on the Options
  • 18.  
  • 19. Writing Gadgets Polling Gadget function renderPoll(){ …… . } Events Event Callback State Event Participant Event
  • 20. Writing Gadgets Polling Gadget Polling Gadget Central State Update State Polling Gadget Polling Gadget Notify via callbacks
  • 21. Interacting with wave participants and state
  • 22. Writing Robots
      • Steps
        • Get Google App Engine Account
        • Get Google App Engine Eclipse plugin
        • Get Web Application Project
  • 23. Robot Architecture
  • 24. Writing Robots
      • Robot is a Java Web Application deployed on GAE
      • Contains
        • A Servlet
        • capabilities.xml
        • web.xml
        • appengine-web.xml
  • 25. Robot Servlet public class IterationServlet extends AbstractRobotServlet { public void processEvents(RobotMessageBundle context) { TextView textView = context.getWavelet().getRootBlip().getDocument(); //Condition to check if Robot was recently added if(context.wasSelfAdded()){ //Example of adding a Text textView.append("Robot: I have been just added to this wave"); //Example of adding a Form textView.appendElement(new FormElement(ElementType.LABEL, "NAME_LABEL", "What is your name? :")); textView.appendElement(new FormElement(ElementType.INPUT, "NAME_INPUT")); textView.appendElement(new FormElement(ElementType.BUTTON, "SUBMIT_BUTTON", "Submit")); //Example of adding a Gadget Gadget gadget = new Gadget("http://xyz.com/Iteration.gadget.xml"); gadget.setField("country", "India"); textView.appendElement(gadget); } } }
  • 26. capabilities.xml <?xml version= &quot;1.0&quot;?> <w:robot xmlns:w= &quot;http://wave.google.com/extensions/robots/1.0&quot;> <w:capabilities> <w:capability name= &quot;wavelet_participants_changed&quot;/> <w:capability name= &quot;document_changed&quot;/> <w:capability name= &quot;form_button_clicked&quot; content=&quot;true&quot; /> </w:capabilities> <w:crons> <w:cron path= &quot;/_wave/robot/fetchupdate&quot; timerinseconds=&quot;3600&quot; /> </w:crons> <w:profile name= &quot;waveiteration&quot; imageurl=&quot;/images/icon.png&quot; profileurl=&quot;/_wave/profile.xml&quot; /> </w:robot>
  • 27. Robot API Overview
  • 28. Robots + Gadget
      • Further we will talk about how to use Robots and Gadgets in conjunction with each other
      • Here is a Product Idea
  • 29. Account of rohitsghatol@wavesandbox.com
  • 30. Account of rohitsghatol@wavesandbox.com
  • 31. Account of rohitsghatol@wavesandbox.com
  • 32. Account of rohitsghatol@wavesandbox.com
  • 33. Account of rohitsghatol@wavesandbox.com
  • 34. Account of rohitsghatol-test@wavesandbox.com
  • 35. Robot wrote the updates from the Gadget to a Google Spreadsheet
  • 36. Robots + Gadget Create Wave Add Robot Present a Form Submit Form Create New Wave Add Participants Add Gadget Add State to Gadget Interacts with Gadget Get Gadget State Store data on Spreadsheet User Action Robot kicks in
  • 37. Questions? ? http://blog.punegtug.org