chore: 并入 iotlcm-upstream-proxy 历史到 upstream-proxy/(原提交 44209ec)
This commit is contained in:
@@ -0,0 +1,43 @@
|
||||
package model
|
||||
|
||||
import (
|
||||
"context"
|
||||
"git.5iot.com/iotlcm-public/iotlcm-upstream-proxy/internal/model/entity"
|
||||
|
||||
"github.com/gogf/gf/v2/os/gtime"
|
||||
)
|
||||
|
||||
type SimChannelConfigItemCache struct {
|
||||
Template *entity.TSimChannelTemplate
|
||||
Channel *entity.TSimChannels
|
||||
IsNormal *int // global_yes_or_no: 0=yes, 1=no; NULL is not eligible.
|
||||
Version string
|
||||
}
|
||||
|
||||
// CanCreateInstance determines whether a channel may have a runtime instance.
|
||||
func (c *SimChannelConfigItemCache) CanCreateInstance() bool {
|
||||
return c != nil && c.Channel != nil && c.IsNormal != nil && *c.IsNormal == 0
|
||||
}
|
||||
|
||||
type SimCardTempI interface {
|
||||
NewTemp(ctx context.Context, channelConfig *SimChannelConfigItemCache) SimCardChannelI
|
||||
}
|
||||
|
||||
// 接口定义
|
||||
type SimCardChannelI interface {
|
||||
SimBase(ctx context.Context, input *SimBaseReqJson) (SimBaseResJson, error)
|
||||
}
|
||||
|
||||
type SimCardChannelCache struct {
|
||||
Instance SimCardChannelI
|
||||
Version string
|
||||
}
|
||||
|
||||
type UpdateAccessTokenInput struct {
|
||||
ChanKey string
|
||||
AccessToken string
|
||||
AccessTokenCreated *gtime.Time
|
||||
AccessTokenExpire *gtime.Time
|
||||
RefreshToken string
|
||||
RefreshTokenExpire *gtime.Time
|
||||
}
|
||||
Reference in New Issue
Block a user