Re: API Thoughts?

From: Date: Sun, 26 Aug 2001 23:38:50 +0000
Subject: Re: API Thoughts?
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-64368@lists.php.net to get a copy of this message
On Sun, Aug 26, 2001 at 07:29:59PM -0400, Sterling Hughes wrote: > Hey, > extension and was wondering what people thought as more intuitive, > something like: > > $tree = tree_new(AVL_TREE); > tree_insert($tree, $element, "compare_func"); > // ... I prefer this notation. There's more room for future expansion without encroaching on namespace. I think it would be neat to be able to do this, though: $tree = new Tree(AVL_TREE); $tree->insert($element, 'compare_func'); But such a wrapper shouldn't be too difficult to write. -- Jon Parise (jon@csh.rit.edu) . Rochester Inst. of Technology http://www.csh.rit.edu/~jon/ : Computer Science House Member

« previous php.dev (#64368) next »