nelmio/NelmioApiDocBundle — pull request #149 by pylebecq (2013-03-20 10:37:20+00:00)
Title: [Parser] Added float in JmsMetadataParser::isPrimitive().

Hi guys,

I ran into an issue today.

I put an ApiDoc annotation like the following :
```php
/**
* @ApiDoc(
* resource=true,
* output="Acme\Bundle\OrderBundle\Entity\OrderLine",
* statusCodes={
* 200="Returned when successful.",
* 404="Returned when the order line is not found.",
* 405="Returned when a wrong HTTP method is used.",
* 415="Returned when the client does not accept any of the supported formats.",
* 500="Returned when an error occured."
* }
* )
*/
```
In the `OrderLine` class, I have the following property :
```php
/**
* Discounted unit price including taxes.
*
* @var string
*
* @ORM\Column(name="li_px_ttc_rem", type="decimal", nullable=true)
* @Assert\Type("numeric")
*/
private $discountedUnitPriceIncludingTaxes;
```
According to the Doctrine2 documentation, a decimal type maps an SQL DECIMAL to a PHP string.

But when I want to see the documentation, I run into this :
![expection](https://f.cloud.github.com/assets/351471/280135/766a3710-9149-11e2-952d-6c24bdcfd62c.png)
I found two ways to fix this :
* Adding `@Serializer\Type("string")` annotation on the property.
* Adding 'float' to the list of primitive types in `JmsMetadataParser::isPrimitive()`

I don't want to specify the `@Serializer\Type` annotation to all my decimal columns so, that's why I propose to add the 'float' primitive type.