time_ext 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
data/doc/Time.html ADDED
@@ -0,0 +1,2277 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <meta name="Content-Type" content="text/html; charset=utf-8" />
6
+ <title>Class: Time</title>
7
+ <link rel="stylesheet" href="css/style.css" type="text/css" media="screen" charset="utf-8" />
8
+ <link rel="stylesheet" href="css/common.css" type="text/css" media="screen" charset="utf-8" />
9
+
10
+ <script type="text/javascript" charset="utf-8">
11
+ relpath = '';
12
+ if (relpath != '') relpath += '/';
13
+ </script>
14
+ <script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
15
+ <script type="text/javascript" charset="utf-8" src="js/app.js"></script>
16
+
17
+ </head>
18
+ <body>
19
+ <script type="text/javascript" charset="utf-8">
20
+ if (window.top.frames.main) document.body.className = 'frames';
21
+ </script>
22
+
23
+ <div id="header">
24
+ <div id="menu">
25
+
26
+ <a href="_index.html">Index (T)</a> &raquo;
27
+
28
+
29
+ <span class="title">Time</span>
30
+
31
+
32
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
33
+ </div>
34
+
35
+ <div id="search">
36
+ <a id="class_list_link" href="#">Class List</a>
37
+ <a id="method_list_link" href="#">Method List</a>
38
+ <a id ="file_list_link" href="#">File List</a>
39
+ </div>
40
+
41
+ <div class="clear"></div>
42
+ </div>
43
+
44
+ <iframe id="search_frame"></iframe>
45
+
46
+ <div id="content"><h1>Class: Time
47
+
48
+
49
+
50
+ </h1>
51
+
52
+ <dl class="box">
53
+
54
+ <dt class="r1">Inherits:</dt>
55
+ <dd class="r1">
56
+ <span class="inheritName">Object</span>
57
+
58
+ <ul class="fullTree">
59
+ <li>Object</li>
60
+
61
+ <li class="next">Time</li>
62
+
63
+ </ul>
64
+ <a href="#" class="inheritanceTree">show all</a>
65
+
66
+ </dd>
67
+
68
+
69
+
70
+
71
+
72
+
73
+
74
+
75
+
76
+ <dt class="r2 last">Defined in:</dt>
77
+ <dd class="r2 last">lib/time_ext/time.rb</dd>
78
+
79
+ </dl>
80
+ <div class="clear"></div>
81
+
82
+
83
+
84
+
85
+
86
+ <h2>
87
+ Instance Method Summary
88
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
89
+ </h2>
90
+
91
+ <ul class="summary">
92
+
93
+ <li class="public ">
94
+ <span class="summary_signature">
95
+
96
+ <a href="#beginning_of_hour-instance_method" title="#beginning_of_hour (instance method)">- (Object) <strong>beginning_of_hour</strong> </a>
97
+
98
+
99
+
100
+ (also: #at_beginning_of_hour)
101
+
102
+ </span>
103
+
104
+
105
+
106
+
107
+
108
+
109
+
110
+
111
+ <span class="summary_desc"><div class='inline'><p>
112
+ Returns a new Time representing the start of the hour (XX:00:00).
113
+ </p>
114
+ </div></span>
115
+
116
+ </li>
117
+
118
+
119
+ <li class="public ">
120
+ <span class="summary_signature">
121
+
122
+ <a href="#beginning_of_minute-instance_method" title="#beginning_of_minute (instance method)">- (Object) <strong>beginning_of_minute</strong> </a>
123
+
124
+
125
+
126
+ (also: #at_beginning_of_min, #beginning_of_min, #at_beginning_of_minute)
127
+
128
+ </span>
129
+
130
+
131
+
132
+
133
+
134
+
135
+
136
+
137
+ <span class="summary_desc"><div class='inline'><p>
138
+ Returns a new Time representing the start of the minute (XX:XX:00).
139
+ </p>
140
+ </div></span>
141
+
142
+ </li>
143
+
144
+
145
+ <li class="public ">
146
+ <span class="summary_signature">
147
+
148
+ <a href="#beginning_of_second-instance_method" title="#beginning_of_second (instance method)">- (Object) <strong>beginning_of_second</strong> </a>
149
+
150
+
151
+
152
+ (also: #at_beginning_of_sec, #beginning_of_sec, #at_beginning_of_second)
153
+
154
+ </span>
155
+
156
+
157
+
158
+
159
+
160
+
161
+
162
+
163
+ <span class="summary_desc"><div class='inline'><p>
164
+ Returns a new Time representing the start of the second, XX:XX:XX.000000
165
+ (.000000000 in ruby1.9).
166
+ </p>
167
+ </div></span>
168
+
169
+ </li>
170
+
171
+
172
+ <li class="public ">
173
+ <span class="summary_signature">
174
+
175
+ <a href="#ceil-instance_method" title="#ceil (instance method)">- (Object) <strong>ceil</strong>(unit = :sec) </a>
176
+
177
+
178
+
179
+ (also: #beginning_of_next, #at_beginning_of_next)
180
+
181
+ </span>
182
+
183
+
184
+
185
+
186
+
187
+
188
+
189
+
190
+ <span class="summary_desc"><div class='inline'><p>
191
+ Returns a new Time representing the start of the next unit specified
192
+ (second by default).
193
+ </p>
194
+ </div></span>
195
+
196
+ </li>
197
+
198
+
199
+ <li class="public ">
200
+ <span class="summary_signature">
201
+
202
+ <a href="#common_year_days_in_month-instance_method" title="#common_year_days_in_month (instance method)">- (Object) <strong>common_year_days_in_month</strong> </a>
203
+
204
+
205
+
206
+ </span>
207
+
208
+
209
+
210
+
211
+
212
+
213
+
214
+
215
+ <span class="summary_desc"><div class='inline'><p>
216
+ Helper method for backwards compatibility with ActiveSupport.
217
+ </p>
218
+ </div></span>
219
+
220
+ </li>
221
+
222
+
223
+ <li class="public ">
224
+ <span class="summary_signature">
225
+
226
+ <a href="#days_ago-instance_method" title="#days_ago (instance method)">- (Object) <strong>days_ago</strong>(days) </a>
227
+
228
+
229
+
230
+ </span>
231
+
232
+
233
+
234
+
235
+
236
+
237
+
238
+
239
+ <span class="summary_desc"><div class='inline'><p>
240
+ Returns a new Time representing the time a number of specified days ago.
241
+ </p>
242
+ </div></span>
243
+
244
+ </li>
245
+
246
+
247
+ <li class="public ">
248
+ <span class="summary_signature">
249
+
250
+ <a href="#days_into_week-instance_method" title="#days_into_week (instance method)">- (Object) <strong>days_into_week</strong> </a>
251
+
252
+
253
+
254
+ </span>
255
+
256
+
257
+
258
+
259
+
260
+
261
+
262
+
263
+ <span class="summary_desc"><div class='inline'><p>
264
+ Helper method for backwards compatibility with ActiveSupport.
265
+ </p>
266
+ </div></span>
267
+
268
+ </li>
269
+
270
+
271
+ <li class="public ">
272
+ <span class="summary_signature">
273
+
274
+ <a href="#days_since-instance_method" title="#days_since (instance method)">- (Object) <strong>days_since</strong>(days) </a>
275
+
276
+
277
+
278
+ </span>
279
+
280
+
281
+
282
+
283
+
284
+
285
+
286
+
287
+ <span class="summary_desc"><div class='inline'><p>
288
+ Returns a new Time representing the time a number of specified days in the
289
+ future.
290
+ </p>
291
+ </div></span>
292
+
293
+ </li>
294
+
295
+
296
+ <li class="public ">
297
+ <span class="summary_signature">
298
+
299
+ <a href="#end_of_hour-instance_method" title="#end_of_hour (instance method)">- (Object) <strong>end_of_hour</strong> </a>
300
+
301
+
302
+
303
+ </span>
304
+
305
+
306
+
307
+
308
+
309
+
310
+
311
+
312
+ <span class="summary_desc"><div class='inline'><p>
313
+ Returns a new Time representing the end of the hour, XX:59:59.999999
314
+ (.999999999 in ruby1.9).
315
+ </p>
316
+ </div></span>
317
+
318
+ </li>
319
+
320
+
321
+ <li class="public ">
322
+ <span class="summary_signature">
323
+
324
+ <a href="#end_of_minute-instance_method" title="#end_of_minute (instance method)">- (Object) <strong>end_of_minute</strong> </a>
325
+
326
+
327
+
328
+ (also: #end_of_min)
329
+
330
+ </span>
331
+
332
+
333
+
334
+
335
+
336
+
337
+
338
+
339
+ <span class="summary_desc"><div class='inline'><p>
340
+ Returns a new Time representing the end of the hour, XX:XX:59.999999
341
+ (.999999999 in ruby1.9).
342
+ </p>
343
+ </div></span>
344
+
345
+ </li>
346
+
347
+
348
+ <li class="public ">
349
+ <span class="summary_signature">
350
+
351
+ <a href="#end_of_second-instance_method" title="#end_of_second (instance method)">- (Object) <strong>end_of_second</strong> </a>
352
+
353
+
354
+
355
+ (also: #end_of_sec)
356
+
357
+ </span>
358
+
359
+
360
+
361
+
362
+
363
+
364
+
365
+
366
+ <span class="summary_desc"><div class='inline'><p>
367
+ Returns a new Time representing the end of the hour, XX:XX:XX.999999
368
+ (.999999999 in ruby1.9).
369
+ </p>
370
+ </div></span>
371
+
372
+ </li>
373
+
374
+
375
+ <li class="public ">
376
+ <span class="summary_signature">
377
+
378
+ <a href="#floor-instance_method" title="#floor (instance method)">- (Object) <strong>floor</strong>(unit = :sec) </a>
379
+
380
+
381
+
382
+ (also: #at_beginning_of, #beginning_of)
383
+
384
+ </span>
385
+
386
+
387
+
388
+
389
+
390
+
391
+
392
+
393
+ <span class="summary_desc"><div class='inline'><p>
394
+ Returns a new Time representing the start of the unit specified (second by
395
+ default).
396
+ </p>
397
+ </div></span>
398
+
399
+ </li>
400
+
401
+
402
+ <li class="public ">
403
+ <span class="summary_signature">
404
+
405
+ <a href="#hours_ago-instance_method" title="#hours_ago (instance method)">- (Object) <strong>hours_ago</strong>(hours) </a>
406
+
407
+
408
+
409
+ </span>
410
+
411
+
412
+
413
+
414
+
415
+
416
+
417
+
418
+ <span class="summary_desc"><div class='inline'><p>
419
+ Returns a new Time representing the time a number of specified hours ago.
420
+ </p>
421
+ </div></span>
422
+
423
+ </li>
424
+
425
+
426
+ <li class="public ">
427
+ <span class="summary_signature">
428
+
429
+ <a href="#hours_since-instance_method" title="#hours_since (instance method)">- (Object) <strong>hours_since</strong>(hours) </a>
430
+
431
+
432
+
433
+ </span>
434
+
435
+
436
+
437
+
438
+
439
+
440
+
441
+
442
+ <span class="summary_desc"><div class='inline'><p>
443
+ Returns a new Time representing the time a number of specified hours in the
444
+ future.
445
+ </p>
446
+ </div></span>
447
+
448
+ </li>
449
+
450
+
451
+ <li class="public ">
452
+ <span class="summary_signature">
453
+
454
+ <a href="#minutes_ago-instance_method" title="#minutes_ago (instance method)">- (Object) <strong>minutes_ago</strong>(minutes) </a>
455
+
456
+
457
+
458
+ (also: #mins_ago)
459
+
460
+ </span>
461
+
462
+
463
+
464
+
465
+
466
+
467
+
468
+
469
+ <span class="summary_desc"><div class='inline'><p>
470
+ Returns a new Time representing the time a number of specified minutes ago.
471
+ </p>
472
+ </div></span>
473
+
474
+ </li>
475
+
476
+
477
+ <li class="public ">
478
+ <span class="summary_signature">
479
+
480
+ <a href="#minutes_since-instance_method" title="#minutes_since (instance method)">- (Object) <strong>minutes_since</strong>(minutes) </a>
481
+
482
+
483
+
484
+ (also: #mins_since)
485
+
486
+ </span>
487
+
488
+
489
+
490
+
491
+
492
+
493
+
494
+
495
+ <span class="summary_desc"><div class='inline'><p>
496
+ Returns a new Time representing the time a number of specified minutes in
497
+ the future.
498
+ </p>
499
+ </div></span>
500
+
501
+ </li>
502
+
503
+
504
+ <li class="public ">
505
+ <span class="summary_signature">
506
+
507
+ <a href="#next_day-instance_method" title="#next_day (instance method)">- (Object) <strong>next_day</strong> </a>
508
+
509
+
510
+
511
+ </span>
512
+
513
+
514
+
515
+
516
+
517
+
518
+
519
+
520
+ <span class="summary_desc"><div class='inline'><p>
521
+ Short-hand for days_since(1).
522
+ </p>
523
+ </div></span>
524
+
525
+ </li>
526
+
527
+
528
+ <li class="public ">
529
+ <span class="summary_signature">
530
+
531
+ <a href="#next_hour-instance_method" title="#next_hour (instance method)">- (Object) <strong>next_hour</strong> </a>
532
+
533
+
534
+
535
+ </span>
536
+
537
+
538
+
539
+
540
+
541
+
542
+
543
+
544
+ <span class="summary_desc"><div class='inline'><p>
545
+ Short-hand for hours_since(1).
546
+ </p>
547
+ </div></span>
548
+
549
+ </li>
550
+
551
+
552
+ <li class="public ">
553
+ <span class="summary_signature">
554
+
555
+ <a href="#next_minute-instance_method" title="#next_minute (instance method)">- (Object) <strong>next_minute</strong> </a>
556
+
557
+
558
+
559
+ (also: #next_min)
560
+
561
+ </span>
562
+
563
+
564
+
565
+
566
+
567
+
568
+
569
+
570
+ <span class="summary_desc"><div class='inline'><p>
571
+ Short-hand for minutes_since(1).
572
+ </p>
573
+ </div></span>
574
+
575
+ </li>
576
+
577
+
578
+ <li class="public ">
579
+ <span class="summary_signature">
580
+
581
+ <a href="#next_quarter-instance_method" title="#next_quarter (instance method)">- (Object) <strong>next_quarter</strong> </a>
582
+
583
+
584
+
585
+ </span>
586
+
587
+
588
+
589
+
590
+
591
+
592
+
593
+
594
+ <span class="summary_desc"><div class='inline'><p>
595
+ Short-hand for quarters_since(1).beginning_of_quarter.
596
+ </p>
597
+ </div></span>
598
+
599
+ </li>
600
+
601
+
602
+ <li class="public ">
603
+ <span class="summary_signature">
604
+
605
+ <a href="#next_second-instance_method" title="#next_second (instance method)">- (Object) <strong>next_second</strong> </a>
606
+
607
+
608
+
609
+ (also: #next_sec)
610
+
611
+ </span>
612
+
613
+
614
+
615
+
616
+
617
+
618
+
619
+
620
+ <span class="summary_desc"><div class='inline'><p>
621
+ Short-hand for seconds_since(1).
622
+ </p>
623
+ </div></span>
624
+
625
+ </li>
626
+
627
+
628
+ <li class="public ">
629
+ <span class="summary_signature">
630
+
631
+ <a href="#prev_day-instance_method" title="#prev_day (instance method)">- (Object) <strong>prev_day</strong> </a>
632
+
633
+
634
+
635
+ </span>
636
+
637
+
638
+
639
+
640
+
641
+
642
+
643
+
644
+ <span class="summary_desc"><div class='inline'><p>
645
+ Short-hand for days_ago(1).
646
+ </p>
647
+ </div></span>
648
+
649
+ </li>
650
+
651
+
652
+ <li class="public ">
653
+ <span class="summary_signature">
654
+
655
+ <a href="#prev_hour-instance_method" title="#prev_hour (instance method)">- (Object) <strong>prev_hour</strong> </a>
656
+
657
+
658
+
659
+ </span>
660
+
661
+
662
+
663
+
664
+
665
+
666
+
667
+
668
+ <span class="summary_desc"><div class='inline'><p>
669
+ Short-hand for hours_ago(1).
670
+ </p>
671
+ </div></span>
672
+
673
+ </li>
674
+
675
+
676
+ <li class="public ">
677
+ <span class="summary_signature">
678
+
679
+ <a href="#prev_minute-instance_method" title="#prev_minute (instance method)">- (Object) <strong>prev_minute</strong> </a>
680
+
681
+
682
+
683
+ (also: #prev_min)
684
+
685
+ </span>
686
+
687
+
688
+
689
+
690
+
691
+
692
+
693
+
694
+ <span class="summary_desc"><div class='inline'><p>
695
+ Short-hand for minutes_ago(1).
696
+ </p>
697
+ </div></span>
698
+
699
+ </li>
700
+
701
+
702
+ <li class="public ">
703
+ <span class="summary_signature">
704
+
705
+ <a href="#prev_quarter-instance_method" title="#prev_quarter (instance method)">- (Object) <strong>prev_quarter</strong> </a>
706
+
707
+
708
+
709
+ </span>
710
+
711
+
712
+
713
+
714
+
715
+
716
+
717
+
718
+ <span class="summary_desc"><div class='inline'><p>
719
+ Short-hand for quarters_ago(1).beginning_of_quarter.
720
+ </p>
721
+ </div></span>
722
+
723
+ </li>
724
+
725
+
726
+ <li class="public ">
727
+ <span class="summary_signature">
728
+
729
+ <a href="#prev_second-instance_method" title="#prev_second (instance method)">- (Object) <strong>prev_second</strong> </a>
730
+
731
+
732
+
733
+ (also: #prev_sec)
734
+
735
+ </span>
736
+
737
+
738
+
739
+
740
+
741
+
742
+
743
+
744
+ <span class="summary_desc"><div class='inline'><p>
745
+ Short-hand for seconds_ago(1).
746
+ </p>
747
+ </div></span>
748
+
749
+ </li>
750
+
751
+
752
+ <li class="public ">
753
+ <span class="summary_signature">
754
+
755
+ <a href="#prev_week-instance_method" title="#prev_week (instance method)">- (Object) <strong>prev_week</strong>(day = :monday) </a>
756
+
757
+
758
+
759
+ </span>
760
+
761
+
762
+
763
+
764
+
765
+
766
+
767
+
768
+ <span class="summary_desc"><div class='inline'><p>
769
+ Returns a new Time representing the start of the given day in the previous
770
+ week (default is Monday).
771
+ </p>
772
+ </div></span>
773
+
774
+ </li>
775
+
776
+
777
+ <li class="public ">
778
+ <span class="summary_signature">
779
+
780
+ <a href="#quarters_ago-instance_method" title="#quarters_ago (instance method)">- (Object) <strong>quarters_ago</strong>(quarters) </a>
781
+
782
+
783
+
784
+ </span>
785
+
786
+
787
+
788
+
789
+
790
+
791
+
792
+
793
+ <span class="summary_desc"><div class='inline'><p>
794
+ Returns a new Time representing the time a number of specified quarters (3
795
+ months) ago.
796
+ </p>
797
+ </div></span>
798
+
799
+ </li>
800
+
801
+
802
+ <li class="public ">
803
+ <span class="summary_signature">
804
+
805
+ <a href="#quarters_since-instance_method" title="#quarters_since (instance method)">- (Object) <strong>quarters_since</strong>(quarters) </a>
806
+
807
+
808
+
809
+ </span>
810
+
811
+
812
+
813
+
814
+
815
+
816
+
817
+
818
+ <span class="summary_desc"><div class='inline'><p>
819
+ Returns a new Time representing the time a number of specified quarters (3
820
+ months) in the future.
821
+ </p>
822
+ </div></span>
823
+
824
+ </li>
825
+
826
+
827
+ <li class="public ">
828
+ <span class="summary_signature">
829
+
830
+ <a href="#round-instance_method" title="#round (instance method)">- (Object) <strong>round</strong>(unit = :sec) </a>
831
+
832
+
833
+
834
+ (also: #beginning_of_closest)
835
+
836
+ </span>
837
+
838
+
839
+
840
+
841
+
842
+
843
+
844
+
845
+ <span class="summary_desc"><div class='inline'><p>
846
+ Returns a new Time representing the start of the current or next unit
847
+ specified (second by default) depending which is closest.
848
+ </p>
849
+ </div></span>
850
+
851
+ </li>
852
+
853
+
854
+ <li class="public ">
855
+ <span class="summary_signature">
856
+
857
+ <a href="#weeks_ago-instance_method" title="#weeks_ago (instance method)">- (Object) <strong>weeks_ago</strong>(weeks) </a>
858
+
859
+
860
+
861
+ </span>
862
+
863
+
864
+
865
+
866
+
867
+
868
+
869
+
870
+ <span class="summary_desc"><div class='inline'><p>
871
+ Returns a new Time representing the time a number of specified weeks ago.
872
+ </p>
873
+ </div></span>
874
+
875
+ </li>
876
+
877
+
878
+ <li class="public ">
879
+ <span class="summary_signature">
880
+
881
+ <a href="#weeks_since-instance_method" title="#weeks_since (instance method)">- (Object) <strong>weeks_since</strong>(weeks) </a>
882
+
883
+
884
+
885
+ </span>
886
+
887
+
888
+
889
+
890
+
891
+
892
+
893
+
894
+ <span class="summary_desc"><div class='inline'><p>
895
+ Returns a new Time representing the time a number of specified weeks in the
896
+ future.
897
+ </p>
898
+ </div></span>
899
+
900
+ </li>
901
+
902
+
903
+ </ul>
904
+
905
+
906
+
907
+
908
+ <div id="instance_method_details" class="method_details_list">
909
+ <h2>Instance Method Details</h2>
910
+
911
+
912
+ <div class="method_details first">
913
+ <p class="signature first" id="beginning_of_hour-instance_method">
914
+
915
+ - (<tt>Object</tt>) <strong>beginning_of_hour</strong>
916
+
917
+
918
+
919
+ <span class="aliases">Also known as:
920
+ <span class="names"><span id='at_beginning_of_hour-instance_method'>at_beginning_of_hour</span></span>
921
+ </span>
922
+
923
+ </p><div class="docstring">
924
+ <div class="discussion">
925
+ <p>
926
+ Returns a new Time representing the start of the hour (XX:00:00).
927
+ </p>
928
+
929
+
930
+ </div>
931
+ </div>
932
+ <div class="tags">
933
+
934
+ </div><table class="source_code">
935
+ <tr>
936
+ <td>
937
+ <pre class="lines">
938
+
939
+
940
+ 181
941
+ 182
942
+ 183</pre>
943
+ </td>
944
+ <td>
945
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 181</span>
946
+
947
+ <span class='def def kw'>def</span> <span class='beginning_of_hour identifier id'>beginning_of_hour</span>
948
+ <span class='change identifier id'>change</span><span class='lparen token'>(</span><span class='symbol val'>:min</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:sec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:usec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>0</span><span class='rparen token'>)</span>
949
+ <span class='end end kw'>end</span>
950
+ </pre>
951
+ </td>
952
+ </tr>
953
+ </table>
954
+ </div>
955
+
956
+ <div class="method_details ">
957
+ <p class="signature " id="beginning_of_minute-instance_method">
958
+
959
+ - (<tt>Object</tt>) <strong>beginning_of_minute</strong>
960
+
961
+
962
+
963
+ <span class="aliases">Also known as:
964
+ <span class="names"><span id='at_beginning_of_min-instance_method'>at_beginning_of_min</span>, <span id='beginning_of_min-instance_method'>beginning_of_min</span>, <span id='at_beginning_of_minute-instance_method'>at_beginning_of_minute</span></span>
965
+ </span>
966
+
967
+ </p><div class="docstring">
968
+ <div class="discussion">
969
+ <p>
970
+ Returns a new Time representing the start of the minute (XX:XX:00).
971
+ </p>
972
+
973
+
974
+ </div>
975
+ </div>
976
+ <div class="tags">
977
+
978
+ </div><table class="source_code">
979
+ <tr>
980
+ <td>
981
+ <pre class="lines">
982
+
983
+
984
+ 167
985
+ 168
986
+ 169</pre>
987
+ </td>
988
+ <td>
989
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 167</span>
990
+
991
+ <span class='def def kw'>def</span> <span class='beginning_of_minute identifier id'>beginning_of_minute</span>
992
+ <span class='change identifier id'>change</span><span class='lparen token'>(</span><span class='symbol val'>:sec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:usec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>0</span><span class='rparen token'>)</span>
993
+ <span class='end end kw'>end</span>
994
+ </pre>
995
+ </td>
996
+ </tr>
997
+ </table>
998
+ </div>
999
+
1000
+ <div class="method_details ">
1001
+ <p class="signature " id="beginning_of_second-instance_method">
1002
+
1003
+ - (<tt>Object</tt>) <strong>beginning_of_second</strong>
1004
+
1005
+
1006
+
1007
+ <span class="aliases">Also known as:
1008
+ <span class="names"><span id='at_beginning_of_sec-instance_method'>at_beginning_of_sec</span>, <span id='beginning_of_sec-instance_method'>beginning_of_sec</span>, <span id='at_beginning_of_second-instance_method'>at_beginning_of_second</span></span>
1009
+ </span>
1010
+
1011
+ </p><div class="docstring">
1012
+ <div class="discussion">
1013
+ <p>
1014
+ Returns a new Time representing the start of the second, XX:XX:XX.000000
1015
+ (.000000000 in ruby1.9).
1016
+ </p>
1017
+
1018
+
1019
+ </div>
1020
+ </div>
1021
+ <div class="tags">
1022
+
1023
+ </div><table class="source_code">
1024
+ <tr>
1025
+ <td>
1026
+ <pre class="lines">
1027
+
1028
+
1029
+ 153
1030
+ 154
1031
+ 155</pre>
1032
+ </td>
1033
+ <td>
1034
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 153</span>
1035
+
1036
+ <span class='def def kw'>def</span> <span class='beginning_of_second identifier id'>beginning_of_second</span>
1037
+ <span class='change identifier id'>change</span><span class='lparen token'>(</span><span class='symbol val'>:usec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>0</span><span class='rparen token'>)</span>
1038
+ <span class='end end kw'>end</span>
1039
+ </pre>
1040
+ </td>
1041
+ </tr>
1042
+ </table>
1043
+ </div>
1044
+
1045
+ <div class="method_details ">
1046
+ <p class="signature " id="ceil-instance_method">
1047
+
1048
+ - (<tt>Object</tt>) <strong>ceil</strong>(unit = :sec)
1049
+
1050
+
1051
+
1052
+ <span class="aliases">Also known as:
1053
+ <span class="names"><span id='beginning_of_next-instance_method'>beginning_of_next</span>, <span id='at_beginning_of_next-instance_method'>at_beginning_of_next</span></span>
1054
+ </span>
1055
+
1056
+ </p><div class="docstring">
1057
+ <div class="discussion">
1058
+ <p>
1059
+ Returns a new Time representing the start of the next unit specified
1060
+ (second by default).
1061
+ </p>
1062
+
1063
+
1064
+ </div>
1065
+ </div>
1066
+ <div class="tags">
1067
+
1068
+ </div><table class="source_code">
1069
+ <tr>
1070
+ <td>
1071
+ <pre class="lines">
1072
+
1073
+
1074
+ 21
1075
+ 22
1076
+ 23</pre>
1077
+ </td>
1078
+ <td>
1079
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 21</span>
1080
+
1081
+ <span class='def def kw'>def</span> <span class='ceil identifier id'>ceil</span><span class='lparen token'>(</span><span class='unit identifier id'>unit</span> <span class='assign token'>=</span> <span class='symbol val'>:sec</span><span class='rparen token'>)</span>
1082
+ <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>&quot;next_#{unit}&quot;</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>&quot;beginning_of_#{unit}&quot;</span><span class='rparen token'>)</span>
1083
+ <span class='end end kw'>end</span>
1084
+ </pre>
1085
+ </td>
1086
+ </tr>
1087
+ </table>
1088
+ </div>
1089
+
1090
+ <div class="method_details ">
1091
+ <p class="signature " id="common_year_days_in_month-instance_method">
1092
+
1093
+ - (<tt>Object</tt>) <strong>common_year_days_in_month</strong>
1094
+
1095
+
1096
+
1097
+ </p><div class="docstring">
1098
+ <div class="discussion">
1099
+ <p>
1100
+ Helper method for backwards compatibility with ActiveSupport.
1101
+ </p>
1102
+
1103
+
1104
+ </div>
1105
+ </div>
1106
+ <div class="tags">
1107
+
1108
+ </div><table class="source_code">
1109
+ <tr>
1110
+ <td>
1111
+ <pre class="lines">
1112
+
1113
+
1114
+ 9
1115
+ 10
1116
+ 11</pre>
1117
+ </td>
1118
+ <td>
1119
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 9</span>
1120
+
1121
+ <span class='def def kw'>def</span> <span class='common_year_days_in_month identifier id'>common_year_days_in_month</span>
1122
+ <span class='defined? defined kw'>defined?</span><span class='lparen token'>(</span><span class='COMMON_YEAR_DAYS_IN_MONTH constant id'>COMMON_YEAR_DAYS_IN_MONTH</span><span class='rparen token'>)</span> <span class='question op'>?</span> <span class='COMMON_YEAR_DAYS_IN_MONTH constant id'>COMMON_YEAR_DAYS_IN_MONTH</span> <span class='colon op'>:</span> <span class='lbrack token'>[</span><span class='nil nil kw'>nil</span><span class='comma token'>,</span> <span class='integer val'>31</span><span class='comma token'>,</span> <span class='integer val'>28</span><span class='comma token'>,</span> <span class='integer val'>31</span><span class='comma token'>,</span> <span class='integer val'>30</span><span class='comma token'>,</span> <span class='integer val'>31</span><span class='comma token'>,</span> <span class='integer val'>30</span><span class='comma token'>,</span> <span class='integer val'>31</span><span class='comma token'>,</span> <span class='integer val'>31</span><span class='comma token'>,</span> <span class='integer val'>30</span><span class='comma token'>,</span> <span class='integer val'>31</span><span class='comma token'>,</span> <span class='integer val'>30</span><span class='comma token'>,</span> <span class='integer val'>31</span><span class='rbrack token'>]</span>
1123
+ <span class='end end kw'>end</span>
1124
+ </pre>
1125
+ </td>
1126
+ </tr>
1127
+ </table>
1128
+ </div>
1129
+
1130
+ <div class="method_details ">
1131
+ <p class="signature " id="days_ago-instance_method">
1132
+
1133
+ - (<tt>Object</tt>) <strong>days_ago</strong>(days)
1134
+
1135
+
1136
+
1137
+ </p><div class="docstring">
1138
+ <div class="discussion">
1139
+ <p>
1140
+ Returns a new Time representing the time a number of specified days ago.
1141
+ </p>
1142
+
1143
+
1144
+ </div>
1145
+ </div>
1146
+ <div class="tags">
1147
+
1148
+ </div><table class="source_code">
1149
+ <tr>
1150
+ <td>
1151
+ <pre class="lines">
1152
+
1153
+
1154
+ 123
1155
+ 124
1156
+ 125</pre>
1157
+ </td>
1158
+ <td>
1159
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 123</span>
1160
+
1161
+ <span class='def def kw'>def</span> <span class='days_ago identifier id'>days_ago</span><span class='lparen token'>(</span><span class='days identifier id'>days</span><span class='rparen token'>)</span>
1162
+ <span class='ago identifier id'>ago</span><span class='lparen token'>(</span><span class='days identifier id'>days</span><span class='dot token'>.</span><span class='days identifier id'>days</span><span class='rparen token'>)</span>
1163
+ <span class='end end kw'>end</span>
1164
+ </pre>
1165
+ </td>
1166
+ </tr>
1167
+ </table>
1168
+ </div>
1169
+
1170
+ <div class="method_details ">
1171
+ <p class="signature " id="days_into_week-instance_method">
1172
+
1173
+ - (<tt>Object</tt>) <strong>days_into_week</strong>
1174
+
1175
+
1176
+
1177
+ </p><div class="docstring">
1178
+ <div class="discussion">
1179
+ <p>
1180
+ Helper method for backwards compatibility with ActiveSupport.
1181
+ </p>
1182
+
1183
+
1184
+ </div>
1185
+ </div>
1186
+ <div class="tags">
1187
+
1188
+ </div><table class="source_code">
1189
+ <tr>
1190
+ <td>
1191
+ <pre class="lines">
1192
+
1193
+
1194
+ 4
1195
+ 5
1196
+ 6</pre>
1197
+ </td>
1198
+ <td>
1199
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 4</span>
1200
+
1201
+ <span class='def def kw'>def</span> <span class='days_into_week identifier id'>days_into_week</span>
1202
+ <span class='defined? defined kw'>defined?</span><span class='lparen token'>(</span><span class='DAYS_INTO_WEEK constant id'>DAYS_INTO_WEEK</span><span class='rparen token'>)</span> <span class='question op'>?</span> <span class='DAYS_INTO_WEEK constant id'>DAYS_INTO_WEEK</span> <span class='colon op'>:</span> <span class='lbrace token'>{</span> <span class='symbol val'>:monday</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>0</span><span class='comma token'>,</span> <span class='symbol val'>:tuesday</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>1</span><span class='comma token'>,</span> <span class='symbol val'>:wednesday</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>2</span><span class='comma token'>,</span> <span class='symbol val'>:thursday</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>3</span><span class='comma token'>,</span> <span class='symbol val'>:friday</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>4</span><span class='comma token'>,</span> <span class='symbol val'>:saturday</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>5</span><span class='comma token'>,</span> <span class='symbol val'>:sunday</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>6</span> <span class='rbrace token'>}</span>
1203
+ <span class='end end kw'>end</span>
1204
+ </pre>
1205
+ </td>
1206
+ </tr>
1207
+ </table>
1208
+ </div>
1209
+
1210
+ <div class="method_details ">
1211
+ <p class="signature " id="days_since-instance_method">
1212
+
1213
+ - (<tt>Object</tt>) <strong>days_since</strong>(days)
1214
+
1215
+
1216
+
1217
+ </p><div class="docstring">
1218
+ <div class="discussion">
1219
+ <p>
1220
+ Returns a new Time representing the time a number of specified days in the
1221
+ future.
1222
+ </p>
1223
+
1224
+
1225
+ </div>
1226
+ </div>
1227
+ <div class="tags">
1228
+
1229
+ </div><table class="source_code">
1230
+ <tr>
1231
+ <td>
1232
+ <pre class="lines">
1233
+
1234
+
1235
+ 128
1236
+ 129
1237
+ 130</pre>
1238
+ </td>
1239
+ <td>
1240
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 128</span>
1241
+
1242
+ <span class='def def kw'>def</span> <span class='days_since identifier id'>days_since</span><span class='lparen token'>(</span><span class='days identifier id'>days</span><span class='rparen token'>)</span>
1243
+ <span class='since identifier id'>since</span><span class='lparen token'>(</span><span class='days identifier id'>days</span><span class='dot token'>.</span><span class='days identifier id'>days</span><span class='rparen token'>)</span>
1244
+ <span class='end end kw'>end</span>
1245
+ </pre>
1246
+ </td>
1247
+ </tr>
1248
+ </table>
1249
+ </div>
1250
+
1251
+ <div class="method_details ">
1252
+ <p class="signature " id="end_of_hour-instance_method">
1253
+
1254
+ - (<tt>Object</tt>) <strong>end_of_hour</strong>
1255
+
1256
+
1257
+
1258
+ </p><div class="docstring">
1259
+ <div class="discussion">
1260
+ <p>
1261
+ Returns a new Time representing the end of the hour, XX:59:59.999999
1262
+ (.999999999 in ruby1.9).
1263
+ </p>
1264
+
1265
+
1266
+ </div>
1267
+ </div>
1268
+ <div class="tags">
1269
+
1270
+ </div><table class="source_code">
1271
+ <tr>
1272
+ <td>
1273
+ <pre class="lines">
1274
+
1275
+
1276
+ 187
1277
+ 188
1278
+ 189</pre>
1279
+ </td>
1280
+ <td>
1281
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 187</span>
1282
+
1283
+ <span class='def def kw'>def</span> <span class='end_of_hour identifier id'>end_of_hour</span>
1284
+ <span class='change identifier id'>change</span><span class='lparen token'>(</span><span class='symbol val'>:min</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>59</span><span class='comma token'>,</span> <span class='symbol val'>:sec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>59</span><span class='comma token'>,</span> <span class='symbol val'>:usec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='float val'>999999.999</span><span class='rparen token'>)</span>
1285
+ <span class='end end kw'>end</span>
1286
+ </pre>
1287
+ </td>
1288
+ </tr>
1289
+ </table>
1290
+ </div>
1291
+
1292
+ <div class="method_details ">
1293
+ <p class="signature " id="end_of_minute-instance_method">
1294
+
1295
+ - (<tt>Object</tt>) <strong>end_of_minute</strong>
1296
+
1297
+
1298
+
1299
+ <span class="aliases">Also known as:
1300
+ <span class="names"><span id='end_of_min-instance_method'>end_of_min</span></span>
1301
+ </span>
1302
+
1303
+ </p><div class="docstring">
1304
+ <div class="discussion">
1305
+ <p>
1306
+ Returns a new Time representing the end of the hour, XX:XX:59.999999
1307
+ (.999999999 in ruby1.9).
1308
+ </p>
1309
+
1310
+
1311
+ </div>
1312
+ </div>
1313
+ <div class="tags">
1314
+
1315
+ </div><table class="source_code">
1316
+ <tr>
1317
+ <td>
1318
+ <pre class="lines">
1319
+
1320
+
1321
+ 175
1322
+ 176
1323
+ 177</pre>
1324
+ </td>
1325
+ <td>
1326
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 175</span>
1327
+
1328
+ <span class='def def kw'>def</span> <span class='end_of_minute identifier id'>end_of_minute</span>
1329
+ <span class='change identifier id'>change</span><span class='lparen token'>(</span><span class='symbol val'>:sec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>59</span><span class='comma token'>,</span> <span class='symbol val'>:usec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='float val'>999999.999</span><span class='rparen token'>)</span>
1330
+ <span class='end end kw'>end</span>
1331
+ </pre>
1332
+ </td>
1333
+ </tr>
1334
+ </table>
1335
+ </div>
1336
+
1337
+ <div class="method_details ">
1338
+ <p class="signature " id="end_of_second-instance_method">
1339
+
1340
+ - (<tt>Object</tt>) <strong>end_of_second</strong>
1341
+
1342
+
1343
+
1344
+ <span class="aliases">Also known as:
1345
+ <span class="names"><span id='end_of_sec-instance_method'>end_of_sec</span></span>
1346
+ </span>
1347
+
1348
+ </p><div class="docstring">
1349
+ <div class="discussion">
1350
+ <p>
1351
+ Returns a new Time representing the end of the hour, XX:XX:XX.999999
1352
+ (.999999999 in ruby1.9).
1353
+ </p>
1354
+
1355
+
1356
+ </div>
1357
+ </div>
1358
+ <div class="tags">
1359
+
1360
+ </div><table class="source_code">
1361
+ <tr>
1362
+ <td>
1363
+ <pre class="lines">
1364
+
1365
+
1366
+ 161
1367
+ 162
1368
+ 163</pre>
1369
+ </td>
1370
+ <td>
1371
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 161</span>
1372
+
1373
+ <span class='def def kw'>def</span> <span class='end_of_second identifier id'>end_of_second</span>
1374
+ <span class='change identifier id'>change</span><span class='lparen token'>(</span><span class='symbol val'>:usec</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='float val'>999999.999</span><span class='rparen token'>)</span>
1375
+ <span class='end end kw'>end</span>
1376
+ </pre>
1377
+ </td>
1378
+ </tr>
1379
+ </table>
1380
+ </div>
1381
+
1382
+ <div class="method_details ">
1383
+ <p class="signature " id="floor-instance_method">
1384
+
1385
+ - (<tt>Object</tt>) <strong>floor</strong>(unit = :sec)
1386
+
1387
+
1388
+
1389
+ <span class="aliases">Also known as:
1390
+ <span class="names"><span id='at_beginning_of-instance_method'>at_beginning_of</span>, <span id='beginning_of-instance_method'>beginning_of</span></span>
1391
+ </span>
1392
+
1393
+ </p><div class="docstring">
1394
+ <div class="discussion">
1395
+ <p>
1396
+ Returns a new Time representing the start of the unit specified (second by
1397
+ default).
1398
+ </p>
1399
+
1400
+
1401
+ </div>
1402
+ </div>
1403
+ <div class="tags">
1404
+
1405
+ </div><table class="source_code">
1406
+ <tr>
1407
+ <td>
1408
+ <pre class="lines">
1409
+
1410
+
1411
+ 14
1412
+ 15
1413
+ 16</pre>
1414
+ </td>
1415
+ <td>
1416
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 14</span>
1417
+
1418
+ <span class='def def kw'>def</span> <span class='floor identifier id'>floor</span><span class='lparen token'>(</span><span class='unit identifier id'>unit</span> <span class='assign token'>=</span> <span class='symbol val'>:sec</span><span class='rparen token'>)</span>
1419
+ <span class='self self kw'>self</span><span class='dot token'>.</span><span class='send identifier id'>send</span><span class='lparen token'>(</span><span class='dstring node'>&quot;beginning_of_#{unit}&quot;</span><span class='rparen token'>)</span>
1420
+ <span class='end end kw'>end</span>
1421
+ </pre>
1422
+ </td>
1423
+ </tr>
1424
+ </table>
1425
+ </div>
1426
+
1427
+ <div class="method_details ">
1428
+ <p class="signature " id="hours_ago-instance_method">
1429
+
1430
+ - (<tt>Object</tt>) <strong>hours_ago</strong>(hours)
1431
+
1432
+
1433
+
1434
+ </p><div class="docstring">
1435
+ <div class="discussion">
1436
+ <p>
1437
+ Returns a new Time representing the time a number of specified hours ago.
1438
+ </p>
1439
+
1440
+
1441
+ </div>
1442
+ </div>
1443
+ <div class="tags">
1444
+
1445
+ </div><table class="source_code">
1446
+ <tr>
1447
+ <td>
1448
+ <pre class="lines">
1449
+
1450
+
1451
+ 113
1452
+ 114
1453
+ 115</pre>
1454
+ </td>
1455
+ <td>
1456
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 113</span>
1457
+
1458
+ <span class='def def kw'>def</span> <span class='hours_ago identifier id'>hours_ago</span><span class='lparen token'>(</span><span class='hours identifier id'>hours</span><span class='rparen token'>)</span>
1459
+ <span class='ago identifier id'>ago</span><span class='lparen token'>(</span><span class='hours identifier id'>hours</span><span class='dot token'>.</span><span class='hours identifier id'>hours</span><span class='rparen token'>)</span>
1460
+ <span class='end end kw'>end</span>
1461
+ </pre>
1462
+ </td>
1463
+ </tr>
1464
+ </table>
1465
+ </div>
1466
+
1467
+ <div class="method_details ">
1468
+ <p class="signature " id="hours_since-instance_method">
1469
+
1470
+ - (<tt>Object</tt>) <strong>hours_since</strong>(hours)
1471
+
1472
+
1473
+
1474
+ </p><div class="docstring">
1475
+ <div class="discussion">
1476
+ <p>
1477
+ Returns a new Time representing the time a number of specified hours in the
1478
+ future.
1479
+ </p>
1480
+
1481
+
1482
+ </div>
1483
+ </div>
1484
+ <div class="tags">
1485
+
1486
+ </div><table class="source_code">
1487
+ <tr>
1488
+ <td>
1489
+ <pre class="lines">
1490
+
1491
+
1492
+ 118
1493
+ 119
1494
+ 120</pre>
1495
+ </td>
1496
+ <td>
1497
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 118</span>
1498
+
1499
+ <span class='def def kw'>def</span> <span class='hours_since identifier id'>hours_since</span><span class='lparen token'>(</span><span class='hours identifier id'>hours</span><span class='rparen token'>)</span>
1500
+ <span class='since identifier id'>since</span><span class='lparen token'>(</span><span class='hours identifier id'>hours</span><span class='dot token'>.</span><span class='hours identifier id'>hours</span><span class='rparen token'>)</span>
1501
+ <span class='end end kw'>end</span>
1502
+ </pre>
1503
+ </td>
1504
+ </tr>
1505
+ </table>
1506
+ </div>
1507
+
1508
+ <div class="method_details ">
1509
+ <p class="signature " id="minutes_ago-instance_method">
1510
+
1511
+ - (<tt>Object</tt>) <strong>minutes_ago</strong>(minutes)
1512
+
1513
+
1514
+
1515
+ <span class="aliases">Also known as:
1516
+ <span class="names"><span id='mins_ago-instance_method'>mins_ago</span></span>
1517
+ </span>
1518
+
1519
+ </p><div class="docstring">
1520
+ <div class="discussion">
1521
+ <p>
1522
+ Returns a new Time representing the time a number of specified minutes ago.
1523
+ </p>
1524
+
1525
+
1526
+ </div>
1527
+ </div>
1528
+ <div class="tags">
1529
+
1530
+ </div><table class="source_code">
1531
+ <tr>
1532
+ <td>
1533
+ <pre class="lines">
1534
+
1535
+
1536
+ 101
1537
+ 102
1538
+ 103</pre>
1539
+ </td>
1540
+ <td>
1541
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 101</span>
1542
+
1543
+ <span class='def def kw'>def</span> <span class='minutes_ago identifier id'>minutes_ago</span><span class='lparen token'>(</span><span class='minutes identifier id'>minutes</span><span class='rparen token'>)</span>
1544
+ <span class='ago identifier id'>ago</span><span class='lparen token'>(</span><span class='minutes identifier id'>minutes</span><span class='dot token'>.</span><span class='minutes identifier id'>minutes</span><span class='rparen token'>)</span>
1545
+ <span class='end end kw'>end</span>
1546
+ </pre>
1547
+ </td>
1548
+ </tr>
1549
+ </table>
1550
+ </div>
1551
+
1552
+ <div class="method_details ">
1553
+ <p class="signature " id="minutes_since-instance_method">
1554
+
1555
+ - (<tt>Object</tt>) <strong>minutes_since</strong>(minutes)
1556
+
1557
+
1558
+
1559
+ <span class="aliases">Also known as:
1560
+ <span class="names"><span id='mins_since-instance_method'>mins_since</span></span>
1561
+ </span>
1562
+
1563
+ </p><div class="docstring">
1564
+ <div class="discussion">
1565
+ <p>
1566
+ Returns a new Time representing the time a number of specified minutes in
1567
+ the future.
1568
+ </p>
1569
+
1570
+
1571
+ </div>
1572
+ </div>
1573
+ <div class="tags">
1574
+
1575
+ </div><table class="source_code">
1576
+ <tr>
1577
+ <td>
1578
+ <pre class="lines">
1579
+
1580
+
1581
+ 107
1582
+ 108
1583
+ 109</pre>
1584
+ </td>
1585
+ <td>
1586
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 107</span>
1587
+
1588
+ <span class='def def kw'>def</span> <span class='minutes_since identifier id'>minutes_since</span><span class='lparen token'>(</span><span class='minutes identifier id'>minutes</span><span class='rparen token'>)</span>
1589
+ <span class='since identifier id'>since</span><span class='lparen token'>(</span><span class='minutes identifier id'>minutes</span><span class='dot token'>.</span><span class='minutes identifier id'>minutes</span><span class='rparen token'>)</span>
1590
+ <span class='end end kw'>end</span>
1591
+ </pre>
1592
+ </td>
1593
+ </tr>
1594
+ </table>
1595
+ </div>
1596
+
1597
+ <div class="method_details ">
1598
+ <p class="signature " id="next_day-instance_method">
1599
+
1600
+ - (<tt>Object</tt>) <strong>next_day</strong>
1601
+
1602
+
1603
+
1604
+ </p><div class="docstring">
1605
+ <div class="discussion">
1606
+ <p>
1607
+ Short-hand for days_since(1).
1608
+ </p>
1609
+
1610
+
1611
+ </div>
1612
+ </div>
1613
+ <div class="tags">
1614
+
1615
+ </div><table class="source_code">
1616
+ <tr>
1617
+ <td>
1618
+ <pre class="lines">
1619
+
1620
+
1621
+ 75
1622
+ 76
1623
+ 77</pre>
1624
+ </td>
1625
+ <td>
1626
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 75</span>
1627
+
1628
+ <span class='def def kw'>def</span> <span class='next_day identifier id'>next_day</span>
1629
+ <span class='days_since identifier id'>days_since</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span>
1630
+ <span class='end end kw'>end</span>
1631
+ </pre>
1632
+ </td>
1633
+ </tr>
1634
+ </table>
1635
+ </div>
1636
+
1637
+ <div class="method_details ">
1638
+ <p class="signature " id="next_hour-instance_method">
1639
+
1640
+ - (<tt>Object</tt>) <strong>next_hour</strong>
1641
+
1642
+
1643
+
1644
+ </p><div class="docstring">
1645
+ <div class="discussion">
1646
+ <p>
1647
+ Short-hand for hours_since(1).
1648
+ </p>
1649
+
1650
+
1651
+ </div>
1652
+ </div>
1653
+ <div class="tags">
1654
+
1655
+ </div><table class="source_code">
1656
+ <tr>
1657
+ <td>
1658
+ <pre class="lines">
1659
+
1660
+
1661
+ 65
1662
+ 66
1663
+ 67</pre>
1664
+ </td>
1665
+ <td>
1666
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 65</span>
1667
+
1668
+ <span class='def def kw'>def</span> <span class='next_hour identifier id'>next_hour</span>
1669
+ <span class='hours_since identifier id'>hours_since</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span>
1670
+ <span class='end end kw'>end</span>
1671
+ </pre>
1672
+ </td>
1673
+ </tr>
1674
+ </table>
1675
+ </div>
1676
+
1677
+ <div class="method_details ">
1678
+ <p class="signature " id="next_minute-instance_method">
1679
+
1680
+ - (<tt>Object</tt>) <strong>next_minute</strong>
1681
+
1682
+
1683
+
1684
+ <span class="aliases">Also known as:
1685
+ <span class="names"><span id='next_min-instance_method'>next_min</span></span>
1686
+ </span>
1687
+
1688
+ </p><div class="docstring">
1689
+ <div class="discussion">
1690
+ <p>
1691
+ Short-hand for minutes_since(1).
1692
+ </p>
1693
+
1694
+
1695
+ </div>
1696
+ </div>
1697
+ <div class="tags">
1698
+
1699
+ </div><table class="source_code">
1700
+ <tr>
1701
+ <td>
1702
+ <pre class="lines">
1703
+
1704
+
1705
+ 54
1706
+ 55
1707
+ 56</pre>
1708
+ </td>
1709
+ <td>
1710
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 54</span>
1711
+
1712
+ <span class='def def kw'>def</span> <span class='next_minute identifier id'>next_minute</span>
1713
+ <span class='minutes_since identifier id'>minutes_since</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span>
1714
+ <span class='end end kw'>end</span>
1715
+ </pre>
1716
+ </td>
1717
+ </tr>
1718
+ </table>
1719
+ </div>
1720
+
1721
+ <div class="method_details ">
1722
+ <p class="signature " id="next_quarter-instance_method">
1723
+
1724
+ - (<tt>Object</tt>) <strong>next_quarter</strong>
1725
+
1726
+
1727
+
1728
+ </p><div class="docstring">
1729
+ <div class="discussion">
1730
+ <p>
1731
+ Short-hand for quarters_since(1).beginning_of_quarter.
1732
+ </p>
1733
+
1734
+
1735
+ </div>
1736
+ </div>
1737
+ <div class="tags">
1738
+
1739
+ </div><table class="source_code">
1740
+ <tr>
1741
+ <td>
1742
+ <pre class="lines">
1743
+
1744
+
1745
+ 85
1746
+ 86
1747
+ 87</pre>
1748
+ </td>
1749
+ <td>
1750
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 85</span>
1751
+
1752
+ <span class='def def kw'>def</span> <span class='next_quarter identifier id'>next_quarter</span>
1753
+ <span class='quarters_since identifier id'>quarters_since</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='beginning_of_quarter identifier id'>beginning_of_quarter</span>
1754
+ <span class='end end kw'>end</span>
1755
+ </pre>
1756
+ </td>
1757
+ </tr>
1758
+ </table>
1759
+ </div>
1760
+
1761
+ <div class="method_details ">
1762
+ <p class="signature " id="next_second-instance_method">
1763
+
1764
+ - (<tt>Object</tt>) <strong>next_second</strong>
1765
+
1766
+
1767
+
1768
+ <span class="aliases">Also known as:
1769
+ <span class="names"><span id='next_sec-instance_method'>next_sec</span></span>
1770
+ </span>
1771
+
1772
+ </p><div class="docstring">
1773
+ <div class="discussion">
1774
+ <p>
1775
+ Short-hand for seconds_since(1).
1776
+ </p>
1777
+
1778
+
1779
+ </div>
1780
+ </div>
1781
+ <div class="tags">
1782
+
1783
+ </div><table class="source_code">
1784
+ <tr>
1785
+ <td>
1786
+ <pre class="lines">
1787
+
1788
+
1789
+ 42
1790
+ 43
1791
+ 44</pre>
1792
+ </td>
1793
+ <td>
1794
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 42</span>
1795
+
1796
+ <span class='def def kw'>def</span> <span class='next_second identifier id'>next_second</span>
1797
+ <span class='since identifier id'>since</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span>
1798
+ <span class='end end kw'>end</span>
1799
+ </pre>
1800
+ </td>
1801
+ </tr>
1802
+ </table>
1803
+ </div>
1804
+
1805
+ <div class="method_details ">
1806
+ <p class="signature " id="prev_day-instance_method">
1807
+
1808
+ - (<tt>Object</tt>) <strong>prev_day</strong>
1809
+
1810
+
1811
+
1812
+ </p><div class="docstring">
1813
+ <div class="discussion">
1814
+ <p>
1815
+ Short-hand for days_ago(1).
1816
+ </p>
1817
+
1818
+
1819
+ </div>
1820
+ </div>
1821
+ <div class="tags">
1822
+
1823
+ </div><table class="source_code">
1824
+ <tr>
1825
+ <td>
1826
+ <pre class="lines">
1827
+
1828
+
1829
+ 70
1830
+ 71
1831
+ 72</pre>
1832
+ </td>
1833
+ <td>
1834
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 70</span>
1835
+
1836
+ <span class='def def kw'>def</span> <span class='prev_day identifier id'>prev_day</span>
1837
+ <span class='days_ago identifier id'>days_ago</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span>
1838
+ <span class='end end kw'>end</span>
1839
+ </pre>
1840
+ </td>
1841
+ </tr>
1842
+ </table>
1843
+ </div>
1844
+
1845
+ <div class="method_details ">
1846
+ <p class="signature " id="prev_hour-instance_method">
1847
+
1848
+ - (<tt>Object</tt>) <strong>prev_hour</strong>
1849
+
1850
+
1851
+
1852
+ </p><div class="docstring">
1853
+ <div class="discussion">
1854
+ <p>
1855
+ Short-hand for hours_ago(1).
1856
+ </p>
1857
+
1858
+
1859
+ </div>
1860
+ </div>
1861
+ <div class="tags">
1862
+
1863
+ </div><table class="source_code">
1864
+ <tr>
1865
+ <td>
1866
+ <pre class="lines">
1867
+
1868
+
1869
+ 60
1870
+ 61
1871
+ 62</pre>
1872
+ </td>
1873
+ <td>
1874
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 60</span>
1875
+
1876
+ <span class='def def kw'>def</span> <span class='prev_hour identifier id'>prev_hour</span>
1877
+ <span class='hours_ago identifier id'>hours_ago</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span>
1878
+ <span class='end end kw'>end</span>
1879
+ </pre>
1880
+ </td>
1881
+ </tr>
1882
+ </table>
1883
+ </div>
1884
+
1885
+ <div class="method_details ">
1886
+ <p class="signature " id="prev_minute-instance_method">
1887
+
1888
+ - (<tt>Object</tt>) <strong>prev_minute</strong>
1889
+
1890
+
1891
+
1892
+ <span class="aliases">Also known as:
1893
+ <span class="names"><span id='prev_min-instance_method'>prev_min</span></span>
1894
+ </span>
1895
+
1896
+ </p><div class="docstring">
1897
+ <div class="discussion">
1898
+ <p>
1899
+ Short-hand for minutes_ago(1).
1900
+ </p>
1901
+
1902
+
1903
+ </div>
1904
+ </div>
1905
+ <div class="tags">
1906
+
1907
+ </div><table class="source_code">
1908
+ <tr>
1909
+ <td>
1910
+ <pre class="lines">
1911
+
1912
+
1913
+ 48
1914
+ 49
1915
+ 50</pre>
1916
+ </td>
1917
+ <td>
1918
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 48</span>
1919
+
1920
+ <span class='def def kw'>def</span> <span class='prev_minute identifier id'>prev_minute</span>
1921
+ <span class='minutes_ago identifier id'>minutes_ago</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span>
1922
+ <span class='end end kw'>end</span>
1923
+ </pre>
1924
+ </td>
1925
+ </tr>
1926
+ </table>
1927
+ </div>
1928
+
1929
+ <div class="method_details ">
1930
+ <p class="signature " id="prev_quarter-instance_method">
1931
+
1932
+ - (<tt>Object</tt>) <strong>prev_quarter</strong>
1933
+
1934
+
1935
+
1936
+ </p><div class="docstring">
1937
+ <div class="discussion">
1938
+ <p>
1939
+ Short-hand for quarters_ago(1).beginning_of_quarter.
1940
+ </p>
1941
+
1942
+
1943
+ </div>
1944
+ </div>
1945
+ <div class="tags">
1946
+
1947
+ </div><table class="source_code">
1948
+ <tr>
1949
+ <td>
1950
+ <pre class="lines">
1951
+
1952
+
1953
+ 90
1954
+ 91
1955
+ 92</pre>
1956
+ </td>
1957
+ <td>
1958
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 90</span>
1959
+
1960
+ <span class='def def kw'>def</span> <span class='prev_quarter identifier id'>prev_quarter</span>
1961
+ <span class='quarters_ago identifier id'>quarters_ago</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='beginning_of_quarter identifier id'>beginning_of_quarter</span>
1962
+ <span class='end end kw'>end</span>
1963
+ </pre>
1964
+ </td>
1965
+ </tr>
1966
+ </table>
1967
+ </div>
1968
+
1969
+ <div class="method_details ">
1970
+ <p class="signature " id="prev_second-instance_method">
1971
+
1972
+ - (<tt>Object</tt>) <strong>prev_second</strong>
1973
+
1974
+
1975
+
1976
+ <span class="aliases">Also known as:
1977
+ <span class="names"><span id='prev_sec-instance_method'>prev_sec</span></span>
1978
+ </span>
1979
+
1980
+ </p><div class="docstring">
1981
+ <div class="discussion">
1982
+ <p>
1983
+ Short-hand for seconds_ago(1).
1984
+ </p>
1985
+
1986
+
1987
+ </div>
1988
+ </div>
1989
+ <div class="tags">
1990
+
1991
+ </div><table class="source_code">
1992
+ <tr>
1993
+ <td>
1994
+ <pre class="lines">
1995
+
1996
+
1997
+ 36
1998
+ 37
1999
+ 38</pre>
2000
+ </td>
2001
+ <td>
2002
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 36</span>
2003
+
2004
+ <span class='def def kw'>def</span> <span class='prev_second identifier id'>prev_second</span>
2005
+ <span class='ago identifier id'>ago</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span>
2006
+ <span class='end end kw'>end</span>
2007
+ </pre>
2008
+ </td>
2009
+ </tr>
2010
+ </table>
2011
+ </div>
2012
+
2013
+ <div class="method_details ">
2014
+ <p class="signature " id="prev_week-instance_method">
2015
+
2016
+ - (<tt>Object</tt>) <strong>prev_week</strong>(day = :monday)
2017
+
2018
+
2019
+
2020
+ </p><div class="docstring">
2021
+ <div class="discussion">
2022
+ <p>
2023
+ Returns a new Time representing the start of the given day in the previous
2024
+ week (default is Monday).
2025
+ </p>
2026
+
2027
+
2028
+ </div>
2029
+ </div>
2030
+ <div class="tags">
2031
+
2032
+ </div><table class="source_code">
2033
+ <tr>
2034
+ <td>
2035
+ <pre class="lines">
2036
+
2037
+
2038
+ 80
2039
+ 81
2040
+ 82</pre>
2041
+ </td>
2042
+ <td>
2043
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 80</span>
2044
+
2045
+ <span class='def def kw'>def</span> <span class='prev_week identifier id'>prev_week</span><span class='lparen token'>(</span><span class='day identifier id'>day</span> <span class='assign token'>=</span> <span class='symbol val'>:monday</span><span class='rparen token'>)</span>
2046
+ <span class='weeks_ago identifier id'>weeks_ago</span><span class='lparen token'>(</span><span class='integer val'>1</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='beginning_of_week identifier id'>beginning_of_week</span><span class='dot token'>.</span><span class='since identifier id'>since</span><span class='lparen token'>(</span><span class='days_into_week identifier id'>days_into_week</span><span class='lbrack token'>[</span><span class='day identifier id'>day</span><span class='rbrack token'>]</span><span class='dot token'>.</span><span class='day identifier id'>day</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='change identifier id'>change</span><span class='lparen token'>(</span><span class='symbol val'>:hour</span> <span class='assign token'>=</span><span class='gt op'>&gt;</span> <span class='integer val'>0</span><span class='rparen token'>)</span>
2047
+ <span class='end end kw'>end</span>
2048
+ </pre>
2049
+ </td>
2050
+ </tr>
2051
+ </table>
2052
+ </div>
2053
+
2054
+ <div class="method_details ">
2055
+ <p class="signature " id="quarters_ago-instance_method">
2056
+
2057
+ - (<tt>Object</tt>) <strong>quarters_ago</strong>(quarters)
2058
+
2059
+
2060
+
2061
+ </p><div class="docstring">
2062
+ <div class="discussion">
2063
+ <p>
2064
+ Returns a new Time representing the time a number of specified quarters (3
2065
+ months) ago.
2066
+ </p>
2067
+
2068
+
2069
+ </div>
2070
+ </div>
2071
+ <div class="tags">
2072
+
2073
+ </div><table class="source_code">
2074
+ <tr>
2075
+ <td>
2076
+ <pre class="lines">
2077
+
2078
+
2079
+ 143
2080
+ 144
2081
+ 145</pre>
2082
+ </td>
2083
+ <td>
2084
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 143</span>
2085
+
2086
+ <span class='def def kw'>def</span> <span class='quarters_ago identifier id'>quarters_ago</span><span class='lparen token'>(</span><span class='quarters identifier id'>quarters</span><span class='rparen token'>)</span>
2087
+ <span class='ago identifier id'>ago</span><span class='lparen token'>(</span><span class='lparen token'>(</span><span class='quarters identifier id'>quarters</span> <span class='mult op'>*</span> <span class='integer val'>3</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='months identifier id'>months</span><span class='rparen token'>)</span>
2088
+ <span class='end end kw'>end</span>
2089
+ </pre>
2090
+ </td>
2091
+ </tr>
2092
+ </table>
2093
+ </div>
2094
+
2095
+ <div class="method_details ">
2096
+ <p class="signature " id="quarters_since-instance_method">
2097
+
2098
+ - (<tt>Object</tt>) <strong>quarters_since</strong>(quarters)
2099
+
2100
+
2101
+
2102
+ </p><div class="docstring">
2103
+ <div class="discussion">
2104
+ <p>
2105
+ Returns a new Time representing the time a number of specified quarters (3
2106
+ months) in the future.
2107
+ </p>
2108
+
2109
+
2110
+ </div>
2111
+ </div>
2112
+ <div class="tags">
2113
+
2114
+ </div><table class="source_code">
2115
+ <tr>
2116
+ <td>
2117
+ <pre class="lines">
2118
+
2119
+
2120
+ 148
2121
+ 149
2122
+ 150</pre>
2123
+ </td>
2124
+ <td>
2125
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 148</span>
2126
+
2127
+ <span class='def def kw'>def</span> <span class='quarters_since identifier id'>quarters_since</span><span class='lparen token'>(</span><span class='quarters identifier id'>quarters</span><span class='rparen token'>)</span>
2128
+ <span class='since identifier id'>since</span><span class='lparen token'>(</span><span class='lparen token'>(</span><span class='quarters identifier id'>quarters</span> <span class='mult op'>*</span> <span class='integer val'>3</span><span class='rparen token'>)</span><span class='dot token'>.</span><span class='months identifier id'>months</span><span class='rparen token'>)</span>
2129
+ <span class='end end kw'>end</span>
2130
+ </pre>
2131
+ </td>
2132
+ </tr>
2133
+ </table>
2134
+ </div>
2135
+
2136
+ <div class="method_details ">
2137
+ <p class="signature " id="round-instance_method">
2138
+
2139
+ - (<tt>Object</tt>) <strong>round</strong>(unit = :sec)
2140
+
2141
+
2142
+
2143
+ <span class="aliases">Also known as:
2144
+ <span class="names"><span id='beginning_of_closest-instance_method'>beginning_of_closest</span></span>
2145
+ </span>
2146
+
2147
+ </p><div class="docstring">
2148
+ <div class="discussion">
2149
+ <p>
2150
+ Returns a new Time representing the start of the current or next unit
2151
+ specified (second by default) depending which is closest
2152
+ </p>
2153
+
2154
+
2155
+ </div>
2156
+ </div>
2157
+ <div class="tags">
2158
+
2159
+ </div><table class="source_code">
2160
+ <tr>
2161
+ <td>
2162
+ <pre class="lines">
2163
+
2164
+
2165
+ 28
2166
+ 29
2167
+ 30
2168
+ 31
2169
+ 32</pre>
2170
+ </td>
2171
+ <td>
2172
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 28</span>
2173
+
2174
+ <span class='def def kw'>def</span> <span class='round identifier id'>round</span><span class='lparen token'>(</span><span class='unit identifier id'>unit</span> <span class='assign token'>=</span> <span class='symbol val'>:sec</span><span class='rparen token'>)</span>
2175
+ <span class='next_unit identifier id'>next_unit</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='ceil identifier id'>ceil</span><span class='lparen token'>(</span><span class='unit identifier id'>unit</span><span class='rparen token'>)</span>
2176
+ <span class='this_unit identifier id'>this_unit</span> <span class='assign token'>=</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='floor identifier id'>floor</span><span class='lparen token'>(</span><span class='unit identifier id'>unit</span><span class='rparen token'>)</span>
2177
+ <span class='lparen token'>(</span><span class='self self kw'>self</span> <span class='minus op'>-</span> <span class='this_unit identifier id'>this_unit</span><span class='rparen token'>)</span> <span class='lt op'>&lt;</span> <span class='lparen token'>(</span><span class='next_unit identifier id'>next_unit</span> <span class='minus op'>-</span> <span class='self self kw'>self</span><span class='rparen token'>)</span> <span class='question op'>?</span> <span class='this_unit identifier id'>this_unit</span> <span class='colon op'>:</span> <span class='next_unit identifier id'>next_unit</span>
2178
+ <span class='end end kw'>end</span>
2179
+ </pre>
2180
+ </td>
2181
+ </tr>
2182
+ </table>
2183
+ </div>
2184
+
2185
+ <div class="method_details ">
2186
+ <p class="signature " id="weeks_ago-instance_method">
2187
+
2188
+ - (<tt>Object</tt>) <strong>weeks_ago</strong>(weeks)
2189
+
2190
+
2191
+
2192
+ </p><div class="docstring">
2193
+ <div class="discussion">
2194
+ <p>
2195
+ Returns a new Time representing the time a number of specified weeks ago.
2196
+ </p>
2197
+
2198
+
2199
+ </div>
2200
+ </div>
2201
+ <div class="tags">
2202
+
2203
+ </div><table class="source_code">
2204
+ <tr>
2205
+ <td>
2206
+ <pre class="lines">
2207
+
2208
+
2209
+ 133
2210
+ 134
2211
+ 135</pre>
2212
+ </td>
2213
+ <td>
2214
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 133</span>
2215
+
2216
+ <span class='def def kw'>def</span> <span class='weeks_ago identifier id'>weeks_ago</span><span class='lparen token'>(</span><span class='weeks identifier id'>weeks</span><span class='rparen token'>)</span>
2217
+ <span class='ago identifier id'>ago</span><span class='lparen token'>(</span><span class='weeks identifier id'>weeks</span><span class='dot token'>.</span><span class='weeks identifier id'>weeks</span><span class='rparen token'>)</span>
2218
+ <span class='end end kw'>end</span>
2219
+ </pre>
2220
+ </td>
2221
+ </tr>
2222
+ </table>
2223
+ </div>
2224
+
2225
+ <div class="method_details ">
2226
+ <p class="signature " id="weeks_since-instance_method">
2227
+
2228
+ - (<tt>Object</tt>) <strong>weeks_since</strong>(weeks)
2229
+
2230
+
2231
+
2232
+ </p><div class="docstring">
2233
+ <div class="discussion">
2234
+ <p>
2235
+ Returns a new Time representing the time a number of specified weeks in the
2236
+ future.
2237
+ </p>
2238
+
2239
+
2240
+ </div>
2241
+ </div>
2242
+ <div class="tags">
2243
+
2244
+ </div><table class="source_code">
2245
+ <tr>
2246
+ <td>
2247
+ <pre class="lines">
2248
+
2249
+
2250
+ 138
2251
+ 139
2252
+ 140</pre>
2253
+ </td>
2254
+ <td>
2255
+ <pre class="code"><span class="info file"># File 'lib/time_ext/time.rb', line 138</span>
2256
+
2257
+ <span class='def def kw'>def</span> <span class='weeks_since identifier id'>weeks_since</span><span class='lparen token'>(</span><span class='weeks identifier id'>weeks</span><span class='rparen token'>)</span>
2258
+ <span class='since identifier id'>since</span><span class='lparen token'>(</span><span class='weeks identifier id'>weeks</span><span class='dot token'>.</span><span class='weeks identifier id'>weeks</span><span class='rparen token'>)</span>
2259
+ <span class='end end kw'>end</span>
2260
+ </pre>
2261
+ </td>
2262
+ </tr>
2263
+ </table>
2264
+ </div>
2265
+
2266
+ </div>
2267
+
2268
+ </div>
2269
+
2270
+ <div id="footer">
2271
+ Generated on Tue Jul 27 20:16:37 2010 by
2272
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool">yard</a>
2273
+ 0.5.8 (ruby-1.8.7).
2274
+ </div>
2275
+
2276
+ </body>
2277
+ </html>