Sha256: 83cf3ef987d6d0a99ad2c41407fa2a5e06b1bae73db3c25d07178a1e9c5f8715

Contents?: true

Size: 1.38 KB

Versions: 38

Compression:

Stored size: 1.38 KB

Contents

# 2.2
  * The `Polarizations` classes, e.g. in `FastTrack` could be steps in the normalizer? so we wouldn't need `reverse_merge`.

  # NOT lowest level. if you need that, use your own proc.
    # TODO: how do we track what goes into the callable?
    #                 adjust what goes into it (e.g. without direction or with kw args)?
    #                 pre contract -> step -> post contract (are these all just steps, in "mini nested pipe"?)
    #
    #
    # aka "Atom".
    def self.Task(instance: :context, method: :call, id:nil)


      # * ingoing contract (could be implemented as a nested pipe with 3 steps. that would allow us
      #   to compile it to native ruby method calls later)
      ->(direction, options, **flow_options) {
        instance = flow_options[:context] if instance==:context # TODO; implement different :context (e.g. :my_context).



      # * incoming args
        # step_args = [args] # TODO: overridable.
        step_args = [ options, **options ]

      # ** call the actual thing
        res = instance.send(method, *step_args) # what goes in? kws?

      # * interpret result (e.g. true=>Right) (should we keep doing that in the tie? so the op has it easier with success, etc?)
      # * outgoing contract
      # * outgoing args

        [ *res, flow_options ]


      # * tracing: incoming, outgoing, direction, etc. - do we want that in tasks, too?


      }
    end

Version data entries

38 entries across 38 versions & 1 rubygems

Version Path
trailblazer-activity-0.17.0 NOTES
trailblazer-activity-0.16.4 NOTES
trailblazer-activity-0.16.3 NOTES
trailblazer-activity-0.16.2 NOTES
trailblazer-activity-0.16.1 NOTES
trailblazer-activity-0.16.0 NOTES
trailblazer-activity-0.15.1 NOTES
trailblazer-activity-0.15.0 NOTES
trailblazer-activity-0.14.0 NOTES
trailblazer-activity-0.14.0.beta2 NOTES
trailblazer-activity-0.14.0.beta1 NOTES
trailblazer-activity-0.13.0 NOTES
trailblazer-activity-0.12.2 NOTES
trailblazer-activity-0.12.1 NOTES
trailblazer-activity-0.12.0 NOTES
trailblazer-activity-0.11.5 NOTES
trailblazer-activity-0.11.4 NOTES
trailblazer-activity-0.11.3 NOTES
trailblazer-activity-0.11.2 NOTES
trailblazer-activity-0.11.0 NOTES