Skip to content

Commit

Permalink
Set visibility of methods where not previously explicit. Also correct…
Browse files Browse the repository at this point in the history
…ed some of the doc blocks
  • Loading branch information
kenguest committed Jan 28, 2012
1 parent bb02714 commit 992d3f8
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 24 deletions.
14 changes: 7 additions & 7 deletions Services/Openstreetmap.php
Expand Up @@ -71,9 +71,9 @@ public static function autoload($class)
* @param array $config Defaults to empty array if none provided
*
* @access protected
* @return void
* @return Services_Openstreetmap
*/
function __construct($config = array())
public function __construct($config = array())
{
if ($config == array()) {
$config = $this->config;
Expand Down Expand Up @@ -107,7 +107,7 @@ function __construct($config = array())
* @access public
* @return array
*/
function bboxToMinMax($minLat, $minLon, $maxLat, $maxLon)
public function bboxToMinMax($minLat, $minLon, $maxLat, $maxLon)
{
return array($minLon, $minLat, $maxLon, $maxLat);
}
Expand All @@ -129,7 +129,7 @@ function bboxToMinMax($minLat, $minLon, $maxLat, $maxLon)
* @return void
*/

function get($minLon, $minLat, $maxLon, $maxLat)
public function get($minLon, $minLat, $maxLon, $maxLat)
{
$config = $this->getConfig();
$url = $config->getValue('server')
Expand All @@ -152,7 +152,7 @@ function get($minLon, $minLat, $maxLon, $maxLat)
* @access public
* @return array
*/
function getCoordsOfPlace($place)
public function getCoordsOfPlace($place)
{
$url = 'http://nominatim.openstreetmap.org/search?q='
. urlencode($place) . '&limit=1&format=xml';
Expand Down Expand Up @@ -197,7 +197,7 @@ public static function getIDs($args)
* @access public
* @return void
*/
function loadXML($file)
public function loadXML($file)
{
$this->xml = file_get_contents($file);
}
Expand All @@ -208,7 +208,7 @@ function loadXML($file)
* @access public
* @return string
*/
function getXML()
public function getXML()
{
return $this->xml;
}
Expand Down
6 changes: 3 additions & 3 deletions Services/Openstreetmap/API/V06.php
Expand Up @@ -104,7 +104,7 @@ public function getTransport()
* @access public
* @return string
*/
function getRelation($relationID, $version = null)
public function getRelation($relationID, $version = null)
{
return $this->getTransport()->getObject('relation', $relationID, $version);
}
Expand Down Expand Up @@ -139,7 +139,7 @@ public function getRelations()
* @access public
* @return string
*/
function getChangeset($id, $version = null)
public function getChangeset($id, $version = null)
{
return $this->getTransport()->getObject('changeset', $id, $version);
}
Expand Down Expand Up @@ -336,7 +336,7 @@ public function getWays()
* @access public
* @return string
*/
function getNode($nodeID, $version = null)
public function getNode($nodeID, $version = null)
{
$node = $this->getTransport()->getObject('node', $nodeID, $version);
if ($node !== false) {
Expand Down
12 changes: 6 additions & 6 deletions Services/Openstreetmap/Config.php
Expand Up @@ -160,9 +160,9 @@ public function getValue($name = null)
* @throws Services_Openstreetmap_Exception If the parameter is unknown
*
* @access public
* @return void
* @return Services_Openstreetmap_Config
*/
function setValue($config, $value = null)
public function setValue($config, $value = null)
{
if (is_array($config)) {
if (isset($config['adapter'])) {
Expand Down Expand Up @@ -218,7 +218,7 @@ function setValue($config, $value = null)
* @access public
* @return Services_Openstreetmap
*/
function setServer($server)
public function setServer($server)
{
try {
$c = $this->getTransport()->getResponse($server . '/api/capabilities');
Expand Down Expand Up @@ -265,7 +265,7 @@ function setServer($server)
* @access public
* @return Services_Openstreetmap
*/
function setPasswordfile($file)
public function setPasswordfile($file)
{
if (is_null($file)) {
return $this;
Expand Down Expand Up @@ -347,7 +347,7 @@ public function asArray()
* @see minVersion
* @see timeout
*
* @return void
* @return boolean
*
* @internal
* @throws Services_Openstreetmap_Exception If the API Version is not
Expand Down Expand Up @@ -513,7 +513,7 @@ public function getMaxElements()
* @param string $attribute name of attribute
* @param mixed $default default value
*
* @return void
* @return string
*/
public function getXMLValue(
SimpleXMLElement $xml,
Expand Down
10 changes: 5 additions & 5 deletions Services/Openstreetmap/Relation.php
Expand Up @@ -34,7 +34,7 @@ class Services_Openstreetmap_Relation extends Services_Openstreetmap_Object
* @access public
* @return void
*/
function getMembers()
public function getMembers()
{
return $this->members;
}
Expand All @@ -43,9 +43,9 @@ function getMembers()
* type
*
* @access public
* @return void
* @return string
*/
function getType()
public function getType()
{
return $this->type;
}
Expand All @@ -57,7 +57,7 @@ function getType()
* @access public
* @return void
*/
function addMember()
public function addMember()
{
}

Expand All @@ -68,7 +68,7 @@ function addMember()
* @access public
* @return void
*/
function removeMember()
public function removeMember()
{
}

Expand Down
6 changes: 3 additions & 3 deletions Services/Openstreetmap/Way.php
Expand Up @@ -35,7 +35,7 @@ class Services_Openstreetmap_Way extends Services_Openstreetmap_Object
* @access public
* @return boolean
*/
function isClosed()
public function isClosed()
{
// Not closed if there's just one node.
// Otherwise a way is considered closed if the first node has
Expand Down Expand Up @@ -80,7 +80,7 @@ public function getNodes()
* @access public
* @return Services_Openstreetmap_Way
*/
function addNode(Services_Openstreetmap_Node $node)
public function addNode(Services_Openstreetmap_Node $node)
{
$id = $node->getId();
$pos = array_search($id, $this->nodes);
Expand All @@ -102,7 +102,7 @@ function addNode(Services_Openstreetmap_Node $node)
* @access public
* @return Services_Openstreetmap_Way
*/
function removeNode($node)
public function removeNode($node)
{
if (empty($this->nodes)) {
$this->nodes = $this->getNodes();
Expand Down

0 comments on commit 992d3f8

Please sign in to comment.