Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide default empty start message for SequentialFunctor #120

Open
SebastianSchmidl opened this issue Oct 15, 2018 · 0 comments
Open

Provide default empty start message for SequentialFunctor #120

SebastianSchmidl opened this issue Oct 15, 2018 · 0 comments

Comments

@SebastianSchmidl
Copy link
Owner

Issue

Users have to define their own start messages.
The framework could provide a singleton message for start messages without any data and create the type alias in the framework:

import de.up.hpi.informationsystems.adbms.function.SequentialFunctor.StartMessage

val functor = SequentialFunctor()
  .start( (_: StartMessage) => _, _ )
  .end(identity)

Problem Description

Creating an empty start message for a SequentialFunctor is tedious:

sealed trait StartMessageType extends RequestResponseProtocol.Message
case object StartMessage extends RequestResponseProtocol.Request[StartMessageType]
type StartMessage = StartMessage.type

val functor = SequentialFunctor()
  .start( (_: StartMessage) => _, _ )
  .end(identity)

Supporting Information

see above

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant