@@ -1564,10 +1564,13 @@ impl RemoveModelBuilder {
15641564 }
15651565}
15661566
1567+ /// Returns a builder for an operation that alters a field in a model.
15671568pub const fn alter_field ( ) -> AlterFieldBuilder {
15681569 AlterFieldBuilder :: new ( )
15691570}
15701571
1572+ /// A builder for altering a field in a model.
1573+ #[ must_use]
15711574#[ derive( Debug , Copy , Clone ) ]
15721575pub struct AlterFieldBuilder {
15731576 table_name : Option < Identifier > ,
@@ -1584,21 +1587,26 @@ impl AlterFieldBuilder {
15841587 }
15851588 }
15861589
1590+ /// Sets the name of the table to alter the field in.
15871591 pub const fn table_name ( mut self , table_name : Identifier ) -> Self {
15881592 self . table_name = Some ( table_name) ;
15891593 self
15901594 }
15911595
1596+ /// Sets the old field definition.
15921597 pub const fn old_field ( mut self , field : Field ) -> Self {
15931598 self . old_field = Some ( field) ;
15941599 self
15951600 }
15961601
1602+ /// Sets the new field definition.
15971603 pub const fn new_field ( mut self , field : Field ) -> Self {
15981604 self . new_field = Some ( field) ;
15991605 self
16001606 }
16011607
1608+ /// Builds the operation.
1609+ #[ must_use]
16021610 pub const fn build ( self ) -> Operation {
16031611 Operation :: new ( OperationInner :: AlterField {
16041612 table_name : unwrap_builder_option ! ( self , table_name) ,
0 commit comments