TnyPlatformFactory

TnyPlatformFactory — A factory that returns implementations for a platform

Synopsis




                    TnyPlatformFactory;
                    TnyPlatformFactoryIface;
TnyAccountStore*    tny_platform_factory_new_account_store
                                                        (TnyPlatformFactory *self);
TnyDevice*          tny_platform_factory_new_device     (TnyPlatformFactory *self);
TnyMsgView*         tny_platform_factory_new_msg_view   (TnyPlatformFactory *self);
TnyMsg*             tny_platform_factory_new_msg        (TnyPlatformFactory *self);
TnyMimePart*        tny_platform_factory_new_mime_part  (TnyPlatformFactory *self);
TnyPasswordGetter*  tny_platform_factory_new_password_getter
                                                        (TnyPlatformFactory *self);

Object Hierarchy


  GInterface
   +----TnyPlatformFactory

Prerequisites

TnyPlatformFactory requires GObject.

Description

A factory type that returns specific implementations for a specific platform.

Details

TnyPlatformFactory

typedef struct _TnyPlatformFactory TnyPlatformFactory;


TnyPlatformFactoryIface

typedef struct {
	GTypeInterface parent;

	TnyAccountStore* (*new_account_store_func) (TnyPlatformFactory *self);
	TnyDevice* (*new_device_func) (TnyPlatformFactory *self);
	TnyMsgView* (*new_msg_view_func) (TnyPlatformFactory *self);
	TnyMsg* (*new_msg_func) (TnyPlatformFactory *self);
	TnyMimePart* (*new_mime_part_func) (TnyPlatformFactory *self);
	TnyPasswordGetter* (*new_password_getter_func) (TnyPlatformFactory *self);
} TnyPlatformFactoryIface;


tny_platform_factory_new_account_store ()

TnyAccountStore*    tny_platform_factory_new_account_store
                                                        (TnyPlatformFactory *self);

Create a new TnyAccountStore instance. The returned instance must be unreferenced after use.

Implementors: when implementing a platform-specific library, return a new TnyAccountStore instance. It's allowed to reuse one instance, just make sure that you add a reference then.

self : a TnyPlatformFactory object
Returns : a TnyAccountStore instance

tny_platform_factory_new_device ()

TnyDevice*          tny_platform_factory_new_device     (TnyPlatformFactory *self);

Create a new TnyDevice instance. The returned instance must be unreferenced after use.

Implementors: when implementing a platform-specific library, return a new TnyDevice instance. It's allowed to reuse one instance, just make sure that you add a reference then.

self : a TnyPlatformFactory object
Returns : a TnyDevice instance

tny_platform_factory_new_msg_view ()

TnyMsgView*         tny_platform_factory_new_msg_view   (TnyPlatformFactory *self);

Create a new TnyMsgView instance. The returned instance must be unreferenced after use.

Implementors: when implementing a platform-specific library, return a new TnyMsgView instance. It's allowed to reuse one instance, just make sure that you add a reference then.

self : a TnyPlatformFactory object
Returns : a TnyMsgView instance

tny_platform_factory_new_msg ()

TnyMsg*             tny_platform_factory_new_msg        (TnyPlatformFactory *self);

Create a new TnyMsg instance. The returned instance must be unreferenced after use.

Implementors: when implementing a platform-specific library, return a new TnyMsg instance.

self : a TnyPlatformFactory object
Returns : a TnyMsg instance

tny_platform_factory_new_mime_part ()

TnyMimePart*        tny_platform_factory_new_mime_part  (TnyPlatformFactory *self);

Create a new TnyMimePart instance. The returned instance must be unreferenced after use.

Implementors: when implementing a platform-specific library, return a new TnyMimePart instance.

self : a TnyPlatformFactory object
Returns : a TnyMimePart instance

tny_platform_factory_new_password_getter ()

TnyPasswordGetter*  tny_platform_factory_new_password_getter
                                                        (TnyPlatformFactory *self);

Create a new TnyPasswordGetter instance. The returned instance must be unreferenced after use.

Implementors: when implementing a platform-specific library, return a new TnyPasswordGetter instance.

self : a TnyPlatformFactory object
Returns : a TnyPasswordGetter instance

See Also

TnyDevice, TnyMsgView, TnySaveStrategy, TnyAccountStore