0.1.7 • Published 6 years ago

u-async-ps v0.1.7

Weekly downloads
10
License
DO_WHATEVER_YOU_W...
Repository
github
Last release
6 years ago

u-async-ps

A "micro" OO running process implemented in plain functions && objects for understanding processes, threads, etc.

Version Build Status License

Prerequisites

  • NodeJs / NPM

Installation

  cd /path/to/your/project
  npm i --save 'u-async-ps'

Testing

From your application code.

const uAsyncPs = require('u-async-ps')
console.log('Successful uAsyncPs import? ', uAsyncPs)

Usage

This repo is under development. Initial LTS release will be 1.0.0, and it should not be used until then.

const uAsyncPs = require('u-async-ps')
const myPs = uAsyncPs(threadConfig)
myPs.spawnProcess(cycles)

Thread Configuration

Example

  • For A0 to execute, the LAST instruction MUST have been C2 (testing "NEXT instruction prediction" for B2)
  • For B1 to execute, the LAST instruction MUST have been C2
  • For B2 to execute, the LAST instruction MUST have been A0
  • All C Steps are unconditional, they fire on every step they are called
const threadConfig = [
  { name: 'A', instructions: [
    {index: 0, conditions: ['last===C2', 'next===B2']}, {index: 1}, {index: 2}
  ]},
  { name: 'B', instructions: [
    {index: 0}, {index: 1, conditions: ['last===C2']}, {index: 2, conditions: ['last===A0']}
  ]},
  { name: 'C', instructions: [
    {index: 0}, {index: 1}, {index: 2}, {index: 3}
  ]}
]

Contributing

Not currently accepting outside contributors, but feel free to clone, modify and use as you wish.

Authors

License

This project is licensed under the DO_WHATEVER_YOU_WANT License - see the LICENSE file for details

Acknowledgments

0.1.7

6 years ago

0.1.6

6 years ago

0.1.4

6 years ago

0.1.3

6 years ago

0.1.2

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago

0.0.26

6 years ago

0.0.25

6 years ago

0.0.24

6 years ago

0.0.23

6 years ago

0.0.22

6 years ago

0.0.21

6 years ago

0.0.20

6 years ago

0.0.19

6 years ago

0.0.18

6 years ago

0.0.17

6 years ago

0.0.16

6 years ago

0.0.15

6 years ago

0.0.14

6 years ago

0.0.13

6 years ago

0.0.12

6 years ago

0.0.11

6 years ago

0.0.10

6 years ago

0.0.9

6 years ago

0.0.8

6 years ago

0.0.7

6 years ago

0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago