| 1 | package Data::MuForm::Model::Object; | ||||||||||
| 2 | # ABSTRACT: stub for Object model | ||||||||||
| 3 | |||||||||||
| 4 | 1 | ▶ | use Moo::Role; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | |||||||||||
| 6 | sub update_model { | ||||||||||
| 7 | 0 | ▶ | my $self = shift; | ||||||||
|
Subroutine
update_model: not called CC=4 SCAR=30.0
Pod
undocumented
| |||||||||||
| 8 | |||||||||||
| 9 | 0 | my $model = $self->model; | |||||||||
| 10 | 0 | ▶ | return unless $model; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 11 | 0 | foreach my $field ( $self->sorted_fields ) { | |||||||||
| 12 | 0 | my $name = $field->name; | |||||||||
| 13 | 0 | ▶ | next unless $model->can($name); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 14 | 0 | $model->$name( $field->value ); | |||||||||
| 15 | } | ||||||||||
| 16 | } | ||||||||||
| 17 | |||||||||||
| 18 | 1 | 1; | |||||||||
| 19 | |||||||||||
| 20 | __END__ | ||||||||||
| 21 | |||||||||||
| 22 | =pod | ||||||||||
| 23 | |||||||||||
| 24 | =encoding UTF-8 | ||||||||||
| 25 | |||||||||||
| 26 | =head1 NAME | ||||||||||
| 27 | |||||||||||
| 28 | Data::MuForm::Model::Object - stub for Object model | ||||||||||
| 29 | |||||||||||
| 30 | =head1 VERSION | ||||||||||
| 31 | |||||||||||
| 32 | version 0.04 | ||||||||||
| 33 | |||||||||||
| 34 | =head1 AUTHOR | ||||||||||
| 35 | |||||||||||
| 36 | Gerda Shank | ||||||||||
| 37 | |||||||||||
| 38 | =head1 COPYRIGHT AND LICENSE | ||||||||||
| 39 | |||||||||||
| 40 | This software is copyright (c) 2017 by Gerda Shank. | ||||||||||
| 41 | |||||||||||
| 42 | This is free software; you can redistribute it and/or modify it under | ||||||||||
| 43 | the same terms as the Perl 5 programming language system itself. | ||||||||||
| 44 | |||||||||||
| 45 | =cut | ||||||||||