The problem with GetCreator is that it will return the person who
created the blip, not the participant who actually submitted the blip
(if someone else edits the blip for example or if there are multiple
collaborators on a blip)
The only way to find out who submitted the blip is by hacking the
waveapi files themselves:
in robot_abstract.py line 124 replace (in the HandleEvent module of
the Robot class):
handler(event.properties, context)
with
#handler(event.properties, context)
handler(event, context)
now, in your event handlers, you'll have to modify things somewhat...
def OnBlipSubmitted(properties, context):
becomes
def OnBlipSubmitted(event, context):
and to get the properties, all you need to do is
event.properties
and finally to get the submitter of the blip
event.modifiedBy
if you want to see what else is available through the event object,
look at the model.py file and look at the event class. It has 5
attributes which can be quite handy.
self.modifiedBy = json.get('modifiedBy') >> string
self.properties = json.get('properties', {}) >>
dictionary
self.timestamp = json.get('timestamp', 0) >> string
self.type = json.get('type') >>
string
self.raw_data = json >>
dictionary
On Nov 28, 9:00 am, Bryan <[email protected]> wrote:
> Thank you, the @googlewave.com is what I wanted. Figured out my other
> problem as well. Just one more question. How do I get the contents of
> the blip that is submitted. I assume its something like like
> blip.GetContents() but I just don't know what the syntax is.
>
> Thank You,
> Bryan
--
You received this message because you are subscribed to the Google Groups
"Google Wave API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-wave-api?hl=en.