sqltype

package
v0.0.0-...-3b2b5cc Latest Latest
Warning

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

Go to latest
Published: May 8, 2026 License: MIT Imports: 2 Imported by: 1

Documentation

Overview

Package sqltype 提供面向存储模型的通用字段类型与标记接口。

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HasSoftDelete

func HasSoftDelete[M sqlbuilder.Model]() bool

HasSoftDelete 判断模型是否实现软删除能力。

Types

type DeletedAtMarker

type DeletedAtMarker interface {
	MarkDeletedAt()
}

DeletedAtMarker 表示模型支持标记删除时间。

type SoftDeleteValueGetter

type SoftDeleteValueGetter interface {
	GetDeletedAt() driver.Value
}

SoftDeleteValueGetter 表示模型可读取当前软删除值。

type WithCreationTime

type WithCreationTime interface {
	MarkCreatedAt()
}

WithCreationTime 表示模型支持标记创建时间。

type WithModificationTime

type WithModificationTime interface {
	MarkModifiedAt()
}

WithModificationTime 表示模型支持标记修改时间。

type WithSoftDelete

type WithSoftDelete interface {
	SoftDeleteFieldAndZeroValue() (string, driver.Value)
}

WithSoftDelete 表示模型暴露软删除字段及其零值。

Directories

Path Synopsis
Package time GENERATED BY gengo:runtimedoc DON'T EDIT THIS FILE
Package time GENERATED BY gengo:runtimedoc DON'T EDIT THIS FILE