MapGuide API Reference
|
virtual MgByteReader* MgDrawingService::GetSectionResource | ( | MgResourceIdentifier * | resource, |
CREFSTRING | resourceName | ||
) | [pure virtual] |
Gets a specific resource from the DWF.
virtual MgByteReader GetSectionResource(MgResourceIdentifier resource, string resourceName); |
virtual MgByteReader GetSectionResource(MgResourceIdentifier resource, String resourceName); |
virtual MgByteReader GetSectionResource(MgResourceIdentifier resource, string resourceName); |
resource | (MgResourceIdentifier) Resource identifier specifying the drawing source which has the DWF resource data. |
resourceName | (String/string) Name of the resource. Resource names can be retrieved via EnumerateSectionResources or from the manifest.xml file via DescribeDrawing. |
// Assuming the drawing service has already been initialized $drawing_ID = new MgResourceIdentifier('Library://DrawingService/Floorplan.DrawingSource'); $resourceName = 'com.autodesk.dwf.ePlot_9E2723744244DB8C44482263E654F7644AA701C2E18DD99948F3C0D4FDFAC165.png'; $byteReader = $drawingService->GetSectionResource($drawing_ID, $resourceName);
MgInvalidArgumentException | if the requested resourceName does not specify a section name. |
MgDwfSectionNotFoundException | if the requested section does not exist in the DWF package. |
MgDwfSectionResourceNotFoundException | if the requested section resource does not exist in the DWF package. |
MgInvalidCastException | if there are problems reading the DWF into memory. |
MgServiceNotAvailableException | if the underlying resource service cannot be obtained to access the drawing in the resource repository. |
MgXmlParserException | if there are problems parsing the resource content specified by the resource identifier. |
MgInvalidDwfPackageException | if the DWF specified by the resource identifier is not a DWF of version 6.0 or greater. |
MgDwfException | if the DWF component encounters errors. |
MgTemporaryFileNotAvailableException | if a temporary file needed to complete the operation cannot be generated or accessed. |