DesignWithContext
DesignWithContext[A] is a wrapper of Design class for chaining lifecycle hooks for the same type A. This can be safely cast to just Design
Attributes
- Graph
- Supertypes
- class Designtrait LogSupporttrait LazyLoggertrait LoggingMethodstrait Serializableclass Objecttrait Matchableclass Any
Members list
Value members
Concrete methods
Inherited methods
Attributes
- Inherited from:
- Design
A helper method of creating a new session and an instance of A. This method is useful when you only need to use A as an entry point of your program. After executing the body, the sesion will be closed.
A helper method of creating a new session and an instance of A. This method is useful when you only need to use A as an entry point of your program. After executing the body, the sesion will be closed.
Attributes
- Inherited from:
- DesignImpl (hidden)
Attributes
- Inherited from:
- LoggingMethods
Attributes
- Inherited from:
- LoggingMethods
Compares the receiver object (this
) with the argument object (that
) for equivalence.
Compares the receiver object (this
) with the argument object (that
) for equivalence.
Any implementation of this method should be an equivalence relation:
- It is reflexive: for any instance
x
of typeAny
,x.equals(x)
should returntrue
. - It is symmetric: for any instances
x
andy
of typeAny
,x.equals(y)
should returntrue
if and only ify.equals(x)
returnstrue
. - It is transitive: for any instances
x
,y
, andz
of typeAny
ifx.equals(y)
returnstrue
andy.equals(z)
returnstrue
, thenx.equals(z)
should returntrue
.
If you override this method, you should verify that your implementation remains an equivalence relation.
Additionally, when overriding this method it is usually necessary to override hashCode
to ensure that
objects which are "equal" (o1.equals(o2)
returns true
) hash to the same scala.Int.
(o1.hashCode.equals(o2.hashCode)
).
Attributes
Attributes
- Inherited from:
- LoggingMethods
Attributes
- Inherited from:
- LoggingMethods
Calculate a hash code value for the object.
Calculate a hash code value for the object.
The default hashing algorithm is platform dependent.
Note that it is allowed for two objects to have identical hash codes (o1.hashCode.equals(o2.hashCode)
) yet
not be equal (o1.equals(o2)
returns false
). A degenerate implementation could always return 0
.
However, it is required that if two objects are equal (o1.equals(o2)
returns true
) that they have
identical hash codes (o1.hashCode.equals(o2.hashCode)
). Therefore, when overriding this method, be sure
to verify that the behavior is consistent with the equals
method.
Attributes
Attributes
- Inherited from:
- LoggingMethods
Attributes
- Inherited from:
- LoggingMethods
Attributes
- Inherited from:
- LoggingMethods
Generates a minimized design by removing overwritten bindings
Create a new session.
Create a new session.
With this method, the session will not start automatically. You need to explicitly call session.start and session.shutdown to start/terminate the lifecycle of objects
Attributes
- Inherited from:
- Design
Method for configuring the session in details
Attributes
- Inherited from:
- Design
Attributes
- Inherited from:
- Design
Execute a given code block by building A using this design, and return B
Execute a given code block by building A using this design, and return B
Attributes
- Inherited from:
- DesignImpl (hidden)
Used for casting itself as Design if returning DesignWithContext type is cumbersome
Used for casting itself as Design if returning DesignWithContext type is cumbersome
Attributes
- Inherited from:
- Design
Attributes
- Inherited from:
- LoggingMethods
Attributes
- Inherited from:
- LoggingMethods
Attributes
- Inherited from:
- LoggingMethods
Attributes
- Inherited from:
- LoggingMethods
Do not initialize singletons for debugging
Attributes
- Inherited from:
- Design
Enable eager initialization of singletons services for production mode
Enable eager initialization of singletons services for production mode
Attributes
- Inherited from:
- Design
Run the code block with a new session.
Run the code block with a new session.
This method will create a new session, start it, run the given code block, and finally terminate the session after the code block completion.
Attributes
- Inherited from:
- Design
Use a custom binding tracer