protected function writeShapeCollection(XMLWriter $objWriter, $shapes = array(), &$shapeId = 0)
{
if (count($shapes) == 0) {
return;
}
foreach ($shapes as $shape) {
// Increment $shapeId
++$shapeId;
// Check type
if ($shape instanceof RichText) {
$this->writeShapeText($objWriter, $shape, $shapeId);
} elseif ($shape instanceof ShapeTable) {
$this->writeShapeTable($objWriter, $shape, $shapeId);
} elseif ($shape instanceof Line) {
$this->writeShapeLine($objWriter, $shape, $shapeId);
} elseif ($shape instanceof ShapeChart) {
$this->writeShapeChart($objWriter, $shape, $shapeId);
} elseif ($shape instanceof AbstractGraphic) {
$this->writeShapePic($objWriter, $shape, $shapeId);
} elseif ($shape instanceof Group) {
$this->writeShapeGroup($objWriter, $shape, $shapeId);
} elseif ($shape instanceof Comment) {
return;
} else {
throw new \Exception("Unknown Shape type: {get_class({$shape})}");
}
}
}