Commit Graph

27 Commits

Author SHA1 Message Date
e3970d1396 define a set of CAMEL_SERVICE_URL_ALLOW_* flags parallel to the _NEED_*
* camel-service.h: define a set of CAMEL_SERVICE_URL_ALLOW_* flags
	parallel to the _NEED_* flags, and make the _NEED_* flags imply
	the _ALLOW_* ones.

	* providers/imap/camel-imap-store.c (camel_imap_store_init): imap
	urls ALLOW_PATH

svn path=/trunk/; revision=4147
2000-07-13 17:17:56 +00:00
98753e92d2 New method, to return an end-user-friendly name corresponding to a
* camel-service.c (camel_service_get_name): New method, to return
	an end-user-friendly name corresponding to a service. (eg, "POP
	service for danw on trna.helixcode.com").

	* providers/imap/camel-imap-store.c,
	providers/mbox/camel-mbox-store.c,
	providers/nntp/camel-nntp-store.c,
	providers/pop3/camel-pop3-store.c,
	providers/sendmail/camel-sendmail-transport.c,
	providers/smtp/camel-smtp-transport.c: Implement.

svn path=/trunk/; revision=3851
2000-07-01 23:07:18 +00:00
a0b7ca18e2 Remove camel_service_connect_with_url. (URLs must be specified when the
* camel-service.c: Remove camel_service_connect_with_url. (URLs
	must be specified when the service is requested from the session,
	so that there can only ever be one service for any URL.)

svn path=/trunk/; revision=3584
2000-06-15 23:05:18 +00:00
631dda8ae0 Init filter_from to NULL, for exception case. (mbox_get_message_by_uid):
2000-05-30  Not Zed  <NotZed@HelixCode.com>

        * providers/mbox/camel-mbox-folder.c (mbox_append_message): Init
        filter_from to NULL, for exception case.
        (mbox_get_message_by_uid): Cast off_t to long int for diagnostics.

        * camel-url.c (camel_url_hash): Hash funciton for using camel
        url's as hash keys.
        (camel_url_equal): equal function for same.

        * camel-session.c (camel_session_finalise): Free cached services.
        (camel_session_init): Init service cache.
        (service_cache_remove): destroy callback to remove a service from
        the cache.

        * camel-store.c (get_folder_internal): Remove the extra ref of the
        folder.  That seems the right behaviour ...?
        (camel_store_get_type): Doh, actually call store init, so the
        cache works.
        (cache_folder): strdup the folder name!  no wonder it never found
        it again.

svn path=/trunk/; revision=3298
2000-05-30 22:35:40 +00:00
580d885820 Make camel not leak like a sieve.
* camel-object.c: New subclass of GtkObject which is now the base
	of the Camel object hierarchy. Currently the only difference
	between CamelObject and GtkObject is that CamelObjects don't start
	out floating.

	* *.h: Move a bunch of typedefs to camel-types.h. Standardize on
	using <camel/foo.h> in header files rather than <foo.h>, "foo.h",
	or "camel/foo.h". Remove some unneeded includes.

	* camel-address.c, camel-data-wrapper.c, camel-folder-search.c,
	camel-folder-summary.c, camel-folder.c, camel-mime-filter.c,
	camel-mime-parser.c, camel-service.c, camel-session.c,
	camel-stream.c: These are now subclasses of CamelObject.

	* camel-data-wrapper.c (set_output_stream):
	* camel-medium.c (set_content_object):
	* camel-seekable-substream.c
	(init_with_seekable_stream_and_bounds):
	* providers/mbox/camel-mbox-folder.c (mbox_get_message_by_uid):
	remove gtk_object_sink calls.

	* camel-stream-buffer.c (init_vbuf):
	* camel-stream-filter.c (camel_stream_filter_new_with_stream):
	ref the original stream.

	* camel-folder-summary.c (camel_folder_summary_finalise): unref
	the filters when finalizing.

	* camel-mime-part-utils.c
	(simple_data_wrapper_construct_from_parser,
	camel_mime_part_construct_content_from_parser):
	* camel-mime-part.c (camel_mime_part_set_content): Unref objects
	that are created only to be handed off to other objects. If
	they're going to be needed later, they will have been additionally
	ref'ed by the object that needs them.

	* providers/pop3/camel-pop3-folder.c (get_message_by_number):
	unref the message stream after creating the data from it.

	* camel-stream.c, camel-stream-buffer.c, camel-stream-filter.c,
	camel-stream-fs.c, camel-stream-mem.c: Remove camel_stream_close,
	since its semantics are dubious (what happens when you close a
	stream other people still have references on?).

	* providers/nntp/camel-nntp-store.c:
	* providers/smtp/camel-smtp-transport.c:
	* providers/pop3/camel-pop3-store.c:
	replace camel_stream_close calls with gtk_object_unref.

	* providers/mbox/camel-mbox-folder.c:
	* providers/nntp/camel-nntp-folder.c:
	* providers/sendmail/camel-sendmail-transport.c:
	replace camel_stream_close with camel_stream_flush +
	gtk_object_unref

svn path=/trunk/; revision=2882
2000-05-07 21:56:32 +00:00
ba6b73fe56 New function to replace camel_provider_scan. Returns a list of either (a)
* camel-session.c (camel_session_list_providers): New function to
        replace camel_provider_scan. Returns a list of either (a) all
        currently-loaded providers, or (b) all available providers.

        * camel-url.[ch]: Add an "empty" flag to CamelURL (indicating that
        it contains only a protocol).

        * camel-service.c (camel_service_query_auth_types): Make this take
        a CamelException (since it may have to try to connect to the
        server, and it might not able to.)

        * providers/pop3/camel-pop3-store.c: add KPOP (Kerberized POP)
        support. This is mostly so I have two kinds of authmech to play
        with instead of just one. (But it does actually work.)

        * providers/smtp/camel-smtp-transport.c (query_auth_types): update
        for prototype change, but disable the functionality, since it
        doesn't really support any auth types yet.
        (camel_smtp_transport_get_type): add an object init function to
        set the service url_flags.

svn path=/trunk/; revision=2797
2000-05-04 15:23:43 +00:00
2e4a546307 the URL RFC says the port must be numeric, so we don't want to do
* g_url_new really wanted to take a CamelException. So, rename
	Gurl to CamelURL, g_url_* to camel_url_* (with camel_url_new
	taking an exception), and url-util.[ch] to camel-url.[ch]. Also
	force url->port to be numeric and remove camel_service_getport. (I
	was confused before: the URL RFC says the port must be numeric, so
	we don't want to do getportbyname.)

svn path=/trunk/; revision=2300
2000-04-06 03:52:39 +00:00
2076526774 convenience functions to canonicalize the host and port values of a
* camel-service.c (camel_service_gethost,
	camel_service_getport): convenience functions to canonicalize
	the host and port values of a service's URL.
	* providers/pop3/camel-pop3-store.c: use them

svn path=/trunk/; revision=2216
2000-03-28 20:51:58 +00:00
07f3a40ef0 new routine to free the data allocated by camel_service_query_auth_types.
* camel-service.c (camel_service_free_auth_types): new routine to
	free the data allocated by camel_service_query_auth_types.

	* providers/pop3/camel-pop3-store.c (free_auth_types): implement

svn path=/trunk/; revision=2190
2000-03-27 16:59:46 +00:00
425b07fa74 New function to query a service for the authentication protocols it
* camel-service.c (camel_service_query_auth_types): New function
	to query a service for the authentication protocols it supports.
	* providers/pop3/camel-pop3-store.c (query_auth_types): implement

svn path=/trunk/; revision=2147
2000-03-22 21:47:21 +00:00
7a2e799ad0 cosmetic changes.
2000-03-10  bertrand  <bertrand@helixcode.com>

	* camel-service.h: cosmetic changes.

svn path=/trunk/; revision=2098
2000-03-11 02:26:08 +00:00
1e7ab47d26 fix the name of "Helix Code, Inc." in all the copyrights
svn path=/trunk/; revision=2091
2000-03-09 19:52:48 +00:00
d3d2adb98c add CamelExceptions to several functions. Use camel_session_new to
* camel-session.h:
        * camel-session.c: add CamelExceptions to several functions. Use
        camel_session_new to initialize the session and URL fields of
        created CamelStores as appropriate.

        * camel-store.h:
        * camel-store.c
        * camel-service.h:
        * camel-service.c: Move the session and url (and associated
        functions) from CamelStore to CamelService. Add url_flags to
        CamelService so subclasses can specify which URL components
        are mandatory for them. Add camel_session_new for
        camel_session_get_store* to use.

        * providers/mbox/camel-mbox-folder.c:
        * providers/mbox/camel-mbox-store.c:
        * providers/mbox/camel-mbox-store.h: Update for above changes.

svn path=/trunk/; revision=1888
2000-02-21 18:38:58 +00:00
e72c45d304 New header with the typedefs for all camel classes. Now the class headers
* camel/camel-types.h: New header with the typedefs for all camel
	classes. Now the class headers can just include this and the
	header for the parent type. This makes it possible for
	CamelService to include a CamelSession without creating an
	#include loop.

	* camel/*:
	* composer/e-msg-composer-attachment-bar.h:
	* mail/folder-browser.c:
	* mail/message-list.c: frob #includes to match the new reality

svn path=/trunk/; revision=1850
2000-02-19 01:40:57 +00:00
0996e4f1ac Make camel-service use a Gurl internally. Remove the login/password
interfaces and instead provide camel_service_connect_with_url.

Also, added CamelExceptions and return values, so the functions can
indicate failure to the caller if they can't connect.

svn path=/trunk/; revision=1834
2000-02-17 22:16:00 +00:00
316a4c47ff Updated my e-mail address to reflect my new employment
svn path=/trunk/; revision=1533
2000-01-03 23:05:55 +00:00
331335d12c Fix copyright informations once again
svn path=/trunk/; revision=1489
1999-12-14 22:40:38 +00:00
9663037f6c More work:
- Fixed some Camel API naming issues.
- Moved the message composer stuff to the `composer' directory.

svn path=/trunk/; revision=1395
1999-11-17 15:35:43 +00:00
8fe1aa5f41 Copyright change
svn path=/trunk/; revision=1348
1999-10-23 15:19:51 +00:00
d938232d3c Address update
svn path=/trunk/; revision=1147
1999-08-29 22:13:34 +00:00
cac0ba57e6 merge a lot of work. Rough ChangeLog will follow
svn path=/trunk/; revision=1052
1999-08-01 13:38:28 +00:00
9a472934f5 new method.
1999-05-04  bertrand <Bertrand.Guiheneuf@inria.fr>

	* camel/camel-service.c (camel_service_get_url):
	new method.

	* devel-docs/camel/camel-sections.txt: added
	function doc references

	* camel/camel-folder.c (__camel_folder_close):
	fixed indentation.
	(camel_folder_expunge): new method.
	(__camel_folder_close): used expunge flag

svn path=/trunk/; revision=890
1999-05-04 18:49:25 +00:00
eb2c9a6024 basic provider structure. Have to write the code for dynamic loading.
1999-04-25  bertrand <Bertrand.Guiheneuf@inria.fr>

	* camel/camel-provider.[ch]:
	basic provider structure. Have to write the
	code for dynamic loading.

svn path=/trunk/; revision=876
1999-04-25 09:45:13 +00:00
50b8c2c0af A first attempt at setting up the documentation system.
svn path=/trunk/; revision=862
1999-04-21 12:56:28 +00:00
94dc5be053 now CamelStore inherits from CamelService.
1999-04-20  bertrand <Bertrand.Guiheneuf@inria.fr>

	* camel/camel-store.h: now CamelStore inherits from
	CamelService.

svn path=/trunk/; revision=861
1999-04-20 20:36:26 +00:00
bba607613c basic abstract service class.
1999-04-20  bertrand <Bertrand.Guiheneuf@inria.fr>

	* camel/camel-service.c (camel_service_class_init):
	basic abstract service class.

svn path=/trunk/; revision=860
1999-04-20 20:23:48 +00:00
9fc7c06fc4 simple service class added
svn path=/trunk/; revision=859
1999-04-20 18:31:34 +00:00