Fey/Placeholder.pm

filter: Statementstmt 100% 27 / 27 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 9 / 9 Podpod 100% 2 / 2 totaltotal 100% 38 / 38 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« Fey/Literal/String.pm ↑ Summary Fey/Role/Comparable.pm »
1 package Fey::Placeholder;
2  
3 26 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 26 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 26 ▶use namespace::autoclean;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 26 our $VERSION = '0.43';
8  
9 26 ▶use Fey::Types;
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11 26 ▶use Moose 2.1200;
Subroutine BEGIN: called CC=1 SCAR=0.0
12 26 ▶use MooseX::SemiAffordanceAccessor 0.03;
Subroutine BEGIN: called CC=1 SCAR=0.0
13 26 ▶use MooseX::StrictConstructor 0.13;
Subroutine BEGIN: called CC=1 SCAR=0.0
14  
15 26 with 'Fey::Role::Comparable';
16  
17 sub sql {
18 67 ▶ return '?';
Subroutine sql: called CC=1 SCAR=0.0
Pod documented
19 }
20  
21 39 ▶sub sql_or_alias { goto &sql; }
Subroutine sql_or_alias: called CC=1 SCAR=0.0
Pod documented
22  
23 26 __PACKAGE__->meta()->make_immutable();
24  
25 26 1;
26  
27 # ABSTRACT: Represents a placeholder
28  
29 __END__
30  
31 =pod
32  
33 =head1 NAME
34  
35 Fey::Placeholder - Represents a placeholder
36  
37 =head1 VERSION
38  
39 version 0.43
40  
41 =head1 SYNOPSIS
42  
43 my $placeholder = Fey::Placeholder->new()
44  
45 =head1 DESCRIPTION
46  
47 This class represents a placeholder in a SQL statement.
48  
49 For now, this always means the string C<?>, but in the future it may
50 allow for numbered or named placeholders.
51  
52 =head1 METHODS
53  
54 This class provides the following methods:
55  
56 =head2 Fey::Placeholder->new()
57  
58 This method creates a new C<Fey::Placeholder> object.
59  
60 =head2 $placeholder->sql()
61  
62 =head2 $placeholder->sql_or_alias()
63  
64 Returns the appropriate SQL snippet.
65  
66 =head1 ROLES
67  
68 This class does the C<Fey::Role::Comparable> role.
69  
70 =head1 BUGS
71  
72 See L<Fey> for details on how to report bugs.
73  
74 =head1 AUTHOR
75  
76 Dave Rolsky <autarch@urth.org>
77  
78 =head1 COPYRIGHT AND LICENSE
79  
80 This software is Copyright (c) 2011 - 2015 by Dave Rolsky.
81  
82 This is free software, licensed under:
83  
84 The Artistic License 2.0 (GPL Compatible)
85  
86 =cut
« Fey/Literal/String.pm ↑ Summary Fey/Role/Comparable.pm »