hile(my ($k, $v) = each %args) {
if($k eq 'create') {
$opt{create} = $v ? 1 : 0;
} elsif($k ~~ $class->_supported_callbacks) {
$self->{_callback}->{$k} = $v;
} else {
warn "Unknown call
_CALL, /* $foo.^methods */
PVIP_NODE_REGEXP,
PVIP_NODE_SMART_MATCH, /* ~~ */
PVIP_NODE_NOT_SMART_MATCH, /* !~~ */
PVIP_NODE_PERL5_REGEXP, /* m:P5/./ */
PVIP_NODE_TRUE,
PVIP_NOD
(sort values %{$EntityMap{$args{entity}->name}->{store}}) {
next ENTRY unless all { $entry->{$_} ~~ $args{data}->{$_} } keys %{$args{data}};
++$seen;
$args{on_item}->($entry) if exists $args{on_
queue} = PICA::Modification::Queue->new( $args{queue} )
unless 'PICA::Modification::Queue' ~~ reftype $args{queue};
$args{check} ||= 60;
if (($args{via} // '') =~ /^https?:\/\//)
};
}
croak "missing 'via' parameter to retrieve PICA+ records from"
unless 'CODE' ~~ reftype $args{via};
bless \%args, $class;
}
sub get {
my ($self, $id) = @_;
my $requ
(time()-$self->{check});
return $request if ($next cmp $last) == -1;
$request->update( 0 ~~ $self->pending($request) ? 1 : 0 );
$self->{queue}->update( $id => $request );
$self->{que
if data is incorrect.
=item Anything else
Data's value must magically match rule's value (with C<~~> operator).
=back
Optional third argument (C<$overrule>) must be a coderef. It will be called wi
nless ref $data eq $rule;
$result = $data;
} else {
die 'INVALID' unless $data ~~ $rule;
$result = $data;
}
if ($overrule)
{
local $_ = $result;
iants) = @_;
return sub {
return unless ref $_ eq 'ARRAY';
my @items = grep $_ ~~ @variants, keys %{{ map { $_ => 1 } @$_ }};
return \@items if scalar(@items) > 0;
};
}
'.$now if ( 'created_at' ~~ [ $self->app->model->resultset( $self->{resource} )->result_source->columns ] );
$self->{_payload}->{updated_at} = ''.$now if ( 'updated_at' ~~ [ $self->app->model->res
my $now = DateTime->now ;
$self->{_payload}->{updated_at} = ''.$now if ( 'updated_at' ~~ [ $self->app->model->resultset( $self->{resource} )->result_source->columns ] );
}
1;
__END__
=p
s = ['group', 'matrix', 'cube', 'hypercube']; # if you go past here, you've gone too far...
given (reftype $tree) {
# Common code for both HASHs and ARRAYs
when (/HASH|ARRAY/) {
# and all foreign keys that refer to it.
elsif ($pkey) { $fk_list = [ grep { $colnames->{$_} ~~ /^$pkey$/ } keys %$colnames ]; }
# If only FKT is given, then the result set contains all fore
n + 1) {
my @s = @$tokens[$c .. $c+$nn-2];
$count++ if @s ~~ @search;
$c++;
}
$denominator = $count;
itespaces with 1 whitespace
return $value;
}
# Description:
# Returns useflag settings of the given (installed) package.
# @useflags=$pxs->getUseSettingsOfInstalledPackage("dev-perl/perl-5.8.8-r3")
sub mk_query_to_server {
my ( $self, $method, $url, $params ) = @_;
unless ( $method ~~ [ qw( POST GET ) ] ) {
confess "Unknown request method: '$method'";
}
confess "UR
my $package = $params->{package};
unless ( $self->{fake_answer} ) {
unless ( $package ~~ $self->show_packages() ) {
return {error => 1, text => "No such package $package on server"};
>distributions($id);
my $kwalitee = $authors->kwalitee($id);
print "$name has published ", ~~ @dists, " distributions:\n";
@dists = sort { lc($a->dist) cmp lc($b->dist) } @dists;
for m
) {
print ( $v->{time} - $t ) . ": $v->{value}\n"
# Or with human-readable times
# print ~~ localtime ( $v->{time} - $t ) . ": $v->{value}\n"
}
=head1 AUTHOR
Luke Poskitt, C<< <ltp at cp
$file = $next_file->() ) ) {
my $mtime = stat($file)->mtime;
if ( ( !$force ) and $mtime ~~ $mtimes{$file} ) {
next;
}
my $perlcritic = "perlcritic $ARGV{-C} $file";
e ( defined( my $file = $next_file->() ) ) {
my $mtime = stat($file)->mtime;
if ( $mtime ~~ $mtimes{$file} ) {
next;
}
my $perltidy = "perltidy $ARGV{-P} $file";
if
ACH loop !
my $played_warlock_classical = 'Warlock' ~~ @roles_played_classical; # assigns boolean
# my $played_warlock_classical = 'Warloc' ~~ @roles_played_classical; # assigns an empty string,
unless ( grep { $_caller eq $_ } @__FRIENDS__ );
#unless ( $_caller ~~ @__FRIENDS__ );
}
$_[0]->[1]->{$fn};
};
less ( grep { $_caller eq $_ } @__FRIENDS__ );
#unless ( $_caller ~~ @__FRIENDS__ );
}
$_[0]->[0]->[$p];
less ( grep { $_caller eq $_ } @__FRIENDS__ );
#unless ( $_caller ~~ @__FRIENDS__ );
}
$_[0]->[1]->{$fn};
=~ s/[-\W]/_/g;
$name;
}
func _range($val, $dent) {
my $ret = "";
$ret .= '[';
given ( $val->{type} ) {
when ( 'hex' ) {
$ret .= join('-', map { '\x{' . $_ . '}' } $val->{min},
lue} \n";
}
}
$ret .= "]";
$ret;
}
func _string($val, $dent) {
my $ret = "";
given ( $val->{type} ) {
when ( 'hex' ) {
$ret = join('', map { '\x' . $_ } @{$val->{value}});
enerateChain>.
Uses in generate call to stringify chains.
=cut
func _asStrings($generated) {
given ( $generated->{class} ) {
when ( "Atom" ) { return [ $generated->{value} ] }
when ( "Sequenc
tern matching and named binding
#if ($string ~~ s:/^ $field := (<-[ \t:]>+) <[ \t]>*\: <sp>? $value := (.*) \n?//) {
if ($string ~~ s:P5/^([^ \t:]+)[ \t]*: ?(.*)\n?//) {
$f
;
#$value ~~ s/\r$//;
$value ~~ s:P5/\r\z//;
%headers{$field} = $value;
} elsif (%headers.pairs && $string ~~ s/^ (<[ \t]> .*) \n?//) {
rs{$field} ~= "\n$0";
#%headers{$field} ~~ s/\r$//;
%headers{$field} ~~ s:P5/\r\z//;
} else {
$string ~~ s:P5/^\r?\n//;
last;
}
}