gen_model

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 18, 2024 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Index

Constants

View Source
const (
	Name              = base.CommandNameModel
	Description       = "Generate model files"
	DefaultTargetPath = "app/models"
)

Variables

This section is empty.

Functions

func New

func New() *console.Command

New creates a console command.

Types

type Generator

type Generator struct {
	Common    *commands.Common
	Command   *console.Command
	Container *console.Container
	Table     *base.Table
	Target    base.Target
}

Generator is a component for generate model files.

func (*Generator) Run

func (o *Generator) Run(ctx context.Context) (err error)

type Provider

type Provider struct {
	// contains filtered or unexported fields
}

Provider is a component used to generate model files.

func (*Provider) Before

func (o *Provider) Before(_ context.Context, _ *console.Container, command *console.Command) (err error)

Before is a before runner hook handler for command.

func (*Provider) Run

func (o *Provider) Run(ctx context.Context, container *console.Container, command *console.Command) (err error)

Run is a runner hook handler for command.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL