This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$service = 'Amazon'; | |
chdir(__DIR__); | |
`git clone ./zf2 ZendService{$service}-library`; | |
`git clone ./zf2 ZendService{$service}-tests`; | |
chdir(__DIR__ . '/ZendService' . $service . '-library'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Coordinate | |
{ | |
protected $x; | |
protected $y; | |
public function __construct($x = null, $y = null) | |
{ | |
(empty($x)) ?: $this->setX($x); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/php | |
<?php | |
/** | |
* Because you want "tree", but cannot find the source code quick enough | |
* on the web to compile for OS.X or there is no suitable implementation | |
* on windows. | |
*/ | |
// set error reporting | |
error_reporting(E_STRICT | E_ALL); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
setup(); | |
$t = new Tree('top', 'T'); | |
$t->append(new TreeNode('one', 1)); | |
$t->append($x = new TreeNode('two', 2)); | |
$t->append(new TreeNode('three', 3)); | |
$t->append(new TreeNode('foo', 'foo')); |
NewerOlder