Agent-TCLI-Package-Net

 view release on metacpan or  search on metacpan

lib/Agent/TCLI/Package/Net/Ping.pm  view on Meta::CPAN

          	_shutdown
          	_default
          	_child
			establish_context
			ping
			Pong
			settings
			show
			)],
      ],
	);
}

sub _init :Init {
	my $self = shift;

#  constraints:
#    - ASCII


	$self->LoadYaml(<<'...');
---
Agent::TCLI::Parameter:
  name: target
  class: NetAddr::IP
  constraints:
    - ASCII
  help: the target ip address
  manual: >
    The target IP address for the attack. The target may
    be specified as a domain name or as a dotted quad.
  type: Param
  show_method: addr
---
Agent::TCLI::Parameter:
  name: timeout
  constraints:
    - UINT
  default: 10
  class: numeric
  help: the timeout in seconds
  manual: >
    Changes the wait before giving up on getting a response. The default
    is 10 seconds.
  type: Param
---
Agent::TCLI::Parameter:
  name: retry_count
  constraints:
    - UINT
  default: 1
  class: numeric
  help: The number of times to retry when no response is received
  manual: >
    This parameter will cause the specified number or retry attampts
    This will only happen if there is no response from prior requests.
  type: Param
---
Agent::TCLI::Command:
  name: ping
  call_style: session
  command: tcli_ping
  contexts:
    ROOT: ping
  handler: ping
  help: check to see if a host is alive
  manual: >
    Ping will send an ICMP echo to a target, hoping to get an ICMP
    response before a timeout. One can ping multiple hosts concurrently.
  parameters:
    target:
    timeout:
    retry_count:
  required:
    target:
  topic: network
  usage: ping target example.com
---
Agent::TCLI::Command:
  name: set
  call_style: session
  command: tcli_ping
  contexts:
    ping: set
  handler: settings
  help: set defaults for pings attacks
  parameters:
    target:
    timeout:
    retry_count:
  topic: network
  usage: ping set target=target.example.com
---
Agent::TCLI::Command:
  name: show
  call_style: session
  command: tcli_ping
  contexts:
    ping: show
  handler: show
  help: show current settings
  parameters:
    target:
    timeout:
    retry_count:
  topic: network
  usage: ping show timeout
...

}

1;
#__END__

=head3 INHERITED METHODS

This module is an Object::InsideOut object that inherits from Agent::TCLI::Package::Base. It
inherits methods from both. Please refer to their documentation for more
details.

=head1 AUTHOR

Eric Hacker	 E<lt>hacker at cpan.orgE<gt>

=head1 BUGS

SHOULDS and MUSTS are currently not always enforced.

Test scripts not thorough enough.

Probably many others.

=head1 LICENSE

Copyright (c) 2007, Alcatel Lucent, All rights resevred.

This package is free software; you may redistribute it
and/or modify it under the same terms as Perl itself.

=cut



( run in 0.554 second using v1.01-cache-2.11-cpan-5837b0d9d2c )