Commits

Sumin Byeon committed c0ace89

Revised function names.

  • Participants
  • Parent commits 3617bb1

Comments (0)

Files changed (1)

File helloworld.py

 #    # Display the title of the document on the command line.
 #    print document_entry.title.text
 
-def ListGetAction(gd_client, key, wksht_id, query=None):
+def get_list_feed(gd_client, key, wksht_id, query=None):
     # Get the list feed
     feed = gd_client.GetListFeed(key, wksht_id, query=query)
     return feed
 
-def ListInsertAction(gd_client, key, wksht_id, row_data):
+def insert_row(gd_client, key, wksht_id, row_data):
     entry = gd_client.InsertRow(row_data, key, wksht_id)
     if isinstance(entry, gdata.spreadsheet.SpreadsheetsList):
         print 'Inserted!'
 
-def ListUpdateAction(gd_client, key, wksht_id, index, row_data):
+def update_row(gd_client, key, wksht_id, index, row_data):
     feed = gd_client.GetListFeed(key, wksht_id)
     entry = gd_client.UpdateRow(feed.entry[index], row_data)
     if isinstance(entry, gdata.spreadsheet.SpreadsheetsList):
 q.sq = 'key!=value'
 q.feed = 'https://spreadsheets.google.com/feeds/list/key/'+key+'/private/full'
 
-for entry in ListGetAction(client, key, 'default', q).entry:
+for entry in get_list_feed(client, key, 'default', q).entry:
     for key in entry.custom:
         print '%s: %s' % (key, entry.custom[key].text)
 
 # Here 'key' is the name of each column of the spreadsheet. It appears to be
 # case insensitive.
-#ListInsertAction(client, key, 'default', {'key':'value'})
+#insert_row(client, key, 'default', {'key':'value'})
 
 # 'index' is zero-based.
-#ListUpdateAction(client, key, 'default', 1, {'key':'new value'})
+#update_row(client, key, 'default', 1, {'key':'new value'})