Commit c4658659 c46586597b134e87d520af4b399c47ac9e074f96 by Sergey Poznyakoff

Added mu-mailbox-get-url.

1 parent 1dca1a5e
...@@ -156,6 +156,21 @@ SCM_DEFINE (mu_mailbox_close, "mu-mailbox-close", 1, 0, 0, ...@@ -156,6 +156,21 @@ SCM_DEFINE (mu_mailbox_close, "mu-mailbox-close", 1, 0, 0,
156 } 156 }
157 #undef FUNC_NAME 157 #undef FUNC_NAME
158 158
159 SCM_DEFINE (mu_mailbox_get_url, "mu-mailbox-get-url", 1, 0, 0,
160 (SCM MBOX),
161 "Returns the URL of the mailbox.")
162 #define FUNC_NAME s_mu_mailbox_get_url
163 {
164 struct mu_mailbox *mum;
165 url_t url;
166
167 SCM_ASSERT (mu_scm_is_mailbox (MBOX), MBOX, SCM_ARG1, FUNC_NAME);
168 mum = (struct mu_mailbox *) SCM_CDR (MBOX);
169 mailbox_get_url (mum->mbox, &url);
170 return scm_makfrom0str (url_to_string (url));
171 }
172 #undef FUNC_NAME
173
159 SCM_DEFINE (mu_mailbox_get_message, "mu-mailbox-get-message", 2, 0, 0, 174 SCM_DEFINE (mu_mailbox_get_message, "mu-mailbox-get-message", 2, 0, 0,
160 (SCM MBOX, SCM MSGNO), "Retrieve from MBOX message # MSGNO.") 175 (SCM MBOX, SCM MSGNO), "Retrieve from MBOX message # MSGNO.")
161 #define FUNC_NAME s_mu_mailbox_get_message 176 #define FUNC_NAME s_mu_mailbox_get_message
......