pho 0.4.1 → 0.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (82) hide show
  1. data/CHANGES +18 -1
  2. data/README +10 -0
  3. data/Rakefile +2 -1
  4. data/doc/rdoc/classes/Pho.html +33 -22
  5. data/doc/rdoc/classes/Pho/DatatypeProperty.html +12 -12
  6. data/doc/rdoc/classes/Pho/{RDF_JSON.html → Enrichment.html} +8 -7
  7. data/doc/rdoc/classes/Pho/Enrichment/ResourceEnricher.html +310 -0
  8. data/doc/rdoc/classes/Pho/Etags.html +42 -42
  9. data/doc/rdoc/classes/Pho/Facet/Results.html +19 -19
  10. data/doc/rdoc/classes/Pho/Facet/Term.html +6 -6
  11. data/doc/rdoc/classes/Pho/FieldPredicateMap.html +110 -105
  12. data/doc/rdoc/classes/Pho/FieldWeighting.html +12 -12
  13. data/doc/rdoc/classes/Pho/FileManagement.html +121 -0
  14. data/doc/rdoc/classes/Pho/FileManagement/AbstractFileManager.html +443 -0
  15. data/doc/rdoc/classes/Pho/FileManagement/FileManager.html +258 -0
  16. data/doc/rdoc/classes/Pho/FileManagement/RDFManager.html +271 -0
  17. data/doc/rdoc/classes/Pho/Job.html +64 -64
  18. data/doc/rdoc/classes/Pho/Jobs.html +60 -60
  19. data/doc/rdoc/classes/Pho/QueryProfile.html +60 -60
  20. data/doc/rdoc/classes/Pho/RDFCollection.html +4 -378
  21. data/doc/rdoc/classes/Pho/ResourceHash.html +123 -0
  22. data/doc/rdoc/classes/Pho/ResourceHash/Converter.html +323 -0
  23. data/doc/rdoc/classes/Pho/{RDF_JSON → ResourceHash}/SetAlgebra.html +18 -18
  24. data/doc/rdoc/classes/Pho/Snapshot.html +35 -35
  25. data/doc/rdoc/classes/Pho/Sparql.html +137 -0
  26. data/doc/rdoc/classes/Pho/Sparql/SparqlClient.html +515 -0
  27. data/doc/rdoc/classes/Pho/Sparql/SparqlHelper.html +575 -0
  28. data/doc/rdoc/classes/Pho/Status.html +26 -26
  29. data/doc/rdoc/classes/Pho/Store.html +271 -241
  30. data/doc/rdoc/classes/Pho/Update/Changeset.html +73 -73
  31. data/doc/rdoc/classes/Pho/Update/ChangesetBuilder.html +34 -34
  32. data/doc/rdoc/classes/Pho/Update/Changesets.html +14 -14
  33. data/doc/rdoc/classes/Pho/Update/LiteralStatement.html +31 -23
  34. data/doc/rdoc/classes/Pho/Update/ResourceStatement.html +45 -21
  35. data/doc/rdoc/classes/Pho/Update/Statement.html +29 -29
  36. data/doc/rdoc/classes/String.html +1 -1
  37. data/doc/rdoc/created.rid +1 -1
  38. data/doc/rdoc/files/CHANGES.html +49 -3
  39. data/doc/rdoc/files/README.html +15 -1
  40. data/doc/rdoc/files/lib/pho/changeset_builder_rb.html +1 -1
  41. data/doc/rdoc/files/lib/pho/changeset_rb.html +1 -1
  42. data/doc/rdoc/files/lib/pho/converter_rb.html +108 -0
  43. data/doc/rdoc/files/lib/pho/enrichment_rb.html +101 -0
  44. data/doc/rdoc/files/lib/pho/etags_rb.html +1 -1
  45. data/doc/rdoc/files/lib/pho/field_predicate_map_rb.html +1 -1
  46. data/doc/rdoc/files/lib/pho/file_management_rb.html +101 -0
  47. data/doc/rdoc/files/lib/pho/file_manager_rb.html +108 -0
  48. data/doc/rdoc/files/lib/pho/rdf_collection_rb.html +1 -1
  49. data/doc/rdoc/files/lib/pho/resource_hash_rb.html +101 -0
  50. data/doc/rdoc/files/lib/pho/{rdf_json_rb.html → sparql_rb.html} +4 -4
  51. data/doc/rdoc/files/lib/pho/store_rb.html +1 -1
  52. data/doc/rdoc/files/lib/pho_rb.html +7 -2
  53. data/doc/rdoc/fr_class_index.html +12 -2
  54. data/doc/rdoc/fr_file_index.html +6 -1
  55. data/doc/rdoc/fr_method_index.html +176 -139
  56. data/examples/sparql_construct_hash.rb +26 -0
  57. data/examples/sparql_select.rb +18 -0
  58. data/lib/pho.rb +6 -1
  59. data/lib/pho/changeset.rb +24 -9
  60. data/lib/pho/changeset_builder.rb +10 -10
  61. data/lib/pho/converter.rb +74 -0
  62. data/lib/pho/enrichment.rb +81 -0
  63. data/lib/pho/etags.rb +1 -0
  64. data/lib/pho/field_predicate_map.rb +6 -1
  65. data/lib/pho/file_management.rb +102 -0
  66. data/lib/pho/file_manager.rb +61 -0
  67. data/lib/pho/rdf_collection.rb +54 -120
  68. data/lib/pho/{rdf_json.rb → resource_hash.rb} +3 -4
  69. data/lib/pho/sparql.rb +332 -0
  70. data/lib/pho/store.rb +20 -14
  71. data/tests/tc_changeset.rb +46 -0
  72. data/tests/tc_changeset_builder.rb +122 -1
  73. data/tests/tc_converter.rb +95 -0
  74. data/tests/tc_enrichment.rb +83 -0
  75. data/tests/tc_file_manager.rb +88 -0
  76. data/tests/tc_rdf_collection.rb +3 -0
  77. data/tests/{tc_rdf_json.rb → tc_resource_hash.rb} +23 -23
  78. data/tests/tc_search.rb +1 -1
  79. data/tests/tc_sparql.rb +131 -6
  80. data/tests/tc_sparql_helper.rb +214 -0
  81. data/tests/ts_pho.rb +6 -2
  82. metadata +47 -8
@@ -101,16 +101,16 @@ about a specific <a href="Job.html">Job</a> from a platform store
101
101
  <h3 class="section-bar">Methods</h3>
102
102
 
103
103
  <div class="name-list">
104
- <a href="#M000117">completed?</a>&nbsp;&nbsp;
105
- <a href="#M000112">new</a>&nbsp;&nbsp;
106
- <a href="#M000114">parse</a>&nbsp;&nbsp;
107
- <a href="#M000115">progress_updates</a>&nbsp;&nbsp;
108
- <a href="#M000113">read_from_store</a>&nbsp;&nbsp;
109
- <a href="#M000119">running?</a>&nbsp;&nbsp;
110
- <a href="#M000116">started?</a>&nbsp;&nbsp;
111
- <a href="#M000118">successful?</a>&nbsp;&nbsp;
112
- <a href="#M000121">with_each</a>&nbsp;&nbsp;
113
- <a href="#M000120">with_first</a>&nbsp;&nbsp;
104
+ <a href="#M000165">completed?</a>&nbsp;&nbsp;
105
+ <a href="#M000160">new</a>&nbsp;&nbsp;
106
+ <a href="#M000162">parse</a>&nbsp;&nbsp;
107
+ <a href="#M000163">progress_updates</a>&nbsp;&nbsp;
108
+ <a href="#M000161">read_from_store</a>&nbsp;&nbsp;
109
+ <a href="#M000167">running?</a>&nbsp;&nbsp;
110
+ <a href="#M000164">started?</a>&nbsp;&nbsp;
111
+ <a href="#M000166">successful?</a>&nbsp;&nbsp;
112
+ <a href="#M000169">with_each</a>&nbsp;&nbsp;
113
+ <a href="#M000168">with_first</a>&nbsp;&nbsp;
114
114
  </div>
115
115
  </div>
116
116
 
@@ -255,11 +255,11 @@ URI of the job
255
255
  <div id="methods">
256
256
  <h3 class="section-bar">Public Class methods</h3>
257
257
 
258
- <div id="method-M000112" class="method-detail">
259
- <a name="M000112"></a>
258
+ <div id="method-M000160" class="method-detail">
259
+ <a name="M000160"></a>
260
260
 
261
261
  <div class="method-heading">
262
- <a href="#M000112" class="method-signature">
262
+ <a href="#M000160" class="method-signature">
263
263
  <span class="method-name">new</span><span class="method-args">(uri, label, type, start_time, created=nil)</span>
264
264
  </a>
265
265
  </div>
@@ -286,8 +286,8 @@ Constructor. Used in the reading/parsing code
286
286
  </td></tr>
287
287
  </table>
288
288
  <p><a class="source-toggle" href="#"
289
- onclick="toggleCode('M000112-source');return false;">[Source]</a></p>
290
- <div class="method-source-code" id="M000112-source">
289
+ onclick="toggleCode('M000160-source');return false;">[Source]</a></p>
290
+ <div class="method-source-code" id="M000160-source">
291
291
  <pre>
292
292
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 214</span>
293
293
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">uri</span>, <span class="ruby-identifier">label</span>, <span class="ruby-identifier">type</span>, <span class="ruby-identifier">start_time</span>, <span class="ruby-identifier">created</span>=<span class="ruby-keyword kw">nil</span>)
@@ -303,11 +303,11 @@ Constructor. Used in the reading/parsing code
303
303
  </div>
304
304
  </div>
305
305
 
306
- <div id="method-M000114" class="method-detail">
307
- <a name="M000114"></a>
306
+ <div id="method-M000162" class="method-detail">
307
+ <a name="M000162"></a>
308
308
 
309
309
  <div class="method-heading">
310
- <a href="#M000114" class="method-signature">
310
+ <a href="#M000162" class="method-signature">
311
311
  <span class="method-name">parse</span><span class="method-args">(uri, xml)</span>
312
312
  </a>
313
313
  </div>
@@ -326,8 +326,8 @@ populated <a href="Job.html">Job</a> instance
326
326
  </td></tr>
327
327
  </table>
328
328
  <p><a class="source-toggle" href="#"
329
- onclick="toggleCode('M000114-source');return false;">[Source]</a></p>
330
- <div class="method-source-code" id="M000114-source">
329
+ onclick="toggleCode('M000162-source');return false;">[Source]</a></p>
330
+ <div class="method-source-code" id="M000162-source">
331
331
  <pre>
332
332
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 241</span>
333
333
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Job</span>.<span class="ruby-identifier">parse</span>(<span class="ruby-identifier">uri</span>, <span class="ruby-identifier">xml</span>)
@@ -384,11 +384,11 @@ populated <a href="Job.html">Job</a> instance
384
384
  </div>
385
385
  </div>
386
386
 
387
- <div id="method-M000113" class="method-detail">
388
- <a name="M000113"></a>
387
+ <div id="method-M000161" class="method-detail">
388
+ <a name="M000161"></a>
389
389
 
390
390
  <div class="method-heading">
391
- <a href="#M000113" class="method-signature">
391
+ <a href="#M000161" class="method-signature">
392
392
  <span class="method-name">read_from_store</span><span class="method-args">(uri, store)</span>
393
393
  </a>
394
394
  </div>
@@ -406,8 +406,8 @@ Read a job from a store
406
406
  </td></tr>
407
407
  </table>
408
408
  <p><a class="source-toggle" href="#"
409
- onclick="toggleCode('M000113-source');return false;">[Source]</a></p>
410
- <div class="method-source-code" id="M000113-source">
409
+ onclick="toggleCode('M000161-source');return false;">[Source]</a></p>
410
+ <div class="method-source-code" id="M000161-source">
411
411
  <pre>
412
412
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 227</span>
413
413
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Job</span>.<span class="ruby-identifier">read_from_store</span>(<span class="ruby-identifier">uri</span>, <span class="ruby-identifier">store</span>)
@@ -425,19 +425,19 @@ Read a job from a store
425
425
 
426
426
  <h3 class="section-bar">Protected Class methods</h3>
427
427
 
428
- <div id="method-M000121" class="method-detail">
429
- <a name="M000121"></a>
428
+ <div id="method-M000169" class="method-detail">
429
+ <a name="M000169"></a>
430
430
 
431
431
  <div class="method-heading">
432
- <a href="#M000121" class="method-signature">
432
+ <a href="#M000169" class="method-signature">
433
433
  <span class="method-name">with_each</span><span class="method-args">(el, xpath) {|ref_el| ...}</span>
434
434
  </a>
435
435
  </div>
436
436
 
437
437
  <div class="method-description">
438
438
  <p><a class="source-toggle" href="#"
439
- onclick="toggleCode('M000121-source');return false;">[Source]</a></p>
440
- <div class="method-source-code" id="M000121-source">
439
+ onclick="toggleCode('M000169-source');return false;">[Source]</a></p>
440
+ <div class="method-source-code" id="M000169-source">
441
441
  <pre>
442
442
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 327</span>
443
443
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Job</span>.<span class="ruby-identifier">with_each</span>(<span class="ruby-identifier">el</span>, <span class="ruby-identifier">xpath</span>)
@@ -453,19 +453,19 @@ Read a job from a store
453
453
  </div>
454
454
  </div>
455
455
 
456
- <div id="method-M000120" class="method-detail">
457
- <a name="M000120"></a>
456
+ <div id="method-M000168" class="method-detail">
457
+ <a name="M000168"></a>
458
458
 
459
459
  <div class="method-heading">
460
- <a href="#M000120" class="method-signature">
460
+ <a href="#M000168" class="method-signature">
461
461
  <span class="method-name">with_first</span><span class="method-args">(el, xpath) {|found_el| ...}</span>
462
462
  </a>
463
463
  </div>
464
464
 
465
465
  <div class="method-description">
466
466
  <p><a class="source-toggle" href="#"
467
- onclick="toggleCode('M000120-source');return false;">[Source]</a></p>
468
- <div class="method-source-code" id="M000120-source">
467
+ onclick="toggleCode('M000168-source');return false;">[Source]</a></p>
468
+ <div class="method-source-code" id="M000168-source">
469
469
  <pre>
470
470
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 320</span>
471
471
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Job</span>.<span class="ruby-identifier">with_first</span>(<span class="ruby-identifier">el</span>, <span class="ruby-identifier">xpath</span>)
@@ -481,22 +481,22 @@ Read a job from a store
481
481
 
482
482
  <h3 class="section-bar">Public Instance methods</h3>
483
483
 
484
- <div id="method-M000117" class="method-detail">
485
- <a name="M000117"></a>
484
+ <div id="method-M000165" class="method-detail">
485
+ <a name="M000165"></a>
486
486
 
487
487
  <div class="method-heading">
488
- <a href="#M000117" class="method-signature">
488
+ <a href="#M000165" class="method-signature">
489
489
  <span class="method-name">completed?</span><span class="method-args">()</span>
490
490
  </a>
491
491
  </div>
492
492
 
493
493
  <div class="method-description">
494
494
  <p>
495
- Has the job <a href="Job.html#M000117">completed?</a>
495
+ Has the job <a href="Job.html#M000165">completed?</a>
496
496
  </p>
497
497
  <p><a class="source-toggle" href="#"
498
- onclick="toggleCode('M000117-source');return false;">[Source]</a></p>
499
- <div class="method-source-code" id="M000117-source">
498
+ onclick="toggleCode('M000165-source');return false;">[Source]</a></p>
499
+ <div class="method-source-code" id="M000165-source">
500
500
  <pre>
501
501
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 304</span>
502
502
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">completed?</span>
@@ -507,19 +507,19 @@ Has the job <a href="Job.html#M000117">completed?</a>
507
507
  </div>
508
508
  </div>
509
509
 
510
- <div id="method-M000115" class="method-detail">
511
- <a name="M000115"></a>
510
+ <div id="method-M000163" class="method-detail">
511
+ <a name="M000163"></a>
512
512
 
513
513
  <div class="method-heading">
514
- <a href="#M000115" class="method-signature">
514
+ <a href="#M000163" class="method-signature">
515
515
  <span class="method-name">progress_updates</span><span class="method-args">()</span>
516
516
  </a>
517
517
  </div>
518
518
 
519
519
  <div class="method-description">
520
520
  <p><a class="source-toggle" href="#"
521
- onclick="toggleCode('M000115-source');return false;">[Source]</a></p>
522
- <div class="method-source-code" id="M000115-source">
521
+ onclick="toggleCode('M000163-source');return false;">[Source]</a></p>
522
+ <div class="method-source-code" id="M000163-source">
523
523
  <pre>
524
524
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 291</span>
525
525
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">progress_updates</span>()
@@ -533,22 +533,22 @@ Has the job <a href="Job.html#M000117">completed?</a>
533
533
  </div>
534
534
  </div>
535
535
 
536
- <div id="method-M000119" class="method-detail">
537
- <a name="M000119"></a>
536
+ <div id="method-M000167" class="method-detail">
537
+ <a name="M000167"></a>
538
538
 
539
539
  <div class="method-heading">
540
- <a href="#M000119" class="method-signature">
540
+ <a href="#M000167" class="method-signature">
541
541
  <span class="method-name">running?</span><span class="method-args">()</span>
542
542
  </a>
543
543
  </div>
544
544
 
545
545
  <div class="method-description">
546
546
  <p>
547
- Is the job still <a href="Job.html#M000119">running?</a>
547
+ Is the job still <a href="Job.html#M000167">running?</a>
548
548
  </p>
549
549
  <p><a class="source-toggle" href="#"
550
- onclick="toggleCode('M000119-source');return false;">[Source]</a></p>
551
- <div class="method-source-code" id="M000119-source">
550
+ onclick="toggleCode('M000167-source');return false;">[Source]</a></p>
551
+ <div class="method-source-code" id="M000167-source">
552
552
  <pre>
553
553
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 314</span>
554
554
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">running?</span>
@@ -559,22 +559,22 @@ Is the job still <a href="Job.html#M000119">running?</a>
559
559
  </div>
560
560
  </div>
561
561
 
562
- <div id="method-M000116" class="method-detail">
563
- <a name="M000116"></a>
562
+ <div id="method-M000164" class="method-detail">
563
+ <a name="M000164"></a>
564
564
 
565
565
  <div class="method-heading">
566
- <a href="#M000116" class="method-signature">
566
+ <a href="#M000164" class="method-signature">
567
567
  <span class="method-name">started?</span><span class="method-args">()</span>
568
568
  </a>
569
569
  </div>
570
570
 
571
571
  <div class="method-description">
572
572
  <p>
573
- Has the job <a href="Job.html#M000116">started?</a>
573
+ Has the job <a href="Job.html#M000164">started?</a>
574
574
  </p>
575
575
  <p><a class="source-toggle" href="#"
576
- onclick="toggleCode('M000116-source');return false;">[Source]</a></p>
577
- <div class="method-source-code" id="M000116-source">
576
+ onclick="toggleCode('M000164-source');return false;">[Source]</a></p>
577
+ <div class="method-source-code" id="M000164-source">
578
578
  <pre>
579
579
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 299</span>
580
580
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">started?</span>
@@ -585,22 +585,22 @@ Has the job <a href="Job.html#M000116">started?</a>
585
585
  </div>
586
586
  </div>
587
587
 
588
- <div id="method-M000118" class="method-detail">
589
- <a name="M000118"></a>
588
+ <div id="method-M000166" class="method-detail">
589
+ <a name="M000166"></a>
590
590
 
591
591
  <div class="method-heading">
592
- <a href="#M000118" class="method-signature">
592
+ <a href="#M000166" class="method-signature">
593
593
  <span class="method-name">successful?</span><span class="method-args">()</span>
594
594
  </a>
595
595
  </div>
596
596
 
597
597
  <div class="method-description">
598
598
  <p>
599
- Was the job <a href="Job.html#M000118">successful?</a>
599
+ Was the job <a href="Job.html#M000166">successful?</a>
600
600
  </p>
601
601
  <p><a class="source-toggle" href="#"
602
- onclick="toggleCode('M000118-source');return false;">[Source]</a></p>
603
- <div class="method-source-code" id="M000118-source">
602
+ onclick="toggleCode('M000166-source');return false;">[Source]</a></p>
603
+ <div class="method-source-code" id="M000166-source">
604
604
  <pre>
605
605
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 309</span>
606
606
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">successful?</span>
@@ -92,16 +92,16 @@ TODO job deletion
92
92
  <h3 class="section-bar">Methods</h3>
93
93
 
94
94
  <div class="name-list">
95
- <a href="#M000069">build_job_request</a>&nbsp;&nbsp;
96
- <a href="#M000063">read_from_store</a>&nbsp;&nbsp;
97
- <a href="#M000068">submit_job</a>&nbsp;&nbsp;
98
- <a href="#M000065">submit_reindex</a>&nbsp;&nbsp;
99
- <a href="#M000064">submit_reset</a>&nbsp;&nbsp;
100
- <a href="#M000067">submit_restore</a>&nbsp;&nbsp;
101
- <a href="#M000066">submit_snapshot</a>&nbsp;&nbsp;
102
- <a href="#M000071">wait_for</a>&nbsp;&nbsp;
103
- <a href="#M000070">wait_for_submitted</a>&nbsp;&nbsp;
104
- <a href="#M000072">yield_job_update</a>&nbsp;&nbsp;
95
+ <a href="#M000116">build_job_request</a>&nbsp;&nbsp;
96
+ <a href="#M000110">read_from_store</a>&nbsp;&nbsp;
97
+ <a href="#M000115">submit_job</a>&nbsp;&nbsp;
98
+ <a href="#M000112">submit_reindex</a>&nbsp;&nbsp;
99
+ <a href="#M000111">submit_reset</a>&nbsp;&nbsp;
100
+ <a href="#M000114">submit_restore</a>&nbsp;&nbsp;
101
+ <a href="#M000113">submit_snapshot</a>&nbsp;&nbsp;
102
+ <a href="#M000118">wait_for</a>&nbsp;&nbsp;
103
+ <a href="#M000117">wait_for_submitted</a>&nbsp;&nbsp;
104
+ <a href="#M000119">yield_job_update</a>&nbsp;&nbsp;
105
105
  </div>
106
106
  </div>
107
107
 
@@ -151,11 +151,11 @@ TODO job deletion
151
151
  <div id="methods">
152
152
  <h3 class="section-bar">Public Class methods</h3>
153
153
 
154
- <div id="method-M000069" class="method-detail">
155
- <a name="M000069"></a>
154
+ <div id="method-M000116" class="method-detail">
155
+ <a name="M000116"></a>
156
156
 
157
157
  <div class="method-heading">
158
- <a href="#M000069" class="method-signature">
158
+ <a href="#M000116" class="method-signature">
159
159
  <span class="method-name">build_job_request</span><span class="method-args">(type, label, t=Time.now, snapshot_uri=nil)</span>
160
160
  </a>
161
161
  </div>
@@ -172,8 +172,8 @@ out
172
172
  </td></tr>
173
173
  </table>
174
174
  <p><a class="source-toggle" href="#"
175
- onclick="toggleCode('M000069-source');return false;">[Source]</a></p>
176
- <div class="method-source-code" id="M000069-source">
175
+ onclick="toggleCode('M000116-source');return false;">[Source]</a></p>
176
+ <div class="method-source-code" id="M000116-source">
177
177
  <pre>
178
178
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 79</span>
179
179
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">build_job_request</span>(<span class="ruby-identifier">type</span>, <span class="ruby-identifier">label</span>, <span class="ruby-identifier">t</span>=<span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>, <span class="ruby-identifier">snapshot_uri</span>=<span class="ruby-keyword kw">nil</span>)
@@ -200,11 +200,11 @@ out
200
200
  </div>
201
201
  </div>
202
202
 
203
- <div id="method-M000063" class="method-detail">
204
- <a name="M000063"></a>
203
+ <div id="method-M000110" class="method-detail">
204
+ <a name="M000110"></a>
205
205
 
206
206
  <div class="method-heading">
207
- <a href="#M000063" class="method-signature">
207
+ <a href="#M000110" class="method-signature">
208
208
  <span class="method-name">read_from_store</span><span class="method-args">(store)</span>
209
209
  </a>
210
210
  </div>
@@ -218,8 +218,8 @@ an array of job names
218
218
  store:: store from which to read the scheduled job list
219
219
  </pre>
220
220
  <p><a class="source-toggle" href="#"
221
- onclick="toggleCode('M000063-source');return false;">[Source]</a></p>
222
- <div class="method-source-code" id="M000063-source">
221
+ onclick="toggleCode('M000110-source');return false;">[Source]</a></p>
222
+ <div class="method-source-code" id="M000110-source">
223
223
  <pre>
224
224
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 16</span>
225
225
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">read_from_store</span>(<span class="ruby-identifier">store</span>)
@@ -241,11 +241,11 @@ an array of job names
241
241
  </div>
242
242
  </div>
243
243
 
244
- <div id="method-M000068" class="method-detail">
245
- <a name="M000068"></a>
244
+ <div id="method-M000115" class="method-detail">
245
+ <a name="M000115"></a>
246
246
 
247
247
  <div class="method-heading">
248
- <a href="#M000068" class="method-signature">
248
+ <a href="#M000115" class="method-signature">
249
249
  <span class="method-name">submit_job</span><span class="method-args">(store, jobtype, label, t=Time.now, snapshot_uri=nil)</span>
250
250
  </a>
251
251
  </div>
@@ -255,8 +255,8 @@ an array of job names
255
255
  Generic submit job method
256
256
  </p>
257
257
  <p><a class="source-toggle" href="#"
258
- onclick="toggleCode('M000068-source');return false;">[Source]</a></p>
259
- <div class="method-source-code" id="M000068-source">
258
+ onclick="toggleCode('M000115-source');return false;">[Source]</a></p>
259
+ <div class="method-source-code" id="M000115-source">
260
260
  <pre>
261
261
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 72</span>
262
262
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">submit_job</span>(<span class="ruby-identifier">store</span>, <span class="ruby-identifier">jobtype</span>, <span class="ruby-identifier">label</span>, <span class="ruby-identifier">t</span>=<span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>, <span class="ruby-identifier">snapshot_uri</span>=<span class="ruby-keyword kw">nil</span>)
@@ -267,11 +267,11 @@ Generic submit job method
267
267
  </div>
268
268
  </div>
269
269
 
270
- <div id="method-M000065" class="method-detail">
271
- <a name="M000065"></a>
270
+ <div id="method-M000112" class="method-detail">
271
+ <a name="M000112"></a>
272
272
 
273
273
  <div class="method-heading">
274
- <a href="#M000065" class="method-signature">
274
+ <a href="#M000112" class="method-signature">
275
275
  <span class="method-name">submit_reindex</span><span class="method-args">(store, label=&quot;Reindex my store&quot;, t=Time.now)</span>
276
276
  </a>
277
277
  </div>
@@ -288,8 +288,8 @@ the newly created job and then monitor the jobs status if they need to wait
288
288
  for the job to finish.
289
289
  </p>
290
290
  <p><a class="source-toggle" href="#"
291
- onclick="toggleCode('M000065-source');return false;">[Source]</a></p>
292
- <div class="method-source-code" id="M000065-source">
291
+ onclick="toggleCode('M000112-source');return false;">[Source]</a></p>
292
+ <div class="method-source-code" id="M000112-source">
293
293
  <pre>
294
294
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 47</span>
295
295
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">submit_reindex</span>(<span class="ruby-identifier">store</span>, <span class="ruby-identifier">label</span>=<span class="ruby-value str">&quot;Reindex my store&quot;</span>, <span class="ruby-identifier">t</span>=<span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>)
@@ -300,11 +300,11 @@ for the job to finish.
300
300
  </div>
301
301
  </div>
302
302
 
303
- <div id="method-M000064" class="method-detail">
304
- <a name="M000064"></a>
303
+ <div id="method-M000111" class="method-detail">
304
+ <a name="M000111"></a>
305
305
 
306
306
  <div class="method-heading">
307
- <a href="#M000064" class="method-signature">
307
+ <a href="#M000111" class="method-signature">
308
308
  <span class="method-name">submit_reset</span><span class="method-args">(store, label=&quot;Reset my store&quot;, t=Time.now)</span>
309
309
  </a>
310
310
  </div>
@@ -321,8 +321,8 @@ the newly created job and then monitor the jobs status if they need to wait
321
321
  for the job to finish.
322
322
  </p>
323
323
  <p><a class="source-toggle" href="#"
324
- onclick="toggleCode('M000064-source');return false;">[Source]</a></p>
325
- <div class="method-source-code" id="M000064-source">
324
+ onclick="toggleCode('M000111-source');return false;">[Source]</a></p>
325
+ <div class="method-source-code" id="M000111-source">
326
326
  <pre>
327
327
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 37</span>
328
328
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">submit_reset</span>(<span class="ruby-identifier">store</span>, <span class="ruby-identifier">label</span>=<span class="ruby-value str">&quot;Reset my store&quot;</span>, <span class="ruby-identifier">t</span>=<span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>)
@@ -333,11 +333,11 @@ for the job to finish.
333
333
  </div>
334
334
  </div>
335
335
 
336
- <div id="method-M000067" class="method-detail">
337
- <a name="M000067"></a>
336
+ <div id="method-M000114" class="method-detail">
337
+ <a name="M000114"></a>
338
338
 
339
339
  <div class="method-heading">
340
- <a href="#M000067" class="method-signature">
340
+ <a href="#M000114" class="method-signature">
341
341
  <span class="method-name">submit_restore</span><span class="method-args">(store, snapshot_uri, label=&quot;Restore my snapshot&quot;, t=Time.now)</span>
342
342
  </a>
343
343
  </div>
@@ -354,8 +354,8 @@ the newly created job and then monitor the jobs status if they need to wait
354
354
  for the job to finish.
355
355
  </p>
356
356
  <p><a class="source-toggle" href="#"
357
- onclick="toggleCode('M000067-source');return false;">[Source]</a></p>
358
- <div class="method-source-code" id="M000067-source">
357
+ onclick="toggleCode('M000114-source');return false;">[Source]</a></p>
358
+ <div class="method-source-code" id="M000114-source">
359
359
  <pre>
360
360
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 67</span>
361
361
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">submit_restore</span>(<span class="ruby-identifier">store</span>, <span class="ruby-identifier">snapshot_uri</span>, <span class="ruby-identifier">label</span>=<span class="ruby-value str">&quot;Restore my snapshot&quot;</span>, <span class="ruby-identifier">t</span>=<span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>)
@@ -366,11 +366,11 @@ for the job to finish.
366
366
  </div>
367
367
  </div>
368
368
 
369
- <div id="method-M000066" class="method-detail">
370
- <a name="M000066"></a>
369
+ <div id="method-M000113" class="method-detail">
370
+ <a name="M000113"></a>
371
371
 
372
372
  <div class="method-heading">
373
- <a href="#M000066" class="method-signature">
373
+ <a href="#M000113" class="method-signature">
374
374
  <span class="method-name">submit_snapshot</span><span class="method-args">(store, label=&quot;Snapshot my store&quot;, t=Time.now)</span>
375
375
  </a>
376
376
  </div>
@@ -387,8 +387,8 @@ the newly created job and then monitor the jobs status if they need to wait
387
387
  for the job to finish.
388
388
  </p>
389
389
  <p><a class="source-toggle" href="#"
390
- onclick="toggleCode('M000066-source');return false;">[Source]</a></p>
391
- <div class="method-source-code" id="M000066-source">
390
+ onclick="toggleCode('M000113-source');return false;">[Source]</a></p>
391
+ <div class="method-source-code" id="M000113-source">
392
392
  <pre>
393
393
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 57</span>
394
394
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">submit_snapshot</span>(<span class="ruby-identifier">store</span>, <span class="ruby-identifier">label</span>=<span class="ruby-value str">&quot;Snapshot my store&quot;</span>, <span class="ruby-identifier">t</span>=<span class="ruby-constant">Time</span>.<span class="ruby-identifier">now</span>)
@@ -399,11 +399,11 @@ for the job to finish.
399
399
  </div>
400
400
  </div>
401
401
 
402
- <div id="method-M000071" class="method-detail">
403
- <a name="M000071"></a>
402
+ <div id="method-M000118" class="method-detail">
403
+ <a name="M000118"></a>
404
404
 
405
405
  <div class="method-heading">
406
- <a href="#M000071" class="method-signature">
406
+ <a href="#M000118" class="method-signature">
407
407
  <span class="method-name">wait_for</span><span class="method-args">(uri, store, interval=1, &amp;block)</span>
408
408
  </a>
409
409
  </div>
@@ -426,8 +426,8 @@ returned once completed.
426
426
  interval:: the interval at which checks will be made, in minutes. Default is 1
427
427
  </pre>
428
428
  <p><a class="source-toggle" href="#"
429
- onclick="toggleCode('M000071-source');return false;">[Source]</a></p>
430
- <div class="method-source-code" id="M000071-source">
429
+ onclick="toggleCode('M000118-source');return false;">[Source]</a></p>
430
+ <div class="method-source-code" id="M000118-source">
431
431
  <pre>
432
432
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 118</span>
433
433
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">wait_for</span>(<span class="ruby-identifier">uri</span>, <span class="ruby-identifier">store</span>, <span class="ruby-identifier">interval</span>=<span class="ruby-value">1</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
@@ -446,11 +446,11 @@ returned once completed.
446
446
  </div>
447
447
  </div>
448
448
 
449
- <div id="method-M000070" class="method-detail">
450
- <a name="M000070"></a>
449
+ <div id="method-M000117" class="method-detail">
450
+ <a name="M000117"></a>
451
451
 
452
452
  <div class="method-heading">
453
- <a href="#M000070" class="method-signature">
453
+ <a href="#M000117" class="method-signature">
454
454
  <span class="method-name">wait_for_submitted</span><span class="method-args">(resp, store, interval=1, &amp;block)</span>
455
455
  </a>
456
456
  </div>
@@ -460,8 +460,8 @@ returned once completed.
460
460
  Wait for a newly submitted job to finish
461
461
  </p>
462
462
  <p><a class="source-toggle" href="#"
463
- onclick="toggleCode('M000070-source');return false;">[Source]</a></p>
464
- <div class="method-source-code" id="M000070-source">
463
+ onclick="toggleCode('M000117-source');return false;">[Source]</a></p>
464
+ <div class="method-source-code" id="M000117-source">
465
465
  <pre>
466
466
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 100</span>
467
467
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">wait_for_submitted</span>(<span class="ruby-identifier">resp</span>, <span class="ruby-identifier">store</span>, <span class="ruby-identifier">interval</span>=<span class="ruby-value">1</span>, <span class="ruby-operator">&amp;</span><span class="ruby-identifier">block</span>)
@@ -478,19 +478,19 @@ Wait for a newly submitted job to finish
478
478
 
479
479
  <h3 class="section-bar">Protected Class methods</h3>
480
480
 
481
- <div id="method-M000072" class="method-detail">
482
- <a name="M000072"></a>
481
+ <div id="method-M000119" class="method-detail">
482
+ <a name="M000119"></a>
483
483
 
484
484
  <div class="method-heading">
485
- <a href="#M000072" class="method-signature">
485
+ <a href="#M000119" class="method-signature">
486
486
  <span class="method-name">yield_job_update</span><span class="method-args">(job, updates) {|job, job.start_message, job.actual_start_time| ...}</span>
487
487
  </a>
488
488
  </div>
489
489
 
490
490
  <div class="method-description">
491
491
  <p><a class="source-toggle" href="#"
492
- onclick="toggleCode('M000072-source');return false;">[Source]</a></p>
493
- <div class="method-source-code" id="M000072-source">
492
+ onclick="toggleCode('M000119-source');return false;">[Source]</a></p>
493
+ <div class="method-source-code" id="M000119-source">
494
494
  <pre>
495
495
  <span class="ruby-comment cmt"># File lib/pho/job.rb, line 132</span>
496
496
  <span class="ruby-keyword kw">def</span> <span class="ruby-constant">Jobs</span>.<span class="ruby-identifier">yield_job_update</span>(<span class="ruby-identifier">job</span>, <span class="ruby-identifier">updates</span>)