model

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2024 License: MIT Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	// ポイント送付のお知らせ
	NotificationTypeSendingPoint = 1
)

notificationTypeID表

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfirmCode

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

func NewConfirmCode

func NewConfirmCode() *ConfirmCode

ラムダム文字列の確認コードを作成

func (*ConfirmCode) String

func (cc *ConfirmCode) String() string

文字列の確認コードを返す @return 確認コード

type NotificationID

type NotificationID int64

type NotificationType

type NotificationType struct {
	ID    NotificationTypeID `json:"id" db:"id"`
	Title string             `json:"title" db:"title"`
}

type NotificationTypeID

type NotificationTypeID int64

type Password

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

パスワードオブジェクト

func NewPassword

func NewPassword(pwd string) (*Password, error)

パスワードオブジェクト作成 ハッシュ化されてない値を扱う コンストラクタ

@params pwd パスワード

@return パスワードオブジェクト

func (*Password) CreateHash

func (pwd *Password) CreateHash() (string, error)

func (*Password) CreateRandomPassword

func (pwd *Password) CreateRandomPassword() *Password

ラムダム文字列のパスワードを作成

func (*Password) IsMatch

func (pwd *Password) IsMatch(hashPwd string) (bool, error)

ハッシュ化されたパスワードと一致するか @params hashPwd ハッシュ化されたパスワード

func (*Password) String

func (pwd *Password) String() string

文字列 @return パスワード

type SendablePoint

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

送信可能ポイントオブジェクト

func NewSendablePoint

func NewSendablePoint(sendablePoint int) *SendablePoint

func (*SendablePoint) CalculatePointBalance

func (sp *SendablePoint) CalculatePointBalance(sendPlannedPoint int) int

ポイント残高を計算

@params sendPlannedPoint 送付予定ポイント

@returns 残高

func (*SendablePoint) CanSendPoint

func (sp *SendablePoint) CanSendPoint(sendPlannedPoint int) bool

送付可能かどうか判断する

@params sendPlannedPoint 送付予定ポイント

@returns true: 送付できる, false: 送付できない

type TemporaryUserString

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

func NewTemporaryUserString

func NewTemporaryUserString(temporaryUserString string) *TemporaryUserString

func (*TemporaryUserString) Join

func (tus *TemporaryUserString) Join(firstName, firstNameKana, familyName, familyNameKana, email, password string) string

ユーザ情報を開業で区切り、1つの文字列に結合する

@params ctx コンテキスト firstName 名前 firstNameKana 名前カナ familyName 名字 familyNameKana 名字カナ email メールアドレス password パスワード

@returns 連結したユーザ

func (*TemporaryUserString) Split

func (tus *TemporaryUserString) Split() (firstName, firstNameKana, familyName, familyNameKana, email, hashPass string)

開業で区切られた1つの文字列になっているユーザ情報を分解する

@returns ctx コンテキスト firstName 名前 firstNameKana 名前カナ familyName 名字 familyNameKana 名字カナ email メールアドレス hashPass パスワード

type Time

type Time struct {
	Time time.Time
}

func NewTime

func NewTime(time time.Time) *Time

func (*Time) Format

func (t *Time) Format() string

yyyy/MM/dd hh:mm:ssの形にフォーマットする

type TransactionID

type TransactionID uint64

type UserID

type UserID int64

Jump to

Keyboard shortcuts

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