Hello
I am on my way to improve my wonderful Perl skills, I got an issue which I want to share with you all. I have a Perl module which looks like
and I want to print the value of variables a, b and c. I am trying below but fails
It does not print any thing. Also it does not throw any error..
All
Please help me to call url in Perl. Ex:
http://www.test.com/dynf?urn=123
Assume it will return success if 123 is in urn or it will return " failed".
I want store this return type in a variable.
Please help me to call the URL through PERL.
Thanx in advance
Regards
Deepak (1 Reply)
Hi all,
Not sure if this is the right forum to post query regarding perl script.
I have a perl script which internally calls a shell script. My problem is that the shell script should be passed command line arguments.
I call a shell script from perl using:
system("sript.sh");
How do... (3 Replies)
Hi,
I would like to invoke "Winzip" utility from a perl script, input the name of zip file and provide output path for unzipped files. Any pointers will be appreciated.
Thanks (5 Replies)
Hi,
I am trying to execute a perl script from c program.
I tried using system command.
system("perl test.pl filename") ;
This perl program takes filename as input and prints a number
to screen.
I need to get that returned number in C program.
system command is... (3 Replies)
Hi ,
Here is my piece of code--
main();
sub main
{
$result = GetOptions ("LogDir=s" => \$LogDir,
"Summary" => \$Summary,
"Indiviual=s" => \$Individual ,
"Diagnostics=s" => \$Diagnostics,
... (1 Reply)
On bash I run precompiled c Program as follows:
./create_cust 1 10000 US S > us_cust.csv
create_cust is a c program and requires 4 parameters.
I am redirecting the output of this program to csv file
I need to run this same program in perl
I am aware of exec command though not... (7 Replies)
hi all,
I have 3 perl scripts a.pl,b.pl and c.pl
each of these work when i pass a date for eg: perl c.pl 2010-05-27
now i want to write a perl script that would call the 3 scripts and make it run all the 3 scripts (a.pl,b.pl,c.pl) parallelly rather than 1 after the other.......
pls... (2 Replies)
All,
Is it possible to call a subroutine from the perl expect module after logging to a system that is within the same program. My situation is I need to run a logic inside a machine that I'm logging in using the expect module, the logic is also available in the same expect program.
Thanks,... (5 Replies)
Can anyone break down the different methods of using SSH in perl? I'm currently using Net::SSH::Expect, which allows me to login to a machine and execute multiple commands without having to ssh again. This feature of holding the session works well for me, but it's slow. If I set timeouts to 4... (3 Replies)
Note: Not a programmer by profession but occasionally have to program.
I am looking for general methods and freely/readily available tools employed to debug problems during development of perl scripts. Anything that has really helped you out with problems you just couldn't find.
A couple of... (5 Replies)
Discussion started by: Vi-Curious
5 Replies
LEARN ABOUT DEBIAN
validation::class::exporter
Validation::Class::Exporter(3pm) User Contributed Perl Documentation Validation::Class::Exporter(3pm)NAME
Validation::Class::Exporter - Simple Exporter for Validation::Class Classes
VERSION
version 7.70
SYNOPSIS
package MyApp::Class;
use Validation::Class;
use Validation::Class::Exporter;
Validation::Class::Exporter->apply_spec(
routines => ['thing'], # export routines as is
settings => [ ... ] # passed to the "load" method, see Validation::Class
);
has foo => 0;
bld sub {
shift->foo(1);
};
sub thing {
my $args = pop;
my $class = shift || caller;
# routine as a keyword
$class->{config}->{THING} = [$args];
};
package MyApp::Example;
use MyApp::Class;
thing ['this' => 'that'];
package main;
my $eg = MyApp::Example->new; # we have lift-off!!!
DESCRIPTION
This module (while experimental) encapsulates the exporting of keywords and routines. It applies the Validation::Class framework along with
any keyword routines and/or sub-routines specified with the apply_spec() method. It does this by simply by copying the spec into the
calling class.
To simplify writing exporter modules, "Validation::Class::Exporter" also imports "strict" and "warnings" into your exporter module, as well
as into modules that use it.
METHODS
apply_spec
When you call this method, "Validation::Class::Exporter" builds a custom "import" method on the calling class. The "import" method will
export the functions you specify, and can also automatically export "Validation::Class" making the calling class a Validation::Class
derived class.
This method accepts the following parameters:
o routines => [ ... ]
This list of function names only will be exported into the calling class exactly as is, the functions can be used traditionally or
as keywords so their parameter handling should be configured accordingly.
o settings => [ ... ]
This list of key/value pair will be passed to the load method imported from "Validation::Class::load" and will be applied on the
calling class.
This approach affords you some trickery in that you can utilize the load method to apply the current class' configuration to the
calling class' configuration, etc.
AUTHOR
Al Newkirk <anewkirk@ana.io>
COPYRIGHT AND LICENSE
This software is copyright (c) 2011 by Al Newkirk.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
perl v5.14.2 2012-06-28 Validation::Class::Exporter(3pm)