Skip to content

Commit

Permalink
💄
Browse files Browse the repository at this point in the history
  • Loading branch information
samber committed Nov 1, 2023
1 parent bd835e9 commit 2fbf315
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 41 deletions.
2 changes: 1 addition & 1 deletion di_alias_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,5 +71,5 @@ func TestInvokeAs(t *testing.T) {
}

func TestMustInvokeAs(t *testing.T) {
// is := assert.New(t)
// @TODO
}
50 changes: 10 additions & 40 deletions service.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,46 +37,16 @@ type Service[T any] interface {
source() (stacktrace.Frame, []stacktrace.Frame)
}

type serviceGetName interface {
getName() string
}

type serviceGetType interface {
getType() ServiceType
}

type serviceGetEmptyInstance interface {
getEmptyInstance() any
}

type serviceGetInstanceAny interface {
getInstanceAny(Injector) (any, error)
}

type serviceGetInstance[T any] interface {
getInstance(Injector) (T, error)
}

type serviceIsHealthchecker interface {
isHealthchecker() bool
}

type serviceHealthcheck interface {
healthcheck(context.Context) error
}

type serviceIsShutdowner interface {
isShutdowner() bool
}

type serviceShutdown interface {
shutdown(context.Context) error
}

type serviceClone interface {
clone() any
}

type serviceGetName interface{ getName() string }
type serviceGetType interface{ getType() ServiceType }
type serviceGetEmptyInstance interface{ getEmptyInstance() any }
type serviceGetInstanceAny interface{ getInstanceAny(Injector) (any, error) }
type serviceGetInstance[T any] interface{ getInstance(Injector) (T, error) } //nolint:unused
type serviceIsHealthchecker interface{ isHealthchecker() bool }
type serviceHealthcheck interface{ healthcheck(context.Context) error }
type serviceIsShutdowner interface{ isShutdowner() bool }
type serviceShutdown interface{ shutdown(context.Context) error }
type serviceClone interface{ clone() any }
type serviceSource interface {
source() (stacktrace.Frame, []stacktrace.Frame)
}
Expand Down

0 comments on commit 2fbf315

Please sign in to comment.