MapGuide API Reference
|
virtual bool MgFeatureService::TestConnection | ( | MgResourceIdentifier * | resource | ) | [pure virtual] |
Connects to the feature source specified by the resource identifier and verifies that the feature source has been correctly configured and installed in the resource repository. See Connection To Feature Source .
virtual bool TestConnection(MgResourceIdentifier resource); |
virtual boolean TestConnection(MgResourceIdentifier resource); |
virtual bool TestConnection(MgResourceIdentifier resource); |
resource | (MgResourceIdentifier) The resource identifier for the feature source. |
$boolResult = $featureService->TestConnection("Library://FeatureService/testSHP.FeatureSource");
MgFdoException |
using OSGeo.MapGuide; // the SDF file identified by this MgResourceIdentifier exists in the repository private MgResourceIdentifier resourceId; private Boolean connected; private MgFeatureService featureService; resourceId = new MgResourceIdentifier("Library://PlatformApiDocTests/SdfFeatureClass.FeatureSource"); // see the comments preceding the class declaration for code showing the creation of MgFeatureService object connected = featureService.TestConnection(resourceId);