NAME

Hades::Realm::Exporter - Hades realm for Exporter

VERSION

Version 0.01

SYNOPSIS

Quick summary of what the module does:

Hades->run({
	eval => 'Kosmos {
		[curae penthos] :t(Int) :d(2) :p :pr :c :r :i(1, GROUP)
		geras $nosoi :t(Int) :d(5) :i { if (penthos() == $nosoi) { return curae; } } 
	}',
	realm => 'Exporter',
});

... generates ...

package Kosmos;
use strict;
use warnings;
use Exporter qw/import/;
our $VERSION = 0.01;
our ( @EXPORT, @EXPORT_OK, %EXPORT_TAGS, %ACCESSORS );

BEGIN {
	@EXPORT = (
		'curae',       'has_curae', 'clear_curae', 'penthos',
		'has_penthos', 'clear_penthos'
	);
	@EXPORT_OK = (
		'curae',       'has_curae',     'clear_curae', 'penthos',
		'has_penthos', 'clear_penthos', 'geras'
	);
	%EXPORT_TAGS = (
		'METHODS'    => ['geras'],
		'CLEARERS'   => [ 'clear_curae', 'clear_penthos' ],
		'GROUP'      => [ 'curae', 'penthos' ],
		'PREDICATES' => [ 'has_curae', 'has_penthos' ],
		'ACCESSORS'  => [ 'curae', 'penthos' ]
	);
	%ACCESSORS = ( curae => 2, penthos => 2, );
}

sub curae {
	my ($value) = @_;
	my $private_caller = caller();
	if ( $private_caller ne __PACKAGE__ ) {
		die "cannot call private method curae from $private_caller";
	}
	if ( defined $value ) {
		if ( ref $value || $value !~ m/^[-+\d]\d*$/ ) {
			die qq{Int: invalid value $value for accessor curae};
		}
		$ACCESSORS{curae} = $value;
	}
	return $ACCESSORS{curae};
}

sub has_curae {
	return exists $ACCESSORS{curae};
}

sub clear_curae {
	delete $ACCESSORS{curae};
	return 1;
}

sub penthos {
	my ($value) = @_;
	my $private_caller = caller();
	if ( $private_caller ne __PACKAGE__ ) {
		die "cannot call private method penthos from $private_caller";
	}
	if ( defined $value ) {
		if ( ref $value || $value !~ m/^[-+\d]\d*$/ ) {
			die qq{Int: invalid value $value for accessor penthos};
		}
		$ACCESSORS{penthos} = $value;
	}
	return $ACCESSORS{penthos};
}

sub has_penthos {
	return exists $ACCESSORS{penthos};
}

sub clear_penthos {
	delete $ACCESSORS{penthos};
	return 1;
}

sub geras {
	my ($nosoi) = @_;
	$nosoi = defined $nosoi ? $nosoi : 5;
	if ( !defined($nosoi) || ref $nosoi || $nosoi !~ m/^[-+\d]\d*$/ ) {
		$nosoi = defined $nosoi ? $nosoi : 'undef';
		die
		    qq{Int: invalid value $nosoi for variable \$nosoi in method geras};
	}
	if ( penthos() == $nosoi ) { return curae(); }
}

1;

__END__

SUBROUTINES/METHODS

new

Instantiate a new Hades::Realm::Exporter object.

Hades::Realm::Exporter->new

build_self

call build_self method. Expects param $name to be a Optional[Str].

$obj->build_self($name)

default_export_hash

call default_export_hash method. Expects param $mg to be a Object, param $class to be a HashRef, param $export to be a HashRef.

$obj->default_export_hash($mg, $class, $export)

build_new

call build_new method. Expects param $mg to be a Object, param $meta to be a HashRef, param $our to be any value including undef.

$obj->build_new($mg, $meta, $our)

build_exporter

call build_exporter method. Expects param $begin to be a Str, param $mg to be a Object, param $export to be a HashRef, param $meta to be a HashRef.

$obj->build_exporter($begin, $mg, $export, $meta)

build_export_tags

call build_export_tags method. Expects param $name to be a Str, param $type to be a Str, param $export to be a HashRef, param $now to be a Optional[Int], param $import to be a ArrayRef.

$obj->build_export_tags($name, $type, $export, $now, $import)

after_class

call after_class method. Expects param $mg to be a Object.

$obj->after_class($mg)

build_sub_or_accessor_attributes

call build_sub_or_accessor_attributes method.

build_accessor_no_arguments

call build_accessor_no_arguments method. Expects param $mg to be any value including undef, param $token to be any value including undef, param $meta to be any value including undef.

$obj->build_accessor_no_arguments($mg, $token, $meta)

build_accessor_code

call build_accessor_code method. Expects param $name to be a Str, param $private to be a Str, param $type to be a Str, param $trigger to be a Str.

$obj->build_accessor_code($name, $private, $type, $trigger)

build_accessor

call build_accessor method.

build_modify

call build_modify method. Expects no params.

$obj->build_modify()

build_sub_no_arguments

call build_sub_no_arguments method. Expects param $mg to be any value including undef, param $token to be any value including undef, param $meta to be any value including undef.

$obj->build_sub_no_arguments($mg, $token, $meta)

build_sub_code

call build_sub_code method. Expects param $name to be a Str, param $params to be a Str, param $subtype to be a Str, param $code to be a Str.

$obj->build_sub_code($name, $params, $subtype, $code)

build_sub

call build_sub method.

build_clearer

call build_clearer method. Expects param $mg to be a Object, param $name to be a Str, param $meta to be a HashRef.

$obj->build_clearer($mg, $name, $meta)

build_predicate

call build_predicate method. Expects param $mg to be a Object, param $name to be a Str, param $meta to be a HashRef.

$obj->build_predicate($mg, $name, $meta)

build_coerce

call build_coerce method. Expects param $name to be a Str, param $param to be a Str, param $code to be a Optional[Str].

$obj->build_coerce($name, $param, $code)

build_trigger

call build_trigger method. Expects param $name to be a Str, param $param to be a Str, param $code to be a Optional[Str].

$obj->build_trigger($name, $param, $code)

build_tests

call build_tests method. Expects param $name to be a Str, param $meta to be a HashRef, param $mod to be a Optional[Str], param $class to be a Optional[HashRef].

$obj->build_tests($name, $meta, $mod, $class)

ACCESSORS

export

get or set export.

$obj->export;

$obj->export($value);

AUTHOR

LNATION, <email at lnation.org>

BUGS

Please report any bugs or feature requests to bug-hades::realm::exporter at rt.cpan.org, or through the web interface at https://rt.cpan.org/NoAuth/ReportBug.html?Queue=Hades-Realm-Exporter. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

SUPPORT

You can find documentation for this module with the perldoc command.

perldoc Hades::Realm::Exporter

You can also look for information at:

ACKNOWLEDGEMENTS

LICENSE AND COPYRIGHT

This software is Copyright (c) 2020 by LNATION.

This is free software, licensed under:

The Artistic License 2.0 (GPL Compatible)