Classes | Typedefs | Functions
gen/gui_factory_friend_gen.h File Reference
#include "gui_factory_gen.h"

Go to the source code of this file.

Classes

struct  gui_factory_st_
struct  gui_factory_vtable_st_

Typedefs

typedef struct
gui_factory_private_st_
gui_factory_private_handle
typedef struct gui_factory_st_ gui_factory_st
typedef button_handle(* gui_factory_create_button_fn )(gui_factory_handle gui_factory_h)
typedef void(* gui_factory_delete_fn )(gui_factory_handle gui_factory_h)
typedef struct
gui_factory_vtable_st_ 
gui_factory_vtable_st

Functions

bool gui_factory_set_vtable (gui_factory_handle gui_factory_h, gui_factory_vtable_st *vtable)
void gui_factory_friend_delete (gui_factory_handle gui_factory_h)
bool gui_factory_init (gui_factory_handle gui_factory_h)

Detailed Description

Author:
Matt Miller <matt@matthewmiller.net>

LICENSE

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

DESCRIPTION

This is the friend interface for the gui_factory class. It should only be included by implementors of the gui_factory interface.

Definition in file gui_factory_friend_gen.h.


Typedef Documentation

Virtual function declaration.

Definition at line 43 of file gui_factory_friend_gen.h.

typedef void(* gui_factory_delete_fn)(gui_factory_handle gui_factory_h)

Virtual function declaration.

Definition at line 49 of file gui_factory_friend_gen.h.

Opaque pointer to reference private data for the class

Definition at line 31 of file gui_factory_friend_gen.h.

Friend accessible data for this class

The virtual table to be specified by friend classes.

See also:
gui_factory_set_vtable()

Function Documentation

void gui_factory_friend_delete ( gui_factory_handle  gui_factory_h)

Allow a friend class to delete the gui_factory object. It is assumed that the friend class is managing the memory for the gui_factory object and, thus, the object will not be freed. However, members within the gui_factory object may be freed. This does not call the virtual function table version of delete, but rather the delete specifically for type gui_factory.

Parameters:
gui_factory_hThe object. If NULL, then this function is a no-op.
See also:
gui_factory_delete()

Definition at line 75 of file gui_factory_gen.c.

bool gui_factory_init ( gui_factory_handle  gui_factory_h)

Allows a friend class to initialize their inner gui_factory object. Must be called before the gui_factory object is used. If an error is returned, any clean-up was handled internally and there is no need to call a delete function.

Parameters:
gui_factory_hThe object
Returns:
TRUE on success, FALSE otherwise
See also:
gui_factory_delete()
gui_factory_friend_delete()

Definition at line 200 of file gui_factory_gen.c.

bool gui_factory_set_vtable ( gui_factory_handle  gui_factory_h,
gui_factory_vtable_st vtable 
)

This is a function used by implementing classes to set the virtual table according with their methods.

Parameters:
gui_factory_hThe object
vtableThe virtual table specification for the implementing class. If any function pointer is NULL, an error is returned.
Returns:
TRUE on success, FALSE otherwise

Definition at line 169 of file gui_factory_gen.c.

 All Classes Files Functions Variables Typedefs