Class: SiSU_Processing_Settings::ProcessingSettings

Inherits:
Object
  • Object
show all
Defined in:
lib/sisu/se_processing.rb

Direct Known Subclasses

SiSU_Env::ProcessingSettings

Instance Method Summary collapse

Constructor Details

#initialize(md) ⇒ ProcessingSettings

Returns a new instance of ProcessingSettings.



61
62
63
# File 'lib/sisu/se_processing.rb', line 61

def initialize(md)
  @md=md
end

Instance Method Details

#buildObject



78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
# File 'lib/sisu/se_processing.rb', line 78

def build
  def ocn?
    if cmd_rc_act[:ocn][:set]==:on
      true
    elsif cmd_rc_act[:ocn][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.ocn? \
    and doc_rc.toc? ==:off
      false
    elsif env_rc.build.ocn? ==:off
      false
    else
      true
    end
  end
  def plaintext_ocn?
    if cmd_rc_act[:txt_ocn][:set]==:on \
    or cmd_rc_act[:ocn][:set]==:on
      true
    elsif cmd_rc_act[:txt_ocn][:set]==:off \
    or cmd_rc_act[:ocn][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.ocn? \
    and doc_rc.toc? ==:off
      false
    elsif env_rc.build.ocn? ==:off
      false
    else
      true
    end
  end
  def odt_ocn?
    if cmd_rc_act[:odt_ocn][:set]==:on \
    or cmd_rc_act[:ocn][:set]==:on
      true
    elsif cmd_rc_act[:odt_ocn][:set]==:off \
    or cmd_rc_act[:ocn][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.ocn? \
    and doc_rc.toc? ==:off
      false
    elsif env_rc.build.ocn? ==:off
      false
    else
      true
    end
  end
  def html_strict?
    if cmd_rc_act[:html_strict][:set]==:on
      true
    elsif cmd_rc_act[:html_strict][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.html_strict? \
    and doc_rc.html_strict? ==:on
      true
    else
      false
    end
  end
  def toc?
    if cmd_rc_act[:toc][:set]==:on
      true
    elsif cmd_rc_act[:toc][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.toc? \
    and doc_rc.toc? ==:off
      false
    elsif env_rc.build.toc? ==:off
      false
    else
      true
    end
  end
  def manifest?
    if cmd_rc_act[:manifest][:set]==:on
      true
    elsif cmd_rc_act[:manifest][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.manifest? \
    and doc_rc.manifest? ==:off
      false
    elsif env_rc.build.manifest? ==:off
      false
    else
      true
    end
  end
  def links_to_manifest?
    if cmd_rc_act[:links_to_manifest][:set]==:on
      true
    elsif cmd_rc_act[:links_to_manifest][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.links_to_manifest? \
    and doc_rc.links_to_manifest? ==:off
      false
    elsif env_rc.build.links_to_manifest? ==:off
      false
    else
      true
    end
  end
  def metadata?
    if cmd_rc_act[:metadata][:set]==:on
      true
    elsif cmd_rc_act[:metadata][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.metadata? \
    and doc_rc.metadata? ==:off
      false
    elsif env_rc.build.metadata? ==:off
      false
    else
      true
    end
  end
  def minitoc?
    if html_top_band? == false #one form of navigation necessary
      true
    elsif cmd_rc_act[:minitoc][:set]==:on
      true
    elsif cmd_rc_act[:minitoc][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.minitoc? \
    and doc_rc.minitoc? ==:off
      false
    elsif env_rc.build.minitoc? ==:off
      false
    else
      true
    end
  end
  def manifest_minitoc?
    if html_top_band? == false #one form of navigation necessary
      true
    elsif cmd_rc_act[:manifest_minitoc][:set]==:on \
    || cmd_rc_act[:minitoc][:set]==:on
      true
    elsif cmd_rc_act[:manifest_minitoc][:set]==:off \
    || cmd_rc_act[:minitoc][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.manifest_minitoc? \
    and (doc_rc.manifest_minitoc? ==:off \
    || doc_rc.minitoc? ==:off)
      false
    elsif env_rc.build.manifest_minitoc? ==:off \
    || env_rc.build.minitoc? ==:off
      false
    elsif minitoc? == false
      false
    else
      true
    end
  end
  def html_minitoc?
    if html_top_band? == false #one form of navigation necessary
      true
    elsif cmd_rc_act[:html_minitoc][:set]==:on \
    || cmd_rc_act[:minitoc][:set]==:on
      true
    elsif cmd_rc_act[:html_minitoc][:set]==:off \
    || cmd_rc_act[:minitoc][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.html_minitoc? \
    and (doc_rc.html_minitoc? ==:off \
    || doc_rc.minitoc? ==:off)
      false
    elsif env_rc.build.html_minitoc? ==:off \
    || env_rc.build.minitoc? ==:off
      false
    elsif minitoc? == false
      false
    else
      true
    end
  end
  def html_top_band?
    if cmd_rc_act[:html_top_band][:set]==:on
      true
    elsif cmd_rc_act[:html_top_band][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.html_top_band? \
    and doc_rc.html_top_band? ==:off
      false
    elsif env_rc.build.html_top_band? ==:off
      false
    else
      true
    end
  end
  def html_navigation?
    if cmd_rc_act[:html_navigation][:set]==:on
      true
    elsif cmd_rc_act[:html_navigation][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.html_navigation? \
    and doc_rc.html_navigation? ==:off
      false
    elsif env_rc.build.html_navigation? ==:off
      false
    else
      true
    end
  end
  def html_navigation_bar?
    if cmd_rc_act[:html_navigation_bar][:set]==:on
      true
    elsif cmd_rc_act[:html_navigation_bar][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.html_navigation_bar? \
    and doc_rc.html_navigation_bar? ==:off
      false
    elsif env_rc.build.html_navigation_bar? ==:off
      false
    else
      false
    end
  end
  def search_form?
    if cmd_rc_act[:search_form][:set]==:on
      true
    elsif cmd_rc_act[:search_form][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.html_search_form? \
    and doc_rc.search_form? ==:off
      false
    elsif env_rc.build.search_form? ==:off
      false
    else
      true
    end
  end
  def html_search_form?
    if cmd_rc_act[:html_search_form][:set]==:on \
    || cmd_rc_act[:search_form][:set]==:on
      true
    elsif cmd_rc_act[:html_search_form][:set]==:off \
    || cmd_rc_act[:search_form][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.html_search_form? \
    and (doc_rc.html_search_form? ==:off \
    || doc_rc.search_form? ==:off)
      false
    elsif env_rc.build.html_search_form? ==:off \
    || env_rc.build.search_form? ==:off
      false
    elsif search_form? == false
      false
    else
      true
    end
  end
  def html_right_pane?
    if cmd_rc_act[:html_right_pane][:set]==:on
      true
    elsif cmd_rc_act[:html_right_pane][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.html_right_pane? \
    and doc_rc.html_right_pane? ==:off
      false
    elsif env_rc.build.html_right_pane? ==:off
      false
    else
      true
    end
  end
  def segsubtoc?
    if cmd_rc_act[:segsubtoc][:set]==:on
      true
    elsif cmd_rc_act[:segsubtoc][:set]==:off
      false
    elsif doc_rc.is_a?(Method) \
    and defined? doc_rc.segsubtoc? \
    and doc_rc.segsubtoc? ==:off
      false
    elsif env_rc.build.segsubtoc? ==:off
      false
    else
      true
    end
  end
  self
end

#by?Boolean

Returns:

  • (Boolean)


441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
# File 'lib/sisu/se_processing.rb', line 441

def by?
  if dump?
    :dump
  elsif redirect?
    :redirect
  elsif by_language_code?
    :language
  elsif by_filetype?
    :filetype
  elsif by_filename?
    :filename
  else #recheck current default
    :language
  end
end

#by_filename?Boolean

Returns:

  • (Boolean)


407
408
409
410
411
412
413
414
415
416
417
418
# File 'lib/sisu/se_processing.rb', line 407

def by_filename?
  if cmd_rc_act[:output_by][:set] == :filename
    true
  elsif cmd_rc_act[:output_by][:set] == :language \
  or cmd_rc_act[:output_by][:set] == :filetype
    false
  elsif cmd_rc_act[:output_by][:set] == :filename
    true
  else
    env_rc.output_dir_structure.by_filename?
  end
end

#by_filetype?Boolean

Returns:

  • (Boolean)


395
396
397
398
399
400
401
402
403
404
405
406
# File 'lib/sisu/se_processing.rb', line 395

def by_filetype?
  if cmd_rc_act[:output_by][:set] == :filetype
    true
  elsif cmd_rc_act[:output_by][:set] == :language \
  or cmd_rc_act[:output_by][:set] == :filename
    false
  elsif cmd_rc_act[:output_by][:set] == :filetype
    true
  else
    env_rc.output_dir_structure.by_filetype?
  end
end

#by_language_code?Boolean

Returns:

  • (Boolean)


383
384
385
386
387
388
389
390
391
392
393
394
# File 'lib/sisu/se_processing.rb', line 383

def by_language_code?
  if cmd_rc_act[:output_by][:set] == :language
    true
  elsif cmd_rc_act[:output_by][:set] == :filetype \
  or cmd_rc_act[:output_by][:set] == :filename
    false
  elsif cmd_rc_act[:output_by][:set] == :language
    true
  else
    env_rc.output_dir_structure.by_language_code?
  end
end

#cmd_rc_actObject

command-line rc



75
76
77
# File 'lib/sisu/se_processing.rb', line 75

def cmd_rc_act #command-line rc
  @cmd_rc_act=@md.opt.opt_act
end

#cnf_rcObject

sisurc.yml



64
65
66
# File 'lib/sisu/se_processing.rb', line 64

def cnf_rc #sisurc.yml
  @rc=SiSU_Env::GetInit.new.sisu_yaml.rc
end

#doc_rcObject

document rc, make instructions



70
71
72
73
74
# File 'lib/sisu/se_processing.rb', line 70

def doc_rc #document rc, make instructions
  (defined? @md.make) \
  ? @md.make
  : nil
end

#dump?Boolean

Returns:

  • (Boolean)


422
423
424
425
426
427
428
# File 'lib/sisu/se_processing.rb', line 422

def dump?
  ((cmd_rc_act[:dump][:bool] \
  &&  cmd_rc_act[:dump][:inst]) \
  || (env_rc.output_dir_structure.dump?)) \
  ? true
  : false
end

#dump_or_redirect?Boolean

Returns:

  • (Boolean)


436
437
438
439
440
# File 'lib/sisu/se_processing.rb', line 436

def dump_or_redirect?
  ((dump?) || (redirect?)) \
  ? true
  : false
end

#env_rcObject

env rc (including sisurc.yml)



67
68
69
# File 'lib/sisu/se_processing.rb', line 67

def env_rc #env rc (including sisurc.yml)
  @env_rc ||=SiSU_Env::InfoEnv.new(@md.fns)
end

#html_minitoc?Boolean

Returns:

  • (Boolean)


241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
# File 'lib/sisu/se_processing.rb', line 241

def html_minitoc?
  if html_top_band? == false #one form of navigation necessary
    true
  elsif cmd_rc_act[:html_minitoc][:set]==:on \
  || cmd_rc_act[:minitoc][:set]==:on
    true
  elsif cmd_rc_act[:html_minitoc][:set]==:off \
  || cmd_rc_act[:minitoc][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.html_minitoc? \
  and (doc_rc.html_minitoc? ==:off \
  || doc_rc.minitoc? ==:off)
    false
  elsif env_rc.build.html_minitoc? ==:off \
  || env_rc.build.minitoc? ==:off
    false
  elsif minitoc? == false
    false
  else
    true
  end
end

#html_navigation?Boolean

Returns:

  • (Boolean)


279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
# File 'lib/sisu/se_processing.rb', line 279

def html_navigation?
  if cmd_rc_act[:html_navigation][:set]==:on
    true
  elsif cmd_rc_act[:html_navigation][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.html_navigation? \
  and doc_rc.html_navigation? ==:off
    false
  elsif env_rc.build.html_navigation? ==:off
    false
  else
    true
  end
end

#html_navigation_bar?Boolean

Returns:

  • (Boolean)


294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
# File 'lib/sisu/se_processing.rb', line 294

def html_navigation_bar?
  if cmd_rc_act[:html_navigation_bar][:set]==:on
    true
  elsif cmd_rc_act[:html_navigation_bar][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.html_navigation_bar? \
  and doc_rc.html_navigation_bar? ==:off
    false
  elsif env_rc.build.html_navigation_bar? ==:off
    false
  else
    false
  end
end

#html_right_pane?Boolean

Returns:

  • (Boolean)


345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
# File 'lib/sisu/se_processing.rb', line 345

def html_right_pane?
  if cmd_rc_act[:html_right_pane][:set]==:on
    true
  elsif cmd_rc_act[:html_right_pane][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.html_right_pane? \
  and doc_rc.html_right_pane? ==:off
    false
  elsif env_rc.build.html_right_pane? ==:off
    false
  else
    true
  end
end

#html_search_form?Boolean

Returns:

  • (Boolean)


324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
# File 'lib/sisu/se_processing.rb', line 324

def html_search_form?
  if cmd_rc_act[:html_search_form][:set]==:on \
  || cmd_rc_act[:search_form][:set]==:on
    true
  elsif cmd_rc_act[:html_search_form][:set]==:off \
  || cmd_rc_act[:search_form][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.html_search_form? \
  and (doc_rc.html_search_form? ==:off \
  || doc_rc.search_form? ==:off)
    false
  elsif env_rc.build.html_search_form? ==:off \
  || env_rc.build.search_form? ==:off
    false
  elsif search_form? == false
    false
  else
    true
  end
end

#html_strict?Boolean

Returns:

  • (Boolean)


128
129
130
131
132
133
134
135
136
137
138
139
140
# File 'lib/sisu/se_processing.rb', line 128

def html_strict?
  if cmd_rc_act[:html_strict][:set]==:on
    true
  elsif cmd_rc_act[:html_strict][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.html_strict? \
  and doc_rc.html_strict? ==:on
    true
  else
    false
  end
end

#html_top_band?Boolean

Returns:

  • (Boolean)


264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
# File 'lib/sisu/se_processing.rb', line 264

def html_top_band?
  if cmd_rc_act[:html_top_band][:set]==:on
    true
  elsif cmd_rc_act[:html_top_band][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.html_top_band? \
  and doc_rc.html_top_band? ==:off
    false
  elsif env_rc.build.html_top_band? ==:off
    false
  else
    true
  end
end

Returns:

  • (Boolean)


171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
# File 'lib/sisu/se_processing.rb', line 171

def links_to_manifest?
  if cmd_rc_act[:links_to_manifest][:set]==:on
    true
  elsif cmd_rc_act[:links_to_manifest][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.links_to_manifest? \
  and doc_rc.links_to_manifest? ==:off
    false
  elsif env_rc.build.links_to_manifest? ==:off
    false
  else
    true
  end
end

#manifest?Boolean

Returns:

  • (Boolean)


156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
# File 'lib/sisu/se_processing.rb', line 156

def manifest?
  if cmd_rc_act[:manifest][:set]==:on
    true
  elsif cmd_rc_act[:manifest][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.manifest? \
  and doc_rc.manifest? ==:off
    false
  elsif env_rc.build.manifest? ==:off
    false
  else
    true
  end
end

#manifest_minitoc?Boolean

Returns:

  • (Boolean)


218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
# File 'lib/sisu/se_processing.rb', line 218

def manifest_minitoc?
  if html_top_band? == false #one form of navigation necessary
    true
  elsif cmd_rc_act[:manifest_minitoc][:set]==:on \
  || cmd_rc_act[:minitoc][:set]==:on
    true
  elsif cmd_rc_act[:manifest_minitoc][:set]==:off \
  || cmd_rc_act[:minitoc][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.manifest_minitoc? \
  and (doc_rc.manifest_minitoc? ==:off \
  || doc_rc.minitoc? ==:off)
    false
  elsif env_rc.build.manifest_minitoc? ==:off \
  || env_rc.build.minitoc? ==:off
    false
  elsif minitoc? == false
    false
  else
    true
  end
end

#metadata?Boolean

Returns:

  • (Boolean)


186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
# File 'lib/sisu/se_processing.rb', line 186

def metadata?
  if cmd_rc_act[:metadata][:set]==:on
    true
  elsif cmd_rc_act[:metadata][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.metadata? \
  and doc_rc.metadata? ==:off
    false
  elsif env_rc.build.metadata? ==:off
    false
  else
    true
  end
end

#minitoc?Boolean

Returns:

  • (Boolean)


201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
# File 'lib/sisu/se_processing.rb', line 201

def minitoc?
  if html_top_band? == false #one form of navigation necessary
    true
  elsif cmd_rc_act[:minitoc][:set]==:on
    true
  elsif cmd_rc_act[:minitoc][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.minitoc? \
  and doc_rc.minitoc? ==:off
    false
  elsif env_rc.build.minitoc? ==:off
    false
  else
    true
  end
end

#multilingual?Boolean

Returns:

  • (Boolean)


419
420
421
# File 'lib/sisu/se_processing.rb', line 419

def multilingual?
  by_language_code?
end

#ocn?Boolean

Returns:

  • (Boolean)


79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# File 'lib/sisu/se_processing.rb', line 79

def ocn?
  if cmd_rc_act[:ocn][:set]==:on
    true
  elsif cmd_rc_act[:ocn][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.ocn? \
  and doc_rc.toc? ==:off
    false
  elsif env_rc.build.ocn? ==:off
    false
  else
    true
  end
end

#ocn_html_identifierObject



377
378
379
380
381
# File 'lib/sisu/se_processing.rb', line 377

def ocn_html_identifier
  (build.html_strict?) \
  ? Mx[:ocn_id_char]
  : ''
end

#odt_ocn?Boolean

Returns:

  • (Boolean)


111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
# File 'lib/sisu/se_processing.rb', line 111

def odt_ocn?
  if cmd_rc_act[:odt_ocn][:set]==:on \
  or cmd_rc_act[:ocn][:set]==:on
    true
  elsif cmd_rc_act[:odt_ocn][:set]==:off \
  or cmd_rc_act[:ocn][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.ocn? \
  and doc_rc.toc? ==:off
    false
  elsif env_rc.build.ocn? ==:off
    false
  else
    true
  end
end

#output_dir_structureObject



382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
# File 'lib/sisu/se_processing.rb', line 382

def output_dir_structure
  def by_language_code?
    if cmd_rc_act[:output_by][:set] == :language
      true
    elsif cmd_rc_act[:output_by][:set] == :filetype \
    or cmd_rc_act[:output_by][:set] == :filename
      false
    elsif cmd_rc_act[:output_by][:set] == :language
      true
    else
      env_rc.output_dir_structure.by_language_code?
    end
  end
  def by_filetype?
    if cmd_rc_act[:output_by][:set] == :filetype
      true
    elsif cmd_rc_act[:output_by][:set] == :language \
    or cmd_rc_act[:output_by][:set] == :filename
      false
    elsif cmd_rc_act[:output_by][:set] == :filetype
      true
    else
      env_rc.output_dir_structure.by_filetype?
    end
  end
  def by_filename?
    if cmd_rc_act[:output_by][:set] == :filename
      true
    elsif cmd_rc_act[:output_by][:set] == :language \
    or cmd_rc_act[:output_by][:set] == :filetype
      false
    elsif cmd_rc_act[:output_by][:set] == :filename
      true
    else
      env_rc.output_dir_structure.by_filename?
    end
  end
  def multilingual?
    by_language_code?
  end
  def dump?
    ((cmd_rc_act[:dump][:bool] \
    &&  cmd_rc_act[:dump][:inst]) \
    || (env_rc.output_dir_structure.dump?)) \
    ? true
    : false
  end
  def redirect?
    ((cmd_rc_act[:redirect][:bool] \
    &&  cmd_rc_act[:redirect][:inst]) \
    || (env_rc.output_dir_structure.redirect?)) \
    ? true
    : false
  end
  def dump_or_redirect?
    ((dump?) || (redirect?)) \
    ? true
    : false
  end
  def by?
    if dump?
      :dump
    elsif redirect?
      :redirect
    elsif by_language_code?
      :language
    elsif by_filetype?
      :filetype
    elsif by_filename?
      :filename
    else #recheck current default
      :language
    end
  end
  self
end

#plaintext_ocn?Boolean

Returns:

  • (Boolean)


94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
# File 'lib/sisu/se_processing.rb', line 94

def plaintext_ocn?
  if cmd_rc_act[:txt_ocn][:set]==:on \
  or cmd_rc_act[:ocn][:set]==:on
    true
  elsif cmd_rc_act[:txt_ocn][:set]==:off \
  or cmd_rc_act[:ocn][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.ocn? \
  and doc_rc.toc? ==:off
    false
  elsif env_rc.build.ocn? ==:off
    false
  else
    true
  end
end

#redirect?Boolean

Returns:

  • (Boolean)


429
430
431
432
433
434
435
# File 'lib/sisu/se_processing.rb', line 429

def redirect?
  ((cmd_rc_act[:redirect][:bool] \
  &&  cmd_rc_act[:redirect][:inst]) \
  || (env_rc.output_dir_structure.redirect?)) \
  ? true
  : false
end

#search_form?Boolean

Returns:

  • (Boolean)


309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
# File 'lib/sisu/se_processing.rb', line 309

def search_form?
  if cmd_rc_act[:search_form][:set]==:on
    true
  elsif cmd_rc_act[:search_form][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.html_search_form? \
  and doc_rc.search_form? ==:off
    false
  elsif env_rc.build.search_form? ==:off
    false
  else
    true
  end
end

#segsubtoc?Boolean

Returns:

  • (Boolean)


360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
# File 'lib/sisu/se_processing.rb', line 360

def segsubtoc?
  if cmd_rc_act[:segsubtoc][:set]==:on
    true
  elsif cmd_rc_act[:segsubtoc][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.segsubtoc? \
  and doc_rc.segsubtoc? ==:off
    false
  elsif env_rc.build.segsubtoc? ==:off
    false
  else
    true
  end
end

#toc?Boolean

Returns:

  • (Boolean)


141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
# File 'lib/sisu/se_processing.rb', line 141

def toc?
  if cmd_rc_act[:toc][:set]==:on
    true
  elsif cmd_rc_act[:toc][:set]==:off
    false
  elsif doc_rc.is_a?(Method) \
  and defined? doc_rc.toc? \
  and doc_rc.toc? ==:off
    false
  elsif env_rc.build.toc? ==:off
    false
  else
    true
  end
end