Skip to content

Commit

Permalink
Merge pull request #18 from ScientaNL/remove-flowchart-definition
Browse files Browse the repository at this point in the history
Remove obsolete FlowchartDefinition and fix some typings
  • Loading branch information
HarmenM authored Aug 12, 2021
2 parents 52d2b9a + 1786931 commit cea0679
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 69 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
* "File": "DocumentExportDefinition\Section\Data\FileDefinition",
* "Form": "DocumentExportDefinition\Section\Data\FormDefinition",
* "Docx": "DocumentExportDefinition\Section\Encoded\DocxDefinition",
* "Flowchart": "DocumentExportDefinition\Section\Encoded\FlowchartDefinition",
* "Image": "DocumentExportDefinition\Section\Encoded\ImageDefinition",
* "Html": "DocumentExportDefinition\Section\Html\HtmlDefinition",
* "HtmlImage": "DocumentExportDefinition\Section\Html\HtmlImageDefinition",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public function getEncodedValue()
}

/**
* @param int $mimeType
* @param string $mimeType
* @return $this
*/
public function setMimeType($mimeType)
Expand All @@ -79,7 +79,7 @@ public function setMimeType($mimeType)
}

/**
* @param int $extension
* @param string $extension
* @return $this
*/
public function setExtension($extension)
Expand All @@ -88,13 +88,16 @@ public function setExtension($extension)
return $this;
}

/**
* @return string
*/
public function getExtension()
{
return $this->extension;
}

/**
* @return int
* @return string
*/
public function getMimeType()
{
Expand Down
65 changes: 0 additions & 65 deletions DocumentExportDefinition/Section/Encoded/FlowchartDefinition.php

This file was deleted.

49 changes: 49 additions & 0 deletions DocumentExportDefinition/Section/Encoded/ImageDefinition.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,19 @@

class ImageDefinition extends AbstractEncodedDataDefinition
{
/**
* @Serializer\Type("int")
* @var int|null
*/
protected $width = null;

/**
* @Serializer\Type("int")
* @var int|null
* @nu
*/
protected $height = null;

/**
* @Serializer\VirtualProperty
* @Serializer\SerializedName("objectType")
Expand All @@ -15,4 +28,40 @@ public function getType()
{
return 'ImageDefinition';
}

/**
* @return int|null
*/
public function getWidth(): ?int
{
return $this->width;
}

/**
* @param int|null $width
* @return self
*/
public function setWidth(?int $width): self
{
$this->width = $width;
return $this;
}

/**
* @return int|null
*/
public function getHeight(): ?int
{
return $this->height;
}

/**
* @param int|null $height
* @return self
*/
public function setHeight(?int $height): self
{
$this->height = $height;
return $this;
}
}

0 comments on commit cea0679

Please sign in to comment.