Browse Source

Added documentation for the @VirtualProperty annotation.

Pierre-Yves LEBECQ 12 năm trước cách đây
mục cha
commit
7cb631a043
1 tập tin đã thay đổi với 8 bổ sung0 xóa
  1. 8 0
      doc/reference/annotations.rst

+ 8 - 0
doc/reference/annotations.rst

@@ -141,6 +141,14 @@ default the order is undefined, but you may change it to either "alphabetical",
         private $name;
     }
 
+@VirtualProperty
+~~~~~~~~~~~~~~~~
+This annotation can be defined on a method to indicate that the data returned by
+the method should appear like a property of the object.
+
+**Note**: This only works for serialization and is completely ignored during
+deserialization.
+
 @Inline
 ~~~~~~~~
 This annotation can be defined on a property to indicate that the data of the property