| 1 | package Dallycot::AST::Identity; | ||
| 2 | 29 | our $AUTHORITY = 'cpan:JSMITH'; | |
| 3 | |||
| 4 | # ABSTRACT: Glue node to return an AST upon execution | ||
| 5 | |||
| 6 | 29 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | 29 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 8 | |||
| 9 | 29 | ▶ | use utf8; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 10 | 29 | ▶ | use parent 'Dallycot::AST'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 11 | |||
| 12 | 29 | ▶ | use Promises qw(deferred); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 13 | |||
| 14 | sub to_string { | ||
| 15 | 0 | ▶ | my ($self) = @_; |
|
Subroutine
to_string: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 16 | |||
| 17 | 0 | return $self->[0]->to_string; | |
| 18 | } | ||
| 19 | |||
| 20 | sub to_rdf { | ||
| 21 | 0 | ▶ | my($self, $model) = @_; |
|
Subroutine
to_rdf: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 22 | |||
| 23 | 0 | return $self->[0]->to_rdf($model); | |
| 24 | } | ||
| 25 | |||
| 26 | sub execute { | ||
| 27 | 123 | ▶ | my ( $self, $engine ) = @_; |
|
Subroutine
execute: called CC=1 SCAR=0.0
Pod
undocumented
| |||
| 28 | |||
| 29 | 123 | my $d = deferred; | |
| 30 | |||
| 31 | 123 | $d->resolve( $self->[0] ); | |
| 32 | |||
| 33 | 123 | return $d->promise; | |
| 34 | } | ||
| 35 | |||
| 36 | 29 | 1; | |