| 1 | package Org::Element::TimeRange; | ||||||||||
| 2 | |||||||||||
| 3 | 4 | ▶ | use 5.010; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 4 | ▶ | use locale; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | 4 | ▶ | use Moo; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | 4 | extends 'Org::Element'; | |||||||||
| 7 | 4 | with 'Org::ElementRole'; | |||||||||
| 8 | 4 | with 'Org::ElementRole::Inline'; | |||||||||
| 9 | |||||||||||
| 10 | 4 | our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY | |||||||||
| 11 | 4 | our $DATE = '2026-07-21'; # DATE | |||||||||
| 12 | 4 | our $DIST = 'Org-Parser'; # DIST | |||||||||
| 13 | 4 | our $VERSION = '0.563'; # VERSION | |||||||||
| 14 | |||||||||||
| 15 | 4 | has ts1 => (is => 'rw'); | |||||||||
| 16 | 4 | has ts2 => (is => 'rw'); | |||||||||
| 17 | |||||||||||
| 18 | 0 | ▶ | sub as_string { | ||||||||
|
Subroutine
as_string: not called CC=2 SCAR=17.9
Pod
documented
| |||||||||||
| 19 | 0 | my ($self) = @_; | |||||||||
| 20 | 0 | ▶ | return $self->_str if $self->_str; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 21 | 0 | join("", | |||||||||
| 22 | $self->ts1->as_string, | ||||||||||
| 23 | "--", | ||||||||||
| 24 | $self->ts2->as_string | ||||||||||
| 25 | ); | ||||||||||
| 26 | } | ||||||||||
| 27 | |||||||||||
| 28 | 0 | ▶ | sub as_text { | ||||||||
|
Subroutine
as_text: not called CC=1 SCAR=6.9
Pod
documented
| |||||||||||
| 29 | 0 | goto \&as_string; | |||||||||
| 30 | } | ||||||||||
| 31 | |||||||||||
| 32 | 4 | 1; | |||||||||
| 33 | # ABSTRACT: Represent Org time range (TS1--TS2) | ||||||||||
| 34 | |||||||||||
| 35 | __END__ | ||||||||||