Kiwi User Interface Framework  beta
Classes | Functions
KUList.h File Reference

Define KUListItem and KUList data structure. More...

#import <Foundation/Foundation.h>
#import <Coconut/Coconut.h>

Go to the source code of this file.

Classes

struct  KUListItem
 List item to keep the NSObject. More...
struct  KUList
 List of NSObject. More...

Functions

static struct KUListItemKUAllocateListItem (struct CNResource *resource)
 Allocate item of object list.
static void KUInitList (struct KUList *dst)
 Initialize object list.
void KUDestroyList (struct CNResource *resource, struct KUList *dst)
 Destroy the context of the object list.
void KUAddObjectToList (struct KUList *dst, NSObject *src, struct CNResource *resource)
 Add object to the list.

Detailed Description

Define KUListItem and KUList data structure.

Copyright
Copyright (C) 2012 Steel Wheels Project

Function Documentation

static struct KUListItem* KUAllocateListItem ( struct CNResource *  resource) [static, read]

Allocate item of object list.

Returns:
Allocated list item
Parameters:
resourceResource to allocate the list item

References KUListItem::nextItem, and KUListItem::object.

static void KUInitList ( struct KUList dst) [inline, static]

Initialize object list.

Parameters:
dstDestination list

References KUList::firstItem, KUList::itemCount, and KUList::lastItem.

void KUDestroyList ( struct CNResource *  resource,
struct KUList dst 
)

Destroy the context of the object list.

Parameters:
resourceResource to return the unallocated objects
dstDestination object list
void KUAddObjectToList ( struct KUList dst,
NSObject *  src,
struct CNResource *  resource 
)

Add object to the list.

Parameters:
dstDestination list
srcObject to be added
resourceResource to allocate the list