Browse Source

Removing Exclude over virtual property annotation

Aleksandr Klimenkov 13 years ago
parent
commit
ab5cc8036d
2 changed files with 3 additions and 12 deletions
  1. 1 1
      Annotation/Exclude.php
  2. 2 11
      Tests/Fixtures/ObjectWithVirtualProperties.php

+ 1 - 1
Annotation/Exclude.php

@@ -20,7 +20,7 @@ namespace JMS\SerializerBundle\Annotation;
 
 /**
  * @Annotation
- * @Target({"PROPERTY", "METHOD", "CLASS"})
+ * @Target({"PROPERTY", "CLASS"})
  */
 final class Exclude
 {

+ 2 - 11
Tests/Fixtures/ObjectWithVirtualProperties.php

@@ -39,7 +39,7 @@ class ObjectWithVirtualProperties
      * 
      * @VirtualProperty("foo")
      */
-    public function getVirualValue()
+    public function getVirtualValue()
     {
         return 'value';
     }
@@ -48,17 +48,8 @@ class ObjectWithVirtualProperties
      * @VirtualProperty("prop_name")
      * @SerializedName("test")
      */
-    public function getVirualSerializedValue()
+    public function getVirtualSerializedValue()
     {
         return 'other-name';
     }
-    
-    /**
-     * @VirtualProperty("excluded")
-     * @Exclude
-     */
-    public function getVirualExcudedValue()
-    {
-        return 'excluded';
-    }
 }