Web API Reference MapGuide Open Source

MgLayer* MgLayerCollection::GetItem CREFSTRING  name  ) 
 

Returns the layer with the specified name.

.Net Syntax
MgLayer GetItem(string name);
Java Syntax
MgLayer GetItem(String name);
PHP Syntax
MgLayer GetItem(string name);

Parameters:
name (String/string) Name of the layer to get.
Returns:
Returns the layer.
Exceptions:
MgObjectNotFoundException if the name does not exist.