phpdoc
[m6w6/pq-gateway] / lib / pq / Mapper / MapInterface.php
index 0e0db3a3e97e9c08e5e0c3326b388a6898fc7b3c..8c950568f365d82fb32b6af8ef5bdf3505dede82 100644 (file)
@@ -9,26 +9,31 @@ use pq\Gateway\Table;
 interface MapInterface
 {
        /**
+        * Get the mapped class' name
         * @return string
         */
        function getClass();
 
        /**
+        * The the underlying table gateway
         * @return Table
         */
        function getGateway();
 
        /**
-        * @return array of PropertyInterface instances
+        * Get the mapped properties
+        * @return PropertyInterface[]
         */
        function getProperties();
 
        /**
+        * Add a property to map
         * @param PropertyInterface $property
         */
        function addProperty(PropertyInterface $property);
 
        /**
+        * Get all child rows by foreign key
         * @param Row $row
         * @param string $refName
         * @param array $objects
@@ -37,6 +42,7 @@ interface MapInterface
        function allOf(Row $row, $refName, &$objects = null);
 
        /**
+        * Get the parent row by foreign key
         * @param Row $row
         * @param string $refName
         * @param array $objects
@@ -45,25 +51,29 @@ interface MapInterface
        function refOf(Row $row, $refName, &$objects = null);
 
        /**
+        * Get the table relation reference
         * @param MapInterface $map origin
         * @param string $refName relations reference name
-        * @return array relation reference
+        * @return Table\Reference
         */
        function relOf(MapInterface $map, $refName);
 
        /**
+        * Map a row to an object
         * @param Row $row
         * @return object
         */
        function map(Row $row);
 
        /**
+        * Map a rowset to an array of objects
         * @param Rowset $rows
-        * @return array
+        * @return object[]
         */
        function mapAll(Rowset $rows);
 
        /**
+        * Unmap on object
         * @param object $object
         * @return Row
         */