Aw::ClientX - ActiveWorks Client as Blessed Hash.


Aw documentation Contained in the Aw distribution.

Index


Code Index:

NAME

Top

Aw::ClientX - ActiveWorks Client as Blessed Hash.

SYNOPSIS

Top

require Aw::ClientX;

my $client = new Aw::ClientX ( "myGroup", "myApp" );

DESCRIPTION

Top

Demonstative module that allows for a blessed hash to act as a client.

AUTHOR

Top

Daniel Yacob Mekonnen, Yacob@wMUsers.Com

SEE ALSO

Top

perl(1).  Aw(3).


Aw documentation Contained in the Aw distribution.

package Aw::ClientX;


BEGIN
{
	use strict;
	use vars qw($VERSION);

	$VERSION = '0.3';

	use Aw;
	require Aw::Client;
}



sub new
{
my $self = {};

	my $blessing = bless $self, shift;

	if ( @_ > 2 ) {
		$self->{_client} = Aw::Client::_new ( "Aw::Client", @_ )
	}
	else {
		my ($client_group)  = @_;
		my $app_name = (@_ == 2) ? $_[1] : $0.".Client";

		$self->{_client} = Aw::Client::_new ( "Aw::Client", $Aw::DefaultBrokerHost, $Aw::DefaultBrokerName, "", $client_group, $app_name );

	}

	$blessing;
}


sub AUTOLOAD
{
	my($self) = shift;
	my($arg) = shift;
	my($method) = ($AUTOLOAD =~ /::([^:]+)$/);
	return unless ($method);

	$self->{_client}->$method ( $arg );

}



#########################################################
# Do not change this, Do not put anything below this.
# File must return "true" value at termination
1;
##########################################################


__END__