Skip to content
This repository has been archived by the owner on Jan 31, 2020. It is now read-only.

Commit

Permalink
Merge branch 'master' into acceptHandling
Browse files Browse the repository at this point in the history
Conflicts:
	library/Zend/Http/Header/AbstractAccept.php
	library/Zend/Http/Header/AcceptEncoding.php
	library/Zend/Http/Header/AcceptLanguage.php
	tests/Zend/Http/Header/AcceptCharsetTest.php
	tests/Zend/Http/Header/AcceptEncodingTest.php
	tests/Zend/Http/Header/AcceptLanguageTest.php
	tests/Zend/Http/Header/AcceptTest.php
  • Loading branch information
Freeaqingme committed Jul 14, 2012
5 parents 8d7b1b5 + 9acf647 + 33f48c3 + db34ff9 + c4d0f17 commit f6b222a
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 16 deletions.
2 changes: 1 addition & 1 deletion src/Cloud.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public function appendTag($tag)
if ($tag instanceof TaggableInterface) {
$tags[] = $tag;
return $this;
}
}

if (!is_array($tag)) {
throw new Exception\InvalidArgumentException(sprintf(
Expand Down
8 changes: 4 additions & 4 deletions src/Cloud/Decorator/DecoratorInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,16 @@ interface DecoratorInterface
* Constructor
*
* Allow passing options to the constructor.
*
* @param mixed $options
*
* @param mixed $options
* @return void
*/
public function __construct($options = null);

/**
* Render a list of tags
*
* @param mixed $tags
*
* @param mixed $tags
* @return string
*/
public function render($tags);
Expand Down
8 changes: 4 additions & 4 deletions src/Cloud/DecoratorPluginManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* Plugin manager implementation for decorators.
*
* Enforces that decorators retrieved are instances of
* Decorator\DecoratorInterface. Additionally, it registers a number of default
* Decorator\DecoratorInterface. Additionally, it registers a number of default
* decorators available.
*
* @category Zend
Expand All @@ -28,7 +28,7 @@ class DecoratorPluginManager extends AbstractPluginManager
{
/**
* Default set of decorators
*
*
* @var array
*/
protected $invokableClasses = array(
Expand All @@ -42,8 +42,8 @@ class DecoratorPluginManager extends AbstractPluginManager
*
* Checks that the decorator loaded is an instance
* of Decorator\DecoratorInterface.
*
* @param mixed $plugin
*
* @param mixed $plugin
* @return void
* @throws Exception\InvalidArgumentException if invalid
*/
Expand Down
12 changes: 8 additions & 4 deletions src/ItemList.php
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,8 @@ public function rewind()
* @param mixed $offset
* @return boolean
*/
public function offsetExists($offset) {
public function offsetExists($offset)
{
return array_key_exists($offset, $this->_items);
}

Expand All @@ -187,7 +188,8 @@ public function offsetExists($offset) {
* @param mixed $offset
* @return TaggableInterface
*/
public function offsetGet($offset) {
public function offsetGet($offset)
{
return $this->_items[$offset];
}

Expand All @@ -199,7 +201,8 @@ public function offsetGet($offset) {
* @throws OutOfBoundsException When item does not implement Zend\Tag\TaggableInterface
* @return void
*/
public function offsetSet($offset, $item) {
public function offsetSet($offset, $item)
{
// We need to make that check here, as the method signature must be
// compatible with ArrayAccess::offsetSet()
if (!($item instanceof TaggableInterface)) {
Expand All @@ -219,7 +222,8 @@ public function offsetSet($offset, $item) {
* @param mixed $offset
* @return void
*/
public function offsetUnset($offset) {
public function offsetUnset($offset)
{
unset($this->_items[$offset]);
}
}
2 changes: 1 addition & 1 deletion test/Cloud/Decorator/HtmlTagTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

use Zend\Tag,
Zend\Tag\Cloud\Decorator,
Zend\Tag\Cloud\Decorator\Exception\InvalidArgumentException;
Zend\Tag\Cloud\Decorator\Exception\InvalidArgumentException;

/**
* @category Zend
Expand Down
4 changes: 2 additions & 2 deletions test/ItemListTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function testSeekableIterator()
$list->seek(2);
$this->assertEquals($list->current()->getTitle(), $values[2]);
}

public function testSeektableIteratorThrowsBoundsException()
{
$list = new Tag\ItemList();
Expand All @@ -66,7 +66,7 @@ public function testSeektableIteratorThrowsBoundsException()
$list[] = $this->_getItem($value);
}
$list->seek(2);

$this->setExpectedException('Zend\Tag\Exception\OutOfBoundsException', 'Invalid seek position');
$list->seek(3);
}
Expand Down

0 comments on commit f6b222a

Please sign in to comment.