Aion

 view release on metacpan or  search on metacpan

LICENSE  view on Meta::CPAN

for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.

  Conveying under any other circumstances is permitted solely under
the conditions stated below.  Sublicensing is not allowed; section 10
makes it unnecessary.

  3. Protecting Users' Legal Rights From Anti-Circumvention Law.

  No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.

  When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.

  4. Conveying Verbatim Copies.

  You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.

README.md  view on Meta::CPAN

[![Actions Status](https://github.com/darviarush/perl-aion/actions/workflows/test.yml/badge.svg)](https://github.com/darviarush/perl-aion/actions) [![GitHub Issues](https://img.shields.io/github/issues/darviarush/perl-aion?logo=perl)](https://github....
# NAME

Aion - постмодернистская объектная система для Perl 5, такая как «Mouse», «Moose», «Moo», «Mo» и «M», но с улучшениями

# VERSION

1.5

# SYNOPSIS

i18n/Aion.ru-en.po  view on Meta::CPAN

msgid "Используем плерому локально:"
msgstr "We use pleroma locally:"

msgid "См. [Aion::Pleroma](https://metacpan.org/pod/Aion::Pleroma)."
msgstr "See [Aion::Pleroma](https://metacpan.org/pod/Aion::Pleroma)."

msgid "`$sub` вызывается после установки свойства в конструкторе (`new`) или через сеттер."
msgstr "`$sub` is called after setting the property in the constructor (`new`) or via a setter."

msgid "Этимология `trigger` – впустить."
msgstr "The etymology of `trigger` is to let in."

msgid "`$sub` вызывается перед возвратом свойства из объекта через геттер."
msgstr "`$sub` is called before returning a property from an object via a getter."

msgid "Этимология `release` – выпустить."
msgstr "The etymology of `release` is to release."

msgid "Меняет имя свойства в конструкторе."
msgstr "Changes the property name in the constructor."

msgid "Меняет имя акцессора."
msgstr "Changes the accessor name."

msgid "Создаёт сеттер с именем `$name` для свойства."
msgstr "Creates a setter named `$name` for a property."

i18n/Aion/Types.ru-en.po  view on Meta::CPAN

msgid "Союз нескольких типов. Аналогичен оператору `$type1 | $type2`."
msgstr "Union of several types. Similar to the `$type1 | $type2`."

msgid "Пересечение нескольких типов. Аналогичен оператору `$type1 & $type2`."
msgstr "The intersection of several types. Similar to the `$type1 & $type2` operator."

msgid "Исключение нескольких типов. Аналогичен оператору `~ $type`."
msgstr "Exclusion of several types. Similar to the `~$type` operator."

msgid "Если `Exclude` имеет много аргументов, то это аналог `~ ($type1 | $type2 ...)`."
msgstr "If `Exclude` has many arguments, then it is analogous to `~ ($type1 | $type2 ...)`."

msgid "Дополнительные ключи в `Dict`."
msgstr "Additional keys in `Dict`."

msgid "Если подпрограмма возвращает разные значения в контексте массива и скаляра, то используется тип `Wantarray` с типом `A` для контекста массÐ...
msgstr "If the routine returns different values in array and scalar contexts, then the `Wantarray` type is used with type `A` for the array context and type `S` for the scalar context."

msgid "Тип верхнего уровня в иерархии скалярных типов."
msgstr "The top-level type in the hierarchy of scalar types."

lib/Aion.pm  view on Meta::CPAN

	
		$counter->accomulator->power->counter # -> $counter
	}

See L<Aion::Pleroma>.

=head2 trigger => $sub

C<$sub> is called after setting the property in the constructor (C<new>) or via a setter.

The etymology of C<trigger> is to let in.

	package ExTrigger { use Aion;
		has x => (trigger => sub {
			my ($self, $old_value) = @_;
			$self->y($old_value + $self->x);
		});
	
		has y => ();
	}
	
	my $ex = ExTrigger->new(x => 10);
	$ex->y	  # -> 10
	$ex->x(20);
	$ex->y	  # -> 30

=head2 release => $sub

C<$sub> is called before returning a property from an object via a getter.

The etymology of C<release> is to release.

	package ExRelease { use Aion;
		has x => (release => sub {
			my ($self, $value) = @_;
			$_[1] = $value + 1;
		});
	}
	
	my $ex = ExRelease->new(x => 10);
	$ex->x	  # -> 11

lib/Aion/Types.pm  view on Meta::CPAN


=head2 Exclude[A, B...]

Exclusion of several types. Similar to the C<~$type> operator.

	-5  ~~ Exclude[PositiveInt] # -> 1
	"a" ~~ Exclude[PositiveInt] # -> 1
	5   ~~ Exclude[PositiveInt] # -> ""
	5.5 ~~ Exclude[PositiveInt] # -> 1

If C<Exclude> has many arguments, then it is analogous to C<~ ($type1 | $type2 ...)>.

	-5  ~~ Exclude[PositiveInt, Enum[-2]] # -> 1
	-2  ~~ Exclude[PositiveInt, Enum[-2]] # -> ""
	0   ~~ Exclude[PositiveInt, Enum[-2]] # -> ""

=head2 Option[A]

Additional keys in C<Dict>.

	{a=>55} ~~ Dict[a=>Int, b => Option[Int]]          # -> 1



( run in 3.215 seconds using v1.01-cache-2.11-cpan-0371d4a6215 )