From: bg66 Date: Mon, 1 Oct 2007 11:24:03 +0000 (+0000) Subject: * mixi.el (mixi-friend-nick-regexp): Follow the change of mixi. X-Git-Tag: mixi-el-1_0_0~16 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c6c7071206bc8f987f1791f3bc03ebbe875e3c8e;p=elisp%2Fmixi.git * mixi.el (mixi-friend-nick-regexp): Follow the change of mixi. (mixi-friend-name-regexp): Ditto. (mixi-friend-sex-regexp): Ditto. (mixi-friend-address-regexp): Ditto. (mixi-friend-age-regexp): Ditto. (mixi-friend-birthday-regexp): Ditto. (mixi-friend-blood-type-regexp): Ditto. (mixi-friend-birthplace-regexp): Ditto. (mixi-friend-hobby-regexp): Ditto. (mixi-friend-job-regexp): Ditto. (mixi-friend-organization-regexp): Ditto. (mixi-friend-profile-regexp): Ditto. (mixi-realize-friend): Ditto. (mixi-friend-list-nick-regexp): Ditto. (mixi-diary-owner-nick-regexp): Ditto. (mixi-diary-title-regexp): Ditto. (mixi-diary-time-regexp): Ditto. (mixi-diary-content-regexp): Ditto. (mixi-realize-diary): Ditto. (mixi-diary-list-regexp): Ditto. (mixi-new-diary-list-regexp): Ditto. (mixi-get-diaries): Ditto. (mixi-community-name-regexp): Ditto. (mixi-community-birthday-regexp): Ditto. (mixi-community-owner-regexp): Ditto. (mixi-community-category-regexp): Ditto. (mixi-community-members-regexp): Ditto. (mixi-community-open-level-regexp): Ditto. (mixi-community-authority-regexp): Ditto. (mixi-community-description-regexp): Ditto. (mixi-community-list-name-regexp): Ditto. (mixi-search-community-list-regexp): Ditto. (mixi-topic-community-regexp): Ditto. (mixi-topic-title-regexp): Ditto. (mixi-topic-time-regexp): Ditto. (mixi-topic-owner-regexp): Ditto. (mixi-topic-content-regexp): Ditto. (mixi-event-community-regexp): Ditto. (mixi-event-title-regexp): Ditto. (mixi-event-time-regexp): Ditto. (mixi-event-date-regexp): Ditto. (mixi-event-place-regexp): Ditto. (mixi-event-owner-regexp): Ditto. (mixi-event-owner-seceded-regexp): Ditto. (mixi-event-detail-regexp): Ditto. (mixi-event-limit-regexp): Ditto. (mixi-event-members-regexp): Ditto. (mixi-realize-event): Ditto. (mixi-bbs-list-regexp): Ditto. (mixi-new-bbs-list-regexp): Ditto. (mixi-search-bbs-list-regexp): Ditto. (mixi-diary-comment-list-regexp): Ditto. (mixi-topic-comment-list-regexp): Ditto. (mixi-event-comment-list-regexp): Ditto. (mixi-get-comments): Ditto. (mixi-new-comment-list-regexp): Ditto. * mixi-utils.el (mixi-make-content): Follow the change above. --- diff --git a/ChangeLog b/ChangeLog index 0b1c5b6..cc906b2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,63 @@ 2007-10-01 OHASHI Akira + * mixi.el (mixi-friend-nick-regexp): Follow the change of mixi. + (mixi-friend-name-regexp): Ditto. + (mixi-friend-sex-regexp): Ditto. + (mixi-friend-address-regexp): Ditto. + (mixi-friend-age-regexp): Ditto. + (mixi-friend-birthday-regexp): Ditto. + (mixi-friend-blood-type-regexp): Ditto. + (mixi-friend-birthplace-regexp): Ditto. + (mixi-friend-hobby-regexp): Ditto. + (mixi-friend-job-regexp): Ditto. + (mixi-friend-organization-regexp): Ditto. + (mixi-friend-profile-regexp): Ditto. + (mixi-realize-friend): Ditto. + (mixi-friend-list-nick-regexp): Ditto. + (mixi-diary-owner-nick-regexp): Ditto. + (mixi-diary-title-regexp): Ditto. + (mixi-diary-time-regexp): Ditto. + (mixi-diary-content-regexp): Ditto. + (mixi-realize-diary): Ditto. + (mixi-diary-list-regexp): Ditto. + (mixi-new-diary-list-regexp): Ditto. + (mixi-get-diaries): Ditto. + (mixi-community-name-regexp): Ditto. + (mixi-community-birthday-regexp): Ditto. + (mixi-community-owner-regexp): Ditto. + (mixi-community-category-regexp): Ditto. + (mixi-community-members-regexp): Ditto. + (mixi-community-open-level-regexp): Ditto. + (mixi-community-authority-regexp): Ditto. + (mixi-community-description-regexp): Ditto. + (mixi-community-list-name-regexp): Ditto. + (mixi-search-community-list-regexp): Ditto. + (mixi-topic-community-regexp): Ditto. + (mixi-topic-title-regexp): Ditto. + (mixi-topic-time-regexp): Ditto. + (mixi-topic-owner-regexp): Ditto. + (mixi-topic-content-regexp): Ditto. + (mixi-event-community-regexp): Ditto. + (mixi-event-title-regexp): Ditto. + (mixi-event-time-regexp): Ditto. + (mixi-event-date-regexp): Ditto. + (mixi-event-place-regexp): Ditto. + (mixi-event-owner-regexp): Ditto. + (mixi-event-owner-seceded-regexp): Ditto. + (mixi-event-detail-regexp): Ditto. + (mixi-event-limit-regexp): Ditto. + (mixi-event-members-regexp): Ditto. + (mixi-realize-event): Ditto. + (mixi-bbs-list-regexp): Ditto. + (mixi-new-bbs-list-regexp): Ditto. + (mixi-search-bbs-list-regexp): Ditto. + (mixi-diary-comment-list-regexp): Ditto. + (mixi-topic-comment-list-regexp): Ditto. + (mixi-event-comment-list-regexp): Ditto. + (mixi-get-comments): Ditto. + (mixi-new-comment-list-regexp): Ditto. + * mixi-utils.el (mixi-make-content): Follow the change above. + * mixi.el (mixi-event-detail-regexp): Fix regexp. 2007-09-30 OHASHI Akira diff --git a/mixi-utils.el b/mixi-utils.el index 6c1b441..289b6c1 100644 --- a/mixi-utils.el +++ b/mixi-utils.el @@ -149,22 +149,18 @@ (defun mixi-make-content (object) (with-mixi-class object (cond ((eq class 'mixi-event) - (let ((limit (mixi-event-limit object))) - (setq limit (if limit - (format-time-string "%Yǯ%m·î%dÆü" limit) - "»ØÄê¤Ê¤·")) - (concat "
" - "
³«ºÅÆü»þ¡§
" - "
" (mixi-event-date object) "
\n" - "
³«ºÅ¾ì½ê¡§
" - "
" (mixi-event-place object) "
\n" - "
¾ÜºÙ¡§
" - "
" (mixi-event-detail object) "
\n" - "
Ê罸´ü¸Â¡§
" - "
" limit "
\n" - "
»²²Ã¼Ô¡§
" - "
" (mixi-event-members object) "
\n" - "
"))) + (concat "
" + "
³«ºÅÆü»þ¡§
" + "
" (mixi-event-date object) "
\n" + "
³«ºÅ¾ì½ê¡§
" + "
" (mixi-event-place object) "
\n" + "
¾ÜºÙ¡§
" + "
" (mixi-event-detail object) "
\n" + "
Ê罸´ü¸Â¡§
" + "
" (mixi-event-limit object) "
\n" + "
»²²Ã¼Ô¡§
" + "
" (mixi-event-members object) "
\n" + "
")) ((eq class 'mixi-friend) (if (mixi-object-realized-p object) (let ((sex (if (eq (mixi-friend-sex object) 'male) "ÃË" "½÷")) diff --git a/mixi.el b/mixi.el index 8d30a24..124d34c 100644 --- a/mixi.el +++ b/mixi.el @@ -825,36 +825,29 @@ Increase this value when unexpected error frequently occurs." `(concat "/show_profile.pl?id=" (mixi-friend-id ,friend))) (defconst mixi-friend-nick-regexp - " ? -\\(.*\\)¤µ¤ó([0-9]+)") + "

\\(.*\\)¤µ¤ó([0-9]+)

") (defconst mixi-friend-name-regexp - "̾\\( \\| \\)Á° - -?\\(.+?\\)\\(\\| ̾Á°\n?
\\(.+?\\)\\(\\)") (defconst mixi-friend-sex-regexp - "À­\\( \\| \\)ÊÌ - -?\\([Ã˽÷]\\)À­\\(\\| À­ÊÌ\n?
\\([Ã˽÷]\\)À­\\(\\)") (defconst mixi-friend-address-regexp - "¸½½»½ê -\\(.+?\\)\\(\\| ¸½½»½ê\n?
\\(.+?\\)\\(\\)") (defconst mixi-friend-age-regexp - "ǯ\\( \\| \\)Îð\n\\([0-9]+\\)ºÐ\\(\\| ǯÎð\n?
\\([0-9]+\\)ºÐ\\( \\)") (defconst mixi-friend-birthday-regexp - "ÃÂÀ¸Æü\n\\([0-9]+\\)·î\\([0-9]+\\)Æü\\(\\| ÃÂÀ¸Æü\n?
\\([0-9]+\\)·î\\([0-9]+\\)Æü\\(\\)") (defconst mixi-friend-blood-type-regexp - "·ì±Õ·¿\n\\([ABO]B?\\)·¿\\(\\| ·ì±Õ·¿\n?
\\([ABO]B?\\)·¿\\(\\)") (defconst mixi-friend-birthplace-regexp - "½Ð¿ÈÃÏ\n?\n\\(.+?\\)\\(\\| ½Ð¿ÈÃÏ\n?
\\(.+?\\)\\(\\)") (defconst mixi-friend-hobby-regexp - "¼ñ\\( \\| \\)Ì£\n\\(.+?\\)\\(\\| ¼ñÌ£\n?
\\(.+?\\)\\(\\)") (defconst mixi-friend-job-regexp - "¿¦\\( \\| \\)¶È\n\\(.+?\\)\\(\\| ¿¦¶È\n?
\\(.+?\\)\\(\\)") (defconst mixi-friend-organization-regexp - "½ê\\( \\| \\)°\n]*>\\(.+?\\)\\(\\| ½ê°\n?
\\(.+?\\)\\(\\)") (defconst mixi-friend-profile-regexp - "¼«¸Ê¾Ò²ð -\\(\\(.\\|\r?\n\\)*?\\)") + "
¼«¸Ê¾Ò²ð
\n?
\\(.+?\\)
") (defun mixi-realize-friend (friend) "Realize a FRIEND." @@ -863,17 +856,17 @@ Increase this value when unexpected error frequently occurs." (with-mixi-retrieve (mixi-friend-page friend) (let ((case-fold-search t)) (if (re-search-forward mixi-friend-nick-regexp nil t) - (mixi-friend-set-nick friend (match-string 4)) + (mixi-friend-set-nick friend (match-string 1)) (mixi-realization-error 'cannot-find-nick friend)) (when (re-search-forward mixi-friend-name-regexp nil t) - (mixi-friend-set-name friend (match-string 2))) + (mixi-friend-set-name friend (match-string 1))) (when (re-search-forward mixi-friend-sex-regexp nil t) - (mixi-friend-set-sex friend (if (string= (match-string 2) "ÃË") + (mixi-friend-set-sex friend (if (string= (match-string 1) "ÃË") 'male 'female))) (when (re-search-forward mixi-friend-address-regexp nil t) (mixi-friend-set-address friend (match-string 1))) (when (re-search-forward mixi-friend-age-regexp nil t) - (mixi-friend-set-age friend (string-to-number (match-string 2)))) + (mixi-friend-set-age friend (string-to-number (match-string 1)))) (when (re-search-forward mixi-friend-birthday-regexp nil t) (mixi-friend-set-birthday friend (list (string-to-number (match-string 1)) @@ -883,11 +876,11 @@ Increase this value when unexpected error frequently occurs." (when (re-search-forward mixi-friend-birthplace-regexp nil t) (mixi-friend-set-birthplace friend (match-string 1))) (when (re-search-forward mixi-friend-hobby-regexp nil t) - (mixi-friend-set-hobby friend (split-string (match-string 2) ", "))) + (mixi-friend-set-hobby friend (split-string (match-string 1) ", "))) (when (re-search-forward mixi-friend-job-regexp nil t) - (mixi-friend-set-job friend (match-string 2))) + (mixi-friend-set-job friend (match-string 1))) (when (re-search-forward mixi-friend-organization-regexp nil t) - (mixi-friend-set-organization friend (match-string 2))) + (mixi-friend-set-organization friend (match-string 1))) (when (re-search-forward mixi-friend-profile-regexp nil t) (mixi-friend-set-profile friend (match-string 1))))) (mixi-object-touch friend))) @@ -1062,7 +1055,7 @@ Increase this value when unexpected error frequently occurs." (defconst mixi-friend-list-id-regexp "\\(.+\\)¤µ¤ó([0-9]+)") + "\\(.+\\)¤µ¤ó([0-9]+)") ;;;###autoload (defun mixi-get-friends (&rest friend-or-range) @@ -1182,13 +1175,18 @@ Increase this value when unexpected error frequently occurs." (defconst mixi-diary-closed-regexp "ͧ¿Í\\(¤Îͧ¿Í\\)?¤Þ¤Ç¸ø³«¤Î¤¿¤áÆɤळ¤È¤¬½ÐÍè¤Þ¤»¤ó¡£") (defconst mixi-diary-owner-nick-regexp - "\\(.+?\\)\\(¤µ¤ó\\)?¤ÎÆüµ­") -(defconst mixi-diary-time-regexp - "\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü\\([0-9]+\\):\\([0-9]+\\)") + "
+

\\(.+?\\)\\(¤µ¤ó\\)?¤ÎÆüµ­

") (defconst mixi-diary-title-regexp - " \\([^<]+\\)") + "
+
+
\\([^<\n]+\\)\\(\\)?") +(defconst mixi-diary-time-regexp + "
\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü\\([0-9]+\\):\\([0-9]+\\)
") (defconst mixi-diary-content-regexp - "\\(\\(.\\|\r?\n\\)*?\\)\\(\t\\|\r?\n\\)
") + "
+\\(\\(.\\|\r?\n\\)*?\\) +
") (defun mixi-realize-diary (diary &optional page) "Realize a DIARY." @@ -1199,19 +1197,19 @@ Increase this value when unexpected error frequently occurs." (unless (re-search-forward mixi-diary-closed-regexp nil t) (if (re-search-forward mixi-diary-owner-nick-regexp nil t) (mixi-friend-set-nick (mixi-diary-owner diary) - (match-string 1)) + (match-string 2)) (mixi-realization-error 'cannot-find-owner-nick diary)) + (if (re-search-forward mixi-diary-title-regexp nil t) + (mixi-diary-set-title diary (match-string 1)) + (mixi-realization-error 'cannot-find-title diary)) (if (re-search-forward mixi-diary-time-regexp nil t) (mixi-diary-set-time - diary (encode-time 0 (string-to-number (match-string 7)) - (string-to-number (match-string 6)) + diary (encode-time 0 (string-to-number (match-string 5)) (string-to-number (match-string 4)) (string-to-number (match-string 3)) - (string-to-number (match-string 2)))) + (string-to-number (match-string 2)) + (string-to-number (match-string 1)))) (mixi-realization-error 'cannot-find-time diary)) - (if (re-search-forward mixi-diary-title-regexp nil t) - (mixi-diary-set-title diary (match-string 1)) - (mixi-realization-error 'cannot-find-title diary)) (if (re-search-forward mixi-diary-content-regexp nil t) (mixi-diary-set-content diary (match-string 1)) (mixi-realization-error 'cannot-find-content diary))))) @@ -1287,9 +1285,9 @@ Increase this value when unexpected error frequently occurs." (when ,friend (concat "&id=" (mixi-friend-id ,friend))))) (defconst mixi-diary-list-regexp - " -\\([0-9]+\\)ǯ
\\([0-9]+\\)·î\\([0-9]+\\)Æü
\\([0-9]+\\):\\([0-9]+\\)
\\(
\\|\\) - 
\\(.*\\)") + "
\\(\\|\\)\\(.*\\)\\(ÊÔ½¸¤¹¤ë\\|\\)
+
\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü\n?\\([0-9]+\\):\\([0-9]+\\)
+
") ;;;###autoload (defun mixi-get-diaries (&rest friend-or-range) @@ -1308,22 +1306,22 @@ Increase this value when unexpected error frequently occurs." mixi-diary-list-regexp range))) (mapcar (lambda (item) - (mixi-make-diary friend (nth 6 item) nil + (mixi-make-diary friend (nth 1 item) nil (encode-time - 0 (string-to-number (nth 4 item)) - (string-to-number (nth 3 item)) - (string-to-number (nth 2 item)) - (string-to-number (nth 1 item)) - (string-to-number (nth 0 item))) - (nth 7 item))) + 0 (string-to-number (nth 8 item)) + (string-to-number (nth 7 item)) + (string-to-number (nth 6 item)) + (string-to-number (nth 5 item)) + (string-to-number (nth 4 item))) + (nth 2 item))) items)))) (defmacro mixi-new-diary-list-page () `(concat "/new_friend_diary.pl?page=%d")) (defconst mixi-new-diary-list-regexp - "\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\) -\\(.+\\) (\\(.*\\)) ") + "
\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\)
+
\\(.+\\) (\\(.*\\))
\\(.*\\)") + "
+

\\(.*\\)

") (defconst mixi-community-birthday-regexp - "³«ÀßÆü -\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü") + "
³«ÀßÆü
+
\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü
") ;; FIXME: Care when the owner has seceded. (defconst mixi-community-owner-regexp - "´ÉÍý¿Í - - -") + "
¥«¥Æ¥´¥ê
+
\\(.+\\)
") (defconst mixi-community-members-regexp - " -") + "
¥á¥ó¥Ð¡¼¿ô
+
\\([0-9]+\\)¿Í
") (defconst mixi-community-open-level-regexp - " -") + "
»²²Ã¾ò·ï¤È
¸ø³«¥ì¥Ù¥ë
+
\\(.+\\)
") (defconst mixi-community-authority-regexp - " -") +") (defconst mixi-community-description-regexp - "") + "
+

\\(.+\\)

") (defun mixi-realize-community (community) "Realize a COMMUNITY." @@ -1657,7 +1650,7 @@ Increase this value when unexpected error frequently occurs." (defconst mixi-community-list-id-regexp "\\(.+\\)([0-9]+)") + "\\(.+\\)([0-9]+)") ;;;###autoload (defun mixi-get-communities (&rest friend-or-range) @@ -1692,9 +1685,7 @@ Increase this value when unexpected error frequently occurs." "&category_id=0")) (defconst mixi-search-community-list-regexp - "
- -") + "
\\(.+\\) ([0-9]+)") ;; FIXME: Support category. ;;;###autoload @@ -1736,15 +1727,16 @@ Increase this value when unexpected error frequently occurs." "&comm_id=" (mixi-community-id (mixi-topic-community ,topic)))) (defconst mixi-topic-community-regexp - "
") -(defconst mixi-topic-time-regexp - "") + "
+

\\(.+\\) ¥È¥Ô¥Ã¥¯

") (defconst mixi-topic-title-regexp - "
") + "\\([^<]+\\)") +(defconst mixi-topic-time-regexp + "\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\)") (defconst mixi-topic-owner-regexp - "
+ "
´ÉÍý¿Í
+
\\(.*\\)") (defconst mixi-community-category-regexp - "
¥«¥Æ¥´¥ê -\\(.+\\) -¥á¥ó¥Ð¡¼¿ô -\\([0-9]+\\)¿Í -»²²Ã¾ò·ï¤È
¸ø³«¥ì¥Ù¥ë
-\\(.+\\) -¥È¥Ô¥Ã¥¯ºîÀ®¤Î¸¢¸Â + "
¥È¥Ô¥Ã¥¯¤Î
ºîÀ®¸¢¸Â
+
\\(.+\\) -
\\(.+\\)¥³¥ß¥å¥Ë¥Æ¥£Ì¾\\([^<]+\\)
\\[\\(.+\\)\\] ¥È¥Ô¥Ã¥¯\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü
\\([0-9]+\\):\\([0-9]+\\)
 \\([^<]+\\)  \\(.*?\\)\\(¤µ¤ó\\)?") + "
\\(.*?\\)\\(¤µ¤ó\\)?") (defconst mixi-topic-content-regexp - "") -(defconst mixi-event-time-regexp - "") + "
+

\\(.+\\) ¥¤¥Ù¥ó¥È

") (defconst mixi-event-title-regexp - "
") -(defconst mixi-event-owner-regexp - " -") + "
³«ºÅÆü»þ
+
\\(.+\\)
") (defconst mixi-event-place-regexp - " -") + "
³«ºÅ¾ì½ê
+
\\(.+\\)
") +(defconst mixi-event-owner-regexp + "
\\(.*\\)
") +(defconst mixi-event-owner-seceded-regexp + "
\\((mixi Âà²ñºÑ)\\)
") (defconst mixi-event-detail-regexp - " - -?") + "
Ê罸´ü¸Â
+
\\(.+\\)
") (defconst mixi-event-members-regexp - " -
\\(\\(.\\|\r?\n\\)*?\\)
") + "
\\(\\(.\\|\r?\n\\)*?\\)
") (defun mixi-realize-topic (topic &optional page) "Realize a TOPIC." @@ -1755,6 +1747,9 @@ Increase this value when unexpected error frequently occurs." (mixi-community-set-name (mixi-topic-community topic) (match-string 1)) (mixi-realization-error 'cannot-find-community topic)) + (if (re-search-forward mixi-topic-title-regexp nil t) + (mixi-topic-set-title topic (match-string 1)) + (mixi-realization-error 'cannot-find-title topic)) (if (re-search-forward mixi-topic-time-regexp nil t) (mixi-topic-set-time topic (encode-time 0 (string-to-number (match-string 5)) @@ -1763,9 +1758,6 @@ Increase this value when unexpected error frequently occurs." (string-to-number (match-string 2)) (string-to-number (match-string 1)))) (mixi-realization-error 'cannot-find-time topic)) - (if (re-search-forward mixi-topic-title-regexp nil t) - (mixi-topic-set-title topic (match-string 1)) - (mixi-realization-error 'cannot-find-title topic)) (if (re-search-forward mixi-topic-owner-regexp nil t) (mixi-topic-set-owner topic (mixi-make-friend (match-string 1) (match-string 2))) @@ -1912,44 +1904,31 @@ Increase this value when unexpected error frequently occurs." "&comm_id=" (mixi-community-id (mixi-event-community ,event)))) (defconst mixi-event-community-regexp - "
\\[\\(.+\\)\\] ¥¤¥Ù¥ó¥È -?\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü
-?\\([0-9]+\\):\\([0-9]+\\) -
 \\([^<]+\\) \\(.*\\)") -(defconst mixi-event-owner-seceded-regexp - " \\((mixi Âà²ñºÑ)\\)") + "\\([^<]+\\)") +(defconst mixi-event-time-regexp + "\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\)") (defconst mixi-event-date-regexp - "³«ºÅÆü»þ - \\(.+\\) -³«ºÅ¾ì½ê - \\(.+\\) -¾ÜºÙ -
\\(\\(.\\|\r?\n\\)*?\\)
") + "
\\(\\(.\\|\r?\n\\)*?\\)
+") (defconst mixi-event-limit-regexp - "
Ê罸´ü¸Â \\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü»²²Ã¼Ô - -? -? - - -?") + "
»²²Ã¼Ô
+
\\(.+\\)
") (defun mixi-realize-event (event &optional page) "Realize a EVENT." @@ -1961,6 +1940,9 @@ Increase this value when unexpected error frequently occurs." (mixi-community-set-name (mixi-event-community event) (match-string 1)) (mixi-realization-error 'cannot-find-community event)) + (if (re-search-forward mixi-event-title-regexp nil t) + (mixi-event-set-title event (match-string 1)) + (mixi-realization-error 'cannot-find-title event)) (if (re-search-forward mixi-event-time-regexp nil t) (mixi-event-set-time event (encode-time 0 (string-to-number (match-string 5)) @@ -1969,9 +1951,12 @@ Increase this value when unexpected error frequently occurs." (string-to-number (match-string 2)) (string-to-number (match-string 1)))) (mixi-realization-error 'cannot-find-time event)) - (if (re-search-forward mixi-event-title-regexp nil t) - (mixi-event-set-title event (match-string 2)) - (mixi-realization-error 'cannot-find-title event)) + (if (re-search-forward mixi-event-date-regexp nil t) + (mixi-event-set-date event (match-string 1)) + (mixi-realization-error 'cannot-find-date event)) + (if (re-search-forward mixi-event-place-regexp nil t) + (mixi-event-set-place event (match-string 1)) + (mixi-realization-error 'cannot-find-place event)) (if (re-search-forward mixi-event-owner-regexp nil t) (mixi-event-set-owner event (mixi-make-friend (match-string 1) (match-string 2))) @@ -1979,20 +1964,12 @@ Increase this value when unexpected error frequently occurs." (mixi-event-set-owner event (mixi-make-friend nil (match-string 1))) (mixi-realization-error 'cannot-find-owner event))) - (if (re-search-forward mixi-event-date-regexp nil t) - (mixi-event-set-date event (match-string 1)) - (mixi-realization-error 'cannot-find-date event)) - (if (re-search-forward mixi-event-place-regexp nil t) - (mixi-event-set-place event (match-string 1)) - (mixi-realization-error 'cannot-find-place event)) (if (re-search-forward mixi-event-detail-regexp nil t) (mixi-event-set-detail event (match-string 1)) (mixi-realization-error 'cannot-find-detail event)) - (when (re-search-forward mixi-event-limit-regexp nil t) - (mixi-event-set-limit - event (encode-time 0 0 0 (string-to-number (match-string 3)) - (string-to-number (match-string 2)) - (string-to-number (match-string 1))))) + (if (re-search-forward mixi-event-limit-regexp nil t) + (mixi-event-set-limit event (match-string 1)) + (mixi-realization-error 'cannot-find-limit event)) (if (re-search-forward mixi-event-members-regexp nil t) (mixi-event-set-members event (match-string 1)) (mixi-realization-error 'cannot-find-members event)))) @@ -2169,7 +2146,7 @@ Increase this value when unexpected error frequently occurs." "&id=" (mixi-community-id ,community))) (defconst mixi-bbs-list-regexp - "") + "
") ;;;###autoload (defun mixi-get-new-bbses (&optional range) @@ -2222,7 +2199,7 @@ Increase this value when unexpected error frequently occurs." "&community_id=0&category_id=0")) (defconst mixi-search-bbs-list-regexp - "¾ÜºÙ¤ò¸«¤ë") + "") ;; FIXME: Support community and category. ;;;###autoload @@ -2291,32 +2268,31 @@ Increase this value when unexpected error frequently occurs." ;; FIXME: Split regexp to time, owner(id and nick) and contents. (defconst mixi-diary-comment-list-regexp - "
- - - - - - - - - - -") +") (defun mixi-event-comment-list-page (event) (concat "/view_event.pl?page=all" @@ -2360,32 +2316,13 @@ Increase this value when unexpected error frequently occurs." ;; FIXME: Split regexp to time, owner(id and nick) and contents. (defconst mixi-event-comment-list-regexp - " -\\) -\\( - - - -") + "\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\) +
+
+
\\(.*\\)
+
+\\(\\(.\\|\r?\n\\)*?\\) +
") ;;;###autoload (defun mixi-get-comments (parent &optional range) @@ -2403,23 +2340,42 @@ Increase this value when unexpected error frequently occurs." (setq page nil)) (let ((items (mixi-get-matched-items page regexp range t))) (mapcar (lambda (item) - (mixi-make-comment parent (mixi-make-friend - (nth 7 item) (nth 8 item)) - (encode-time - 0 - (string-to-number (nth 4 item)) - (string-to-number (nth 3 item)) - (string-to-number (nth 2 item)) - (string-to-number (nth 1 item)) - (string-to-number (nth 0 item))) - (nth 10 item))) + (let (owner-id owner-nick year month day hour minute content) + (if (eq (mixi-object-class parent) 'mixi-diary) + (progn + (setq owner-id (nth 1 item)) + (setq owner-nick (nth 2 item)) + (setq year (nth 3 item)) + (setq month (nth 4 item)) + (setq day (nth 5 item)) + (setq hour (nth 6 item)) + (setq minute (nth 7 item)) + (setq content (nth 8 item))) + (setq owner-id (nth 5 item)) + (setq owner-nick (nth 6 item)) + (setq year (nth 0 item)) + (setq month (nth 1 item)) + (setq day (nth 2 item)) + (setq hour (nth 3 item)) + (setq minute (nth 4 item)) + (setq content (nth 7 item))) + (mixi-make-comment parent (mixi-make-friend owner-id + owner-nick) + (encode-time + 0 + (string-to-number minute) + (string-to-number hour) + (string-to-number day) + (string-to-number month) + (string-to-number year)) + content))) items)))) (defmacro mixi-new-comment-list-page () `(concat "/new_comment.pl?page=%d")) (defconst mixi-new-comment-list-regexp - "") + "") ;;;###autoload (defun mixi-get-new-comments (&optional range) @@ -2805,7 +2761,6 @@ Increase this value when unexpected error frequently occurs." `(concat "http://news.mixi.jp/view_news.pl?id=" (mixi-news-id ,news) "&media_id=" (mixi-news-media-id ,news))) - (defconst mixi-news-finished-regexp "¿½¤·Ìõ¤´¤¶¤¤¤Þ¤»¤ó¤¬¡¢¤³¤Î¥Ë¥å¡¼¥¹¤Ï·ÇºÜ¤¬½ªÎ»¤·¤¿¤«¡¢URL¤¬´Ö°ã¤Ã¤Æ¤¤¤¤¤ë¤¿¤á¤´Í÷¤¤¤¿¤À¤±¤Þ¤»¤ó¡£") (defconst mixi-news-title-regexp
 \\(.+\\) -\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü
\\([0-9]+\\):\\([0-9]+\\)\\(
- -\\|\\) -
- - -\\( - -
\\) -\\(.*\\) + "\\( +\\|\\)\\(.*\\) + -\\(| ]+>ºï½ü +\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\) -\\|\\)
-
- - -
+ +? + + + + + + + + + + + + + +? +
\\(.+\\) -
") +") (defun mixi-topic-comment-list-page (topic) (concat "/view_bbs.pl?page=all" @@ -2325,33 +2301,13 @@ Increase this value when unexpected error frequently occurs." ;; FIXME: Split regexp to time, owner(id and nick) and contents. (defconst mixi-topic-comment-list-regexp - "
-\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü
-\\([0-9]+\\):\\([0-9]+\\)
-\\( -\\|\\)
  -[^<]+:  -\\( -\\|\\) *\\(.*\\) - -?\\( - -\\|ºï½ü -\\|\\)
- - - - -
+ "\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\) +
+
+
\\(.*\\)
+
\\(\\(.\\|\r?\n\\)*?\\) -
-
-\\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü
-\\([0-9]+\\):\\([0-9]+\\)
-\\(
\\) -[^<]+ : -\\(.*\\) - -\\(| -ºï½ü - -\\|\\)
- - - - -
- -\\(.+\\) -
-