From ebae593425aef965ca2504db727c56e70d308d87 Mon Sep 17 00:00:00 2001 From: dakkar Date: Mon, 29 Aug 2011 14:24:53 +0100 Subject: notches --- lib/Enigmatic/Rotor.pm | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'lib/Enigmatic/Rotor.pm') diff --git a/lib/Enigmatic/Rotor.pm b/lib/Enigmatic/Rotor.pm index 792c7b5..e0a3b97 100644 --- a/lib/Enigmatic/Rotor.pm +++ b/lib/Enigmatic/Rotor.pm @@ -1,6 +1,7 @@ package Enigmatic::Rotor; use DAKKAR::p 'class'; use Enigmatic::Types qw(WiringMap Letter RotorPos); +use MooseX::Types::Set::Object; has wiring => ( is => 'ro', @@ -14,6 +15,15 @@ has ring_setting => ( default => 0, ); +has notches => ( + isa => 'Set::Object', + coerce => 1, + handles => { + has_notch_at => 'member', + }, + default => sub { [] }, +); + with 'Enigmatic::Role::WithWiring'; sub map { -- cgit v1.2.3