github.com/goravel/framework@v1.13.9/contracts/database/orm/factory.go (about)

     1  package orm
     2  
     3  //go:generate mockery --name=Factory
     4  type Factory interface {
     5  	// Count sets the number of models that should be generated.
     6  	Count(count int) Factory
     7  	// Create creates a model and persists it to the database.
     8  	Create(value any, attributes ...map[string]any) error
     9  	// CreateQuietly creates a model and persists it to the database without firing any model events.
    10  	CreateQuietly(value any, attributes ...map[string]any) error
    11  	// Make creates a model and returns it, but does not persist it to the database.
    12  	Make(value any, attributes ...map[string]any) error
    13  }