| 1 | package Poker::Card; | ||
| 2 | 13 | our $VERSION = '0.12'; | |
| 3 | |||
| 4 | |||
| 5 | 13 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | 13 | ▶ | use warnings FATAL => 'all'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | 13 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 8 | |||
| 9 | =head1 NAME | ||
| 10 | |||
| 11 | Poker::Card - Simple class to represent a poker card. | ||
| 12 | |||
| 13 | =head1 VERSION | ||
| 14 | |||
| 15 | Version 0.12 | ||
| 16 | |||
| 17 | =cut | ||
| 18 | |||
| 19 | |||
| 20 | |||
| 21 | =head1 SYNOPSIS | ||
| 22 | |||
| 23 | This class is used internally by Poker::Deck. You probably don't want to use it directly. Attributes include rank, suit, up_flag, and wild_flag. | ||
| 24 | |||
| 25 | =cut; | ||
| 26 | |||
| 27 | 13 | has 'suit' => ( | |
| 28 | is => 'rw', | ||
| 29 | ); | ||
| 30 | |||
| 31 | 13 | has 'rank' => ( | |
| 32 | is => 'rw', | ||
| 33 | ); | ||
| 34 | |||
| 35 | 13 | has 'id' => ( | |
| 36 | is => 'rw', | ||
| 37 | ); | ||
| 38 | |||
| 39 | 13 | has 'up_flag' => ( | |
| 40 | is => 'rw', | ||
| 41 | ); | ||
| 42 | |||
| 43 | 13 | has 'wild_flag' => ( | |
| 44 | is => 'rw', | ||
| 45 | clearer => 1, | ||
| 46 | predicate => 'is_wild', | ||
| 47 | ); | ||
| 48 | |||
| 49 | 0 | ▶ | sub clone { |
|
Subroutine
clone: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 50 | 0 | my $self = shift; | |
| 51 | 0 | bless { %$self, @_ }, ref $self; | |
| 52 | } | ||
| 53 | |||
| 54 | =head1 AUTHOR | ||
| 55 | |||
| 56 | Nathaniel Graham, C<< <ngraham at cpan.org> >> | ||
| 57 | |||
| 58 | =head1 LICENSE AND COPYRIGHT | ||
| 59 | |||
| 60 | Copyright 2016 Nathaniel Graham. | ||
| 61 | |||
| 62 | This program is free software; you can redistribute it and/or modify it | ||
| 63 | under the terms of the the Artistic License (2.0). You may obtain a | ||
| 64 | copy of the full license at: | ||
| 65 | |||
| 66 | L<http://www.perlfoundation.org/artistic_license_2_0> | ||
| 67 | |||
| 68 | =cut | ||
| 69 | |||
| 70 | 13 | 1; | |