forked from GoIntegro/hateoas
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Javier Lorenzana
committed
Nov 22, 2014
1 parent
65dd370
commit f6983f9
Showing
6 changed files
with
95 additions
and
49 deletions.
There are no files selected for viewing
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
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
/** | ||
* @copyright 2014 Integ S.A. | ||
* @license http://opensource.org/licenses/MIT The MIT License (MIT) | ||
* @author Javier Lorenzana <[email protected]> | ||
*/ | ||
|
||
namespace GoIntegro\Bundle\HateoasBundle\Util; | ||
|
||
class ArrayHelper | ||
{ | ||
/** | ||
* @param array $array | ||
* @return boolean | ||
* @todo Move to helper in utils. | ||
* @see http://stackoverflow.com/a/173479 | ||
*/ | ||
public function isAssociative(array $array) | ||
{ | ||
return array_keys($array) !== range(0, count($array) - 1); | ||
} | ||
} |