@@ -77,7 +77,7 @@ public function uuid(string $version = 'v4'): TdbmFluidColumnOptions
7777 return $ this ->column ('uuid ' )->guid ();
7878 }
7979
80- public function timestamps (): TdbmFluidTable
80+ public function timestamps (): self
8181 {
8282 $ this ->fluidTable ->timestamps ();
8383 return $ this ;
@@ -86,7 +86,7 @@ public function timestamps(): TdbmFluidTable
8686 /**
8787 * @throws FluidSchemaException
8888 */
89- public function extends (string $ tableName ): TdbmFluidTable
89+ public function extends (string $ tableName ): self
9090 {
9191 $ this ->fluidTable ->extends ($ tableName );
9292 return $ this ;
@@ -95,7 +95,7 @@ public function extends(string $tableName): TdbmFluidTable
9595 /**
9696 * Adds a "Bean" annotation to the table.
9797 */
98- public function customBeanName (string $ beanName ): TdbmFluidTable
98+ public function customBeanName (string $ beanName ): self
9999 {
100100 $ this ->addAnnotation ('Bean ' , ['name ' =>$ beanName ]);
101101 return $ this ;
@@ -104,12 +104,36 @@ public function customBeanName(string $beanName): TdbmFluidTable
104104 /**
105105 * Adds a "Type" annotation.
106106 */
107- public function graphqlType (): TdbmFluidTable
107+ public function graphqlType (): self
108108 {
109109 $ this ->addAnnotation ('TheCodingMachine \\GraphQLite \\Annotations \\Type ' );
110110 return $ this ;
111111 }
112112
113+ /**
114+ * Makes the generated bean implement the interface $interfaceName
115+ *
116+ * @param string $interfaceName The fully qualified name of the PHP interface to implement.
117+ * @return TdbmFluidTable
118+ */
119+ public function implementsInterface (string $ interfaceName ): self
120+ {
121+ $ this ->addAnnotation ('AddInterface ' , ['name ' => $ interfaceName ], false );
122+ return $ this ;
123+ }
124+
125+ /**
126+ * Makes the generated DAO implement the interface $interfaceName
127+ *
128+ * @param string $interfaceName The fully qualified name of the PHP interface to implement.
129+ * @return TdbmFluidTable
130+ */
131+ public function implementsInterfaceOnDao (string $ interfaceName ): self
132+ {
133+ $ this ->addAnnotation ('AddInterfaceOnDao ' , ['name ' => $ interfaceName ], false );
134+ return $ this ;
135+ }
136+
113137 private function getComment (): Comment
114138 {
115139 $ options = $ this ->fluidTable ->getDbalTable ()->getOptions ();
0 commit comments