All pastes #723219 Raw Edit

atsushieno

public diff v1 · immutable
#723219 ·published 2007-10-02 16:49 UTC
rendered paste body
--- TwitterIrcGateway/src/TwitterIrcGatewayCore/TwitterService.cs	2007-09-29 03:03:48.000000000 +0900+++ TwitterIrcGateway-eno/src/TwitterIrcGatewayCore/TwitterService.cs	2007-10-03 01:45:57.953125000 +0900@@ -248,6 +248,53 @@         }          /// <summary>+        /// replies を取得します。+        /// </summary>+        /// <exception cref="WebException"></exception>+        /// <exception cref="TwitterServiceException"></exception>+        public Statuses GetReplies()+        {+            try+            {+                String responseBody = GET("/statuses/replies.xml");+                Statuses statuses;+                if (NilClasses.CanDeserialize(responseBody))+                {+                    statuses = new Statuses();+                    statuses.Status = new Status[0];+                }+                else+                {+                    statuses = Statuses.Serializer.Deserialize(new StringReader(responseBody)) as Statuses;+                    if (statuses == null || statuses.Status == null)+                    {+                        statuses = new Statuses();+                        statuses.Status = new Status[0];+                    }+                }++                return statuses;+            }+            catch (WebException we)+            {+                throw;+            }+            catch (InvalidOperationException ioe)+            {+                // XmlSerializer+                throw new TwitterServiceException(ioe);+            }+            catch (XmlException xe)+            {+                throw new TwitterServiceException(xe);+            }+            catch (IOException ie)+            {+                throw new TwitterServiceException(ie);+            }+        }++        /// <summary>         /// direct messages を取得します。         /// </summary>         /// <param name="since">最終更新日時</param>