213 |
if ($by eq 'display-name') { |
if ($by eq 'display-name') { |
214 |
$$i->{value} = $self->_parse_value ($$i->{type}, $$i->{value}); |
$$i->{value} = $self->_parse_value ($$i->{type}, $$i->{value}); |
215 |
return 1 if ref $$i->{value} && $$list{$$i->{value}->display_name}; |
return 1 if ref $$i->{value} && $$list{$$i->{value}->display_name}; |
216 |
|
} elsif ($by eq 'addr-spec') { |
217 |
|
$$i->{value} = $self->_parse_value ($$i->{type}, $$i->{value}); |
218 |
|
return 1 if ref $$i->{value} && $$list{$$i->{value}->addr_spec}; |
219 |
} |
} |
220 |
0; |
0; |
221 |
} |
} |
223 |
|
|
224 |
## Returns returned item value \$item-value, \%option |
## Returns returned item value \$item-value, \%option |
225 |
sub _item_return_value ($\$\%) { |
sub _item_return_value ($\$\%) { |
226 |
if (ref ${$_[1]}) { |
if (ref ${$_[1]}->{value}) { |
227 |
${$_[1]}->{value}; |
${$_[1]}->{value}; |
228 |
} else { |
} else { |
229 |
${$_[1]}->{value} = $_[0]->_parse_value (${$_[1]}->{type}, ${$_[1]}->{value}); |
${$_[1]}->{value} = $_[0]->_parse_value (${$_[1]}->{type}, ${$_[1]}->{value}); |
230 |
${$_[1]}->{value}; |
${$_[1]}->{value}; |
231 |
} |
} |
232 |
} |
} |
233 |
|
*_add_return_value = \&_item_return_value; |
234 |
|
|
235 |
## Returns returned (new created) item value $name, \%option |
## Returns returned (new created) item value $name, \%option |
236 |
sub _item_new_value ($$\%) { |
sub _item_new_value ($$\%) { |
266 |
my $self = shift; |
my $self = shift; |
267 |
my @a; |
my @a; |
268 |
for (@{$self->{$self->{option}->{_ARRAY_NAME}}}) { |
for (@{$self->{$self->{option}->{_ARRAY_NAME}}}) { |
269 |
$_->{value} = $self->_parse_value ($_->{value}) unless ref $_->{value}; |
$_->{value} = $self->_parse_value |
270 |
|
($_->{type} => $_->{value}) unless ref $_->{value}; |
271 |
if (ref $_->{value}) { |
if (ref $_->{value}) { |
272 |
push @a, $_->{value}->addr_spec (@_); |
push @a, $_->{value}->addr_spec (@_); |
273 |
} elsif (length $_->{value}) { |
} elsif (length $_->{value}) { |