Dockyard > Objective-C Protocols > JSArrayAccessors

JSArrayAccessors

Protocol Description


a workaround for the problem illustrated by: http: *www.ditchnet.org/wp/2005/10/21/report-a-bug-friday/
use a category on WebScriptObject to allow access to the javascript array that it proxies for (if one exists). access is through the typical NSArray access methods, or you can use NSArray arrayWithArray: to convert the whole thing.

By James G. Speth

Methods


- count

- getObjects:range:

- objectAtIndex:

Method Detail


count

- (unsigned)count

Returns the number of objects in the Javascript array.

getObjects:range:

- (void)getObjects:(id *)aBuffer range:(NSRange)aRange

Copies the objects contained in the receiver that fall within the specified range to aBuffer.

objectAtIndex:

- (id)objectAtIndex:(unsigned)index

Returns the object located at index.

This page was generated with DocYouMeant, a program created by Belkadan Software

Valid XHTML 1.0! Valid CSS!