Documentation ¶
Index ¶
- Variables
- func AddScopedITime(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
- func AddScopedITimeByFunc(builder *di.Builder, implType reflect.Type, ...)
- func AddScopedITimeByFuncWithMetadata(builder *di.Builder, implType reflect.Type, ...)
- func AddScopedITimeUtils(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
- func AddScopedITimeUtilsByFunc(builder *di.Builder, implType reflect.Type, ...)
- func AddScopedITimeUtilsByFuncWithMetadata(builder *di.Builder, implType reflect.Type, ...)
- func AddScopedITimeUtilsWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, ...)
- func AddScopedITimeWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, ...)
- func AddSingletonITime(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
- func AddSingletonITimeByFunc(builder *di.Builder, implType reflect.Type, ...)
- func AddSingletonITimeByFuncWithMetadata(builder *di.Builder, implType reflect.Type, ...)
- func AddSingletonITimeByObj(builder *di.Builder, obj interface{}, implementedTypes ...reflect.Type)
- func AddSingletonITimeByObjWithMetadata(builder *di.Builder, obj interface{}, metaData map[string]interface{}, ...)
- func AddSingletonITimeUtils(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
- func AddSingletonITimeUtilsByFunc(builder *di.Builder, implType reflect.Type, ...)
- func AddSingletonITimeUtilsByFuncWithMetadata(builder *di.Builder, implType reflect.Type, ...)
- func AddSingletonITimeUtilsByObj(builder *di.Builder, obj interface{}, implementedTypes ...reflect.Type)
- func AddSingletonITimeUtilsByObjWithMetadata(builder *di.Builder, obj interface{}, metaData map[string]interface{}, ...)
- func AddSingletonITimeUtilsWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, ...)
- func AddSingletonITimeWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, ...)
- func AddTimeNowFunc(builder *di.Builder, fnc TimeNow)
- func AddTimeParseFunc(builder *di.Builder, fnc TimeParse)
- func AddTransientITime(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
- func AddTransientITimeByFunc(builder *di.Builder, implType reflect.Type, ...)
- func AddTransientITimeByFuncWithMetadata(builder *di.Builder, implType reflect.Type, ...)
- func AddTransientITimeUtils(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
- func AddTransientITimeUtilsByFunc(builder *di.Builder, implType reflect.Type, ...)
- func AddTransientITimeUtilsByFuncWithMetadata(builder *di.Builder, implType reflect.Type, ...)
- func AddTransientITimeUtilsWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, ...)
- func AddTransientITimeWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, ...)
- func GetITimeDefinition(ctn di.Container) *di.Def
- func GetITimeDefinitions(ctn di.Container) []*di.Def
- func GetITimeUtilsDefinition(ctn di.Container) *di.Def
- func GetITimeUtilsDefinitions(ctn di.Container) []*di.Def
- func RemoveAllITime(builder *di.Builder)
- func RemoveAllITimeUtils(builder *di.Builder)
- func RemoveAllTimeNowFunc(builder *di.Builder)
- func RemoveAllTimeParseFunc(builder *di.Builder)
- type ITime
- type ITimeUtils
- type TimeNow
- type TimeParse
Constants ¶
This section is empty.
Variables ¶
var ReflectTypeITime = di.GetInterfaceReflectType((*ITime)(nil))
ReflectTypeITime used when your service claims to implement ITime
var ReflectTypeITimeUtils = di.GetInterfaceReflectType((*ITimeUtils)(nil))
ReflectTypeITimeUtils used when your service claims to implement ITimeUtils
var ReflectTypeTimeNow = reflect.TypeOf(TimeNow(nil))
ReflectTypeTimeNow used when your service claims to implement TimeNow
var ReflectTypeTimeParse = reflect.TypeOf(TimeParse(nil))
ReflectTypeTimeParse used when your service claims to implement TimeParse
Functions ¶
func AddScopedITime ¶
AddScopedITime adds a type that implements ITime
func AddScopedITimeByFunc ¶
func AddScopedITimeByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)
AddScopedITimeByFunc adds a type by a custom func
func AddScopedITimeByFuncWithMetadata ¶ added in v0.1.217
func AddScopedITimeByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddScopedITimeByFuncWithMetadata adds a type by a custom func
func AddScopedITimeUtils ¶
func AddScopedITimeUtils(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
AddScopedITimeUtils adds a type that implements ITimeUtils
func AddScopedITimeUtilsByFunc ¶
func AddScopedITimeUtilsByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)
AddScopedITimeUtilsByFunc adds a type by a custom func
func AddScopedITimeUtilsByFuncWithMetadata ¶ added in v0.1.217
func AddScopedITimeUtilsByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddScopedITimeUtilsByFuncWithMetadata adds a type by a custom func
func AddScopedITimeUtilsWithMetadata ¶ added in v0.1.217
func AddScopedITimeUtilsWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddScopedITimeUtilsWithMetadata adds a type that implements ITimeUtils
func AddScopedITimeWithMetadata ¶ added in v0.1.217
func AddScopedITimeWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddScopedITimeWithMetadata adds a type that implements ITime
func AddSingletonITime ¶
func AddSingletonITime(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
AddSingletonITime adds a type that implements ITime
func AddSingletonITimeByFunc ¶
func AddSingletonITimeByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)
AddSingletonITimeByFunc adds a type by a custom func
func AddSingletonITimeByFuncWithMetadata ¶ added in v0.1.217
func AddSingletonITimeByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddSingletonITimeByFuncWithMetadata adds a type by a custom func
func AddSingletonITimeByObj ¶
AddSingletonITimeByObj adds a prebuilt obj
func AddSingletonITimeByObjWithMetadata ¶ added in v0.1.217
func AddSingletonITimeByObjWithMetadata(builder *di.Builder, obj interface{}, metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddSingletonITimeByObjWithMetadata adds a prebuilt obj
func AddSingletonITimeUtils ¶
func AddSingletonITimeUtils(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
AddSingletonITimeUtils adds a type that implements ITimeUtils
func AddSingletonITimeUtilsByFunc ¶
func AddSingletonITimeUtilsByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)
AddSingletonITimeUtilsByFunc adds a type by a custom func
func AddSingletonITimeUtilsByFuncWithMetadata ¶ added in v0.1.217
func AddSingletonITimeUtilsByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddSingletonITimeUtilsByFuncWithMetadata adds a type by a custom func
func AddSingletonITimeUtilsByObj ¶
func AddSingletonITimeUtilsByObj(builder *di.Builder, obj interface{}, implementedTypes ...reflect.Type)
AddSingletonITimeUtilsByObj adds a prebuilt obj
func AddSingletonITimeUtilsByObjWithMetadata ¶ added in v0.1.217
func AddSingletonITimeUtilsByObjWithMetadata(builder *di.Builder, obj interface{}, metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddSingletonITimeUtilsByObjWithMetadata adds a prebuilt obj
func AddSingletonITimeUtilsWithMetadata ¶ added in v0.1.217
func AddSingletonITimeUtilsWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddSingletonITimeUtilsWithMetadata adds a type that implements ITimeUtils
func AddSingletonITimeWithMetadata ¶ added in v0.1.217
func AddSingletonITimeWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddSingletonITimeWithMetadata adds a type that implements ITime
func AddTimeNowFunc ¶ added in v0.1.187
AddSingletonTimeNowFunc adds a func to the DI
func AddTimeParseFunc ¶ added in v0.1.192
AddSingletonTimeParseFunc adds a func to the DI
func AddTransientITime ¶
func AddTransientITime(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
AddTransientITime adds a type that implements ITime
func AddTransientITimeByFunc ¶
func AddTransientITimeByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)
AddTransientITimeByFunc adds a type by a custom func
func AddTransientITimeByFuncWithMetadata ¶ added in v0.1.217
func AddTransientITimeByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddTransientITimeByFuncWithMetadata adds a type by a custom func
func AddTransientITimeUtils ¶
func AddTransientITimeUtils(builder *di.Builder, implType reflect.Type, implementedTypes ...reflect.Type)
AddTransientITimeUtils adds a type that implements ITimeUtils
func AddTransientITimeUtilsByFunc ¶
func AddTransientITimeUtilsByFunc(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), implementedTypes ...reflect.Type)
AddTransientITimeUtilsByFunc adds a type by a custom func
func AddTransientITimeUtilsByFuncWithMetadata ¶ added in v0.1.217
func AddTransientITimeUtilsByFuncWithMetadata(builder *di.Builder, implType reflect.Type, build func(ctn di.Container) (interface{}, error), metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddTransientITimeUtilsByFuncWithMetadata adds a type by a custom func
func AddTransientITimeUtilsWithMetadata ¶ added in v0.1.217
func AddTransientITimeUtilsWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddTransientITimeUtilsWithMetadata adds a type that implements ITimeUtils
func AddTransientITimeWithMetadata ¶ added in v0.1.217
func AddTransientITimeWithMetadata(builder *di.Builder, implType reflect.Type, metaData map[string]interface{}, implementedTypes ...reflect.Type)
AddTransientITimeWithMetadata adds a type that implements ITime
func GetITimeDefinition ¶ added in v0.1.217
GetITimeDefinition returns that last definition registered that this container can provide
func GetITimeDefinitions ¶ added in v0.1.217
GetITimeDefinitions returns all definitions that this container can provide
func GetITimeUtilsDefinition ¶ added in v0.1.217
GetITimeUtilsDefinition returns that last definition registered that this container can provide
func GetITimeUtilsDefinitions ¶ added in v0.1.217
GetITimeUtilsDefinitions returns all definitions that this container can provide
func RemoveAllITime ¶
RemoveAllITime removes all ITime from the DI
func RemoveAllITimeUtils ¶
RemoveAllITimeUtils removes all ITimeUtils from the DI
func RemoveAllTimeNowFunc ¶ added in v0.1.187
RemoveAllTimeNowFunc removes all TimeNow functions from the DI
func RemoveAllTimeParseFunc ¶ added in v0.1.192
RemoveAllTimeParseFunc removes all TimeParse functions from the DI
Types ¶
type ITime ¶
ITime ...
func GetITimeFromContainer ¶
GetITimeFromContainer alternative to SafeGetITimeFromContainer but panics of object is not present
func GetManyITimeFromContainer ¶ added in v0.1.179
GetManyITimeFromContainer alternative to SafeGetManyITimeFromContainer but panics of object is not present
func SafeGetITimeFromContainer ¶
SafeGetITimeFromContainer trys to get the object by type, will not panic, returns nil and error
type ITimeUtils ¶
type ITimeUtils interface { // StartOfMonthUTC where offsetMonth is 0-based (0 = Current Month) StartOfMonthUTC(offsetMonth int) time.Time }
ITimeUtils ...
func GetITimeUtilsFromContainer ¶
func GetITimeUtilsFromContainer(ctn di.Container) ITimeUtils
GetITimeUtilsFromContainer alternative to SafeGetITimeUtilsFromContainer but panics of object is not present
func GetManyITimeUtilsFromContainer ¶ added in v0.1.179
func GetManyITimeUtilsFromContainer(ctn di.Container) []ITimeUtils
GetManyITimeUtilsFromContainer alternative to SafeGetManyITimeUtilsFromContainer but panics of object is not present
func SafeGetITimeUtilsFromContainer ¶
func SafeGetITimeUtilsFromContainer(ctn di.Container) (ITimeUtils, error)
SafeGetITimeUtilsFromContainer trys to get the object by type, will not panic, returns nil and error
func SafeGetManyITimeUtilsFromContainer ¶ added in v0.1.179
func SafeGetManyITimeUtilsFromContainer(ctn di.Container) ([]ITimeUtils, error)
SafeGetManyITimeUtilsFromContainer trys to get the object by type, will not panic, returns nil and error
type TimeNow ¶ added in v0.1.186
TimeNow ...
func GetManyTimeNowFromContainer ¶ added in v0.1.187
GetManyTimeNowFromContainer alternative to SafeGetManyTimeNowFromContainer but panics of object is not present
func GetTimeNowFromContainer ¶ added in v0.1.187
GetTimeNowFromContainer alternative to SafeGetTimeNowFromContainer but panics of object is not present
func SafeGetManyTimeNowFromContainer ¶ added in v0.1.187
SafeGetManyTimeNowFromContainer trys to get the object by type, will not panic, returns nil and error
type TimeParse ¶ added in v0.1.192
TimeParse ...
func GetManyTimeParseFromContainer ¶ added in v0.1.192
GetManyTimeParseFromContainer alternative to SafeGetManyTimeParseFromContainer but panics of object is not present
func GetTimeParseFromContainer ¶ added in v0.1.192
GetTimeParseFromContainer alternative to SafeGetTimeParseFromContainer but panics of object is not present
func SafeGetManyTimeParseFromContainer ¶ added in v0.1.192
SafeGetManyTimeParseFromContainer trys to get the object by type, will not panic, returns nil and error