case class InjectConstraints[+T](default: Option[() ⇒ T] = None, initialIdentifiers: List[Identifier] = Nil) extends Product with Serializable
A wrapper for a default value for the injection and for its identifiers.
It is here to make injection constraints look like natural language.
- T
type of the dependency being injected
- default
default value for injected instance. It would be used if biding is not found in the
Injector
.- initialIdentifiers
identifiers
- Alphabetic
- By Inheritance
- InjectConstraints
- Serializable
- Serializable
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
-
new
InjectConstraints(default: Option[() ⇒ T] = None, initialIdentifiers: List[Identifier] = Nil)
- default
default value for injected instance. It would be used if biding is not found in the
Injector
.- initialIdentifiers
identifiers
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
and(by: IdentifiedWord[_]): IdentifiedWord[T]
Helper method to make possible that "identified" follows "and" word.
Helper method to make possible that "identified" follows "and" word.
Example:
inject [Database] (by default defaultDb and identified by 'remote)
- by
IdentifiedWord
that follows the "and"
-
def
and(by: ByWord): ByWord
Helper method to define a default value for injection.
Helper method to define a default value for injection.
Example:
inject [Database] ('database and by default defaultDb)
- by
ByWord
that follows the "and"
-
def
and(ids: Identifier*): InjectConstraints.this.type
Appends identifier to a current list of identifiers.
Appends identifier to a current list of identifiers.
- ids
one or many other identifiers
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- val default: Option[() ⇒ T]
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- var identifiers: List[Identifier]
- val initialIdentifiers: List[Identifier]
-
def
is(by: ByWord): ByWord
Alias to "and"
Alias to "and"
Example:
inject [Database] ('remote is by default defaultDb)
- by
ByWord
that follows the "is"
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
that(by: ByWord): ByWord
Alias to "and"
Alias to "and"
Example:
inject [Database] ('remote that by default defaultDb)
- by
ByWord
that follows the "that"
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
which(by: ByWord): ByWord
Alias to "and"
Alias to "and"
Example:
inject [Database] ('remote which by default defaultDb)
- by
ByWord that follows the "which"