Skip to content

A Declarative Framework for Describing Bidirectional Dataflow.

License

Notifications You must be signed in to change notification settings

kentaro/pratipad

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

53 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pratipad

Pratipad is a declarative framework for describing bidirectional dataflow.

Usage

Dataflow

defmodule Pratipad.Example.Dataflow do
  use Pratipad.Dataflow
  alias Pratipad.Dataflow.{Demand, Output}
  alias Pratipad.Example.Processor.Precipitation

  def declare() do
    Demand <~> Precipitation <~> Output
  end
end

Processor

defmodule Pratipad.Example.Processor.Precipitation do
  alias Pratipad.Processor
  use Processor

  @impl GenServer
  def init(opts \\ []) do
    {:ok, opts}
  end

  @impl Processor
  def process(data, state) do
    # do something with the message
  end
end

See the example repository for details.

Installation

If available in Hex, the package can be installed by adding pratipad to your list of dependencies in mix.exs:

def deps do
  [
    {:pratipad, "~> 0.1.0"}
  ]
end

Documentation can be generated with ExDoc and published on HexDocs. Once published, the docs can be found at https://hexdocs.pm/pratipad.

About

A Declarative Framework for Describing Bidirectional Dataflow.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages