pfa 1.2.0 → 1.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a58c95abe6fbc6bce5a654ee112527a19c9fe246e14131e91272080f993e82d7
4
- data.tar.gz: 15ab845938f1ee991c159cca196eab2b769dfdc894e9554374d417952781c79e
3
+ metadata.gz: f10c58fc537057a980066cf512d0000a428a9d6c014518e1780f1f6368cab2ae
4
+ data.tar.gz: 44a36902a87991c20a2367667717781fac771dca198d0b78762f15270222fa74
5
5
  SHA512:
6
- metadata.gz: f361f19a68751c35563dac9767a8cf290245d28da1c09d65483cfa08baf79ad3a181655d14f4f73ad75bad2832a395460fce216289b7148e446a749a92ea6cfa
7
- data.tar.gz: 21b4806cff3f374c27c1c4dc7f72e59d5492b8d6dd283c74fcd7ba7ba912487ebceba5ec2924bdb84e6114d2eacc651b796f88d561afa3d0d03ad96876c40eab
6
+ metadata.gz: cda5b5c693714a2e981d0dd0f97386b72c1994fad4abd2eb3e0e263a37851ab8675a3741bd96b0bac9b56ee589c51061c9adc4729dbadbd146ba980227998b4a
7
+ data.tar.gz: 32046d22e0371956c0f4043d674a1f718f022ccfe960c590ba76eca54e6d09d640dac0645fbd4a62363a8408209e0ba7b1601a2faaae84a3399eed629cdedc4d
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Change log
2
2
 
3
+ ## 1.3.0
4
+
5
+ * Bon gestion de l'identifiant lorsqu'il y a plusieurs PFAs dans un film.
6
+
3
7
  ## 1.2.0
4
8
 
5
9
  * gestion des identifiants de PFA pour en avoir plusieurs dans le même dossier (peut aussi servir à faire plusieurs versions).
@@ -87,8 +87,8 @@ nodes:
87
87
  hname: 'DÉV. PART I'
88
88
  abs_start: 1/4
89
89
  abs_duration: 1/4
90
- items: ['action_1_part1', 'premier_tiers', 'cle_de_voute']
91
- action_1_part1:
90
+ items: ['action1_part1', 'premier_tiers', 'cle_de_voute']
91
+ action1_part1:
92
92
  printed: false
93
93
  drawn: false # pas sur le PFA
94
94
  required: false
@@ -128,8 +128,8 @@ nodes:
128
128
  hname: 'DÉV. PART II'
129
129
  abs_start: 1/2
130
130
  abs_duration: 1/4
131
- items: ['action_1_part2', 'second_tiers', 'crise', 'pivot2']
132
- action_1_part2:
131
+ items: ['action1_part2', 'second_tiers', 'crise', 'pivot2']
132
+ action1_part2:
133
133
  printed: false
134
134
  drawn: false # pas sur le PFA
135
135
  required: false
@@ -179,8 +179,8 @@ nodes:
179
179
  hname: 'DÉNOUEMENT'
180
180
  abs_start: 3/4
181
181
  abs_duration: 1/4
182
- items: ['action_1_denouement', 'climax', 'desinence']
183
- action_1_denouement:
182
+ items: ['action1_denouement', 'climax', 'desinence']
183
+ action1_denouement:
184
184
  printed: false
185
185
  drawn: false # pas sur le PFA
186
186
  required: false
@@ -23,6 +23,10 @@ class RelativePFA
23
23
  # [Hash] Les données du Paradigme de Field Augmenté
24
24
  attr_reader :data
25
25
 
26
+ # [Integer] Indice éventuel du PFA (quand il y en a plusieurs dans
27
+ # un film)
28
+ attr_reader :pfa_id
29
+
26
30
  # Instanciation du paradigme
27
31
  #
28
32
  # @param input_data [Hash|Nil] Données du paradigme fournies à l'instanciation
@@ -33,6 +37,7 @@ class RelativePFA
33
37
  # -- Traitement de toutes les données fournies --
34
38
  #
35
39
  input_data ||= {}
40
+ @pfa_id = input_data.delete(:pfa_id) # indice éventuel du PFA
36
41
  input_data.each { |k, v| add(k, v) }
37
42
  end
38
43
 
@@ -49,12 +54,18 @@ class RelativePFA
49
54
  # Ajout d'un nœud dans le PFA
50
55
  #
51
56
  # On utilise pour le faire : pfa.add(key, value). Si c'est un
52
- # nœud, la valeur contient {t: '<horloge>', d: "description"}
57
+ # nœud, la valeur contient {t: '<horloge>', d: "description"} et
58
+ # peut-être la clé :pfa_id qui définit l'index du PFA à utiliser
59
+ #
60
+ # @note
61
+ # Je crois que maintenant +value+ est toujours un [Hash] définis-
62
+ # sant les données de la clé.
63
+ #
53
64
  # La clé :t peut-être remplacée par :time ou :start_at
54
65
  # La clé :d peut-être remplacée par :description
55
66
  #
56
67
  def add(key, value)
57
- # puts "-> add(#{key.inspect}, #{value.inspect}::#{value.class})".orange
68
+ puts "-> add(#{key.inspect}, #{value.inspect}::#{value.class})".orange
58
69
  key = key.to_sym
59
70
  if AbsolutePFA.data[:nodes].key?(key)
60
71
  #
data/lib/pfa/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module PFA
2
- VERSION = "1.2.0"
2
+ VERSION = "1.3.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pfa
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - PhilippePerret