Create a named service call descriptor, identified by the name of the method that implements the service call.
Create a named service call descriptor, identified by the name of the method that implements the service call.
The method
parameter can be provided by passing a reference to the function that provides the service call.
ServiceSupport provides a number of implicit conversions and macros for converting these references to a
ScalaMethodServiceCall, which captures the actual method.
The DSL allows the following ways to pass method references:
// Eta-expanded method on this
call(getItem _)
// Invocation of parameterless method on this
call(getItem)
// Invocation of zero argument method on this
call(getItem())
The service call may or may not be qualified by this
. These are the only forms that the DSL permits, the macro
that implements this will inspect the passed in Scala AST to extract which method is invoked. Anything else passed
will result in a compilation failure.
A reference to the service call method.
A named service call descriptor.
Create a descriptor for a service with the given name.
Create a descriptor for a service with the given name.
The name of the service.
The descriptor.
Create a named service call descriptor, identified by the given name.
Create a named service call descriptor, identified by the given name.
The method
parameter can be provided by passing a reference to the function that provides the service call.
ServiceSupport provides a number of implicit conversions and macros for converting these references to a
ScalaMethodServiceCall, which captures the actual method.
The DSL allows the following ways to pass method references:
// Eta-expanded method on this
namedCall("item", getItem _)
// Invocation of parameterless method on this
namedCall("item", getItem)
// Invocation of zero argument method on this
namedCall("item", getItem())
The service call may or may not be qualified by this
. These are the only forms that the DSL permits, the macro
that implements this will inspect the passed in Scala AST to extract which method is invoked. Anything else passed
will result in a compilation failure.
The name of the service call.
A reference to the service call method.
A named service call descriptor.
Create a path service call descriptor, identified by the given path pattern.
Create a path service call descriptor, identified by the given path pattern.
The method
parameter can be provided by passing a reference to the function that provides the service call.
ServiceSupport provides a number of implicit conversions and macros for converting these references to a
ScalaMethodServiceCall, which captures the actual method, as well as the implicit serializers necessary to
convert the path parameters specified in the pathPattern
to and from the arguments for the method.
The DSL allows the following ways to pass method references:
// Eta-expanded method on this
pathCall("/item/:id", getItem _)
// Invocation of parameterless method on this
pathCall("/items", getItem)
// Invocation of zero argument method on this
pathCall("/items", getItem())
The service call may or may not be qualified by this
. These are the only forms that the DSL permits, the macro
that implements this will inspect the passed in Scala AST to extract which method is invoked. Anything else passed
will result in a compilation failure.
The path pattern.
A reference to the service call method.
A path based service call descriptor.
Create a REST service call descriptor, identified by the given HTTP method and path pattern.
Create a REST service call descriptor, identified by the given HTTP method and path pattern.
The scalaMethod
parameter can be provided by passing a reference to the function that provides the service call.
ServiceSupport provides a number of implicit conversions and macros for converting these references to a
ScalaMethodServiceCall, which captures the actual method, as well as the implicit serializers necessary to
convert the path parameters specified in the pathPattern
to and from the arguments for the method.
The DSL allows the following ways to pass method references:
// Eta-expanded method on this
restCall(Method.GET, "/item/:id", getItem _)
// Invocation of parameterless method on this
restCall(Method.GET, "/items", getItem)
// Invocation of zero argument method on this
restCall(Method.GET, "/items", getItem())
The service call may or may not be qualified by this
. These are the only forms that the DSL permits, the macro
that implements this will inspect the passed in Scala AST to extract which method is invoked. Anything else passed
will result in a compilation failure.
The HTTP method.
The path pattern.
A reference to the service call method.
A REST service call descriptor.
Create a topic descriptor.
Create a topic descriptor.
The method
parameter can be provided by passing a reference to the function that provides the topic.
ServiceSupport provides a number of implicit conversions and macros for converting these references to a
ScalaMethodServiceCall, which captures the actual method.
The DSL allows the following ways to pass method references:
// Eta-expanded method on this
topic("item-events", itemEventStream _)
// Invocation of parameterless method on this
topic("item-events", itemEventStream)
// Invocation of zero argument method on this
topic("item-events", itemEventStream)
The topic may or may not be qualified by this
. These are the only forms that the DSL permits, the macro
that implements this will inspect the passed in Scala AST to extract which method is invoked. Anything else passed
will result in a compilation failure.
The name of the topic.
A reference to the topic method.
A topic call descriptor.