Skip to content

Commit 55f838b

Browse files
committed
Upgrade references
1 parent 40f3346 commit 55f838b

File tree

10 files changed

+69
-161
lines changed

10 files changed

+69
-161
lines changed

examples/ArduinoML/MMArduinoML.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ let Class, Model, Enum
88
Model = JSMF.Model
99
Class = JSMF.Class
1010
Enum = JSMF.Enum
11-
}).call();
11+
}).call()
1212

1313

1414
const Signal = new Enum('Signal', ['LOW', 'HIGH'])

examples/ArduinoML/Switch.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ on.transition = tOn
2525
const aOff = AML.Action.newInstance({value: AML.Signal.LOW, actuator: led})
2626
const tOff = AML.Transition.newInstance({value: AML.Signal.HIGH, sensor: button})
2727
const off = AML.State.newInstance({name: 'off'})
28-
on.action = aOff
29-
on.transition = tOff
28+
off.action = aOff
29+
off.transition = tOff
3030

3131

3232
/*
@@ -41,15 +41,15 @@ tOff.next = on
4141
*/
4242

4343
const switchApp = AML.App.newInstance({
44-
name: 'Switch!',
45-
bricks: [button, led],
46-
states: [on, off],
47-
initial: off
44+
name: 'Switch!',
45+
bricks: [button, led],
46+
states: [on, off],
47+
initial: off
4848
})
4949

5050
const Switch = new Model('Switch', AML.ArduinoML, switchApp, true)
5151

5252
module.exports = {
53-
Switch: Switch,
54-
switchApp: switchApp
53+
Switch: Switch,
54+
switchApp: switchApp
5555
}

examples/ArduinoML/package.json

Lines changed: 0 additions & 11 deletions
This file was deleted.

examples/FamilyToPerson/Families.js

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
'use strict'
2+
3+
const JSMF = require('../../src/index')
4+
5+
let Class, Model, Enum
6+
7+
(function() {
8+
Model = JSMF.Model
9+
Class = JSMF.Class
10+
}).call()
11+
12+
const Member = new Class('Member', [], {firstName : String})
13+
const Family = new Class('Family', [], {lastName : String},
14+
{ father: { type: Member
15+
, cardinality: JSMF.Cardinality.one
16+
, opposite: 'familyFather'
17+
, oppositeCardinality: JSMF.Cardinality.optional
18+
}
19+
, mother: { type: Member
20+
, cardinality: JSMF.Cardinality.one
21+
, opposite: 'familyMother'
22+
, oppositeCardinality: JSMF.Cardinality.optional
23+
}
24+
, sons: { type: Member
25+
, cardinality: JSMF.Cardinality.any
26+
, opposite: 'familySon'
27+
, oppositeCardinality: JSMF.Cardinality.optional
28+
}
29+
, daughters: { type: Member
30+
, cardinality: JSMF.Cardinality.any
31+
, opposite: 'familyDaughter'
32+
, oppositeCardinality: JSMF.Cardinality.optional
33+
}
34+
})
35+
36+
const Families = new Model('Families', undefined, [Family, Member])
37+
38+
module.exports = {Families}

examples/FamilyToPerson/Persons.js

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
'use strict'
2+
3+
const JSMF = require('../../src/index')
4+
5+
let Class, Model, Enum
6+
7+
(function() {
8+
Model = JSMF.Model
9+
Class = JSMF.Class
10+
}).call()
11+
12+
const Person = new Class('Person', [], {fullName: String})
13+
const Male = new Class('Male', Person)
14+
const Female = new Class('Male', Person)
15+
16+
const Persons = new Model('Persons', undefined, [Person, Male, Female])
17+
18+
module.exports = {Persons}

examples/LegacyArduinoML/MArduinoML.js

Lines changed: 0 additions & 64 deletions
This file was deleted.

examples/LegacyArduinoML/MMArduinoML.js

Lines changed: 0 additions & 56 deletions
This file was deleted.

examples/LegacyArduinoML/README.md

Lines changed: 0 additions & 6 deletions
This file was deleted.

examples/LegacyArduinoML/package.json

Lines changed: 0 additions & 11 deletions
This file was deleted.

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@
2525
"author": "Jean-Sebastien Sottet <[email protected]> (http://www.list.lu/)",
2626
"license": "MIT",
2727
"dependencies": {
28-
"lodash": "^4.1.0",
29-
"uuid": "^2.0.1"
28+
"lodash": "^4.15.0",
29+
"uuid": "^2.0.3"
3030
},
3131
"devDependencies": {
32-
"should": "^7.1.1",
33-
"mocha": "^2.4.5",
32+
"should": "^11.1.0",
33+
"mocha": "^3.0.2",
3434
"assert": "^1.3.0"
3535
}
3636
}

0 commit comments

Comments
 (0)