12-10-2009
Ohhhhhh, thank you very much. You have really understood my problem. I didnīt know if i had explained very well. My english isnīt very good.
Anyway, i am studying a C++ Reflection Library (
XCppRefl - C++ Reflection Library), maybe it could serve me.
Sincerely, thank you very much.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
can I call a function in bash script just as in C++
while
do
function()
done
function()
thanks,
Steffen (3 Replies)
Discussion started by: forever_49ers
3 Replies
2. Programming
Hi, Can anyone help me figure out the problem I'm having with a function call?
I have a header file, which sets an enum:
typedef enum {INFO, WARNING, FATAL} Levels;
int log_event (Levels, char *fmt, ...);
..then the function is called this way:
log_event(INFO, "Message text");
... (6 Replies)
Discussion started by: Stevhp
6 Replies
3. Shell Programming and Scripting
I have a function check_ok in my abc.sh. which return me 1 or 0 . I want to call this fuction through other shell script. this shell also send two parameter to calling function.
Can you please tell me how. I am very new in unix.
#!/bin/bash
date_equal()
{
sqlplus -silent... (4 Replies)
Discussion started by: Jamil Qadir
4 Replies
4. Shell Programming and Scripting
hello,
when i call function inside awk traitement it doesn't work, i don't have error execution but i don't get result and if i call the function outside awk traitement it work well..
there's something special in awk call function??
here is the example :
awk -F "," '{ {first=$1; sec=$2;... (3 Replies)
Discussion started by: kamel.seg
3 Replies
5. Shell Programming and Scripting
How we can start a process if doesn't exists before? (1 Reply)
Discussion started by: Zaxon
1 Replies
6. Infrastructure Monitoring
Hello,
I have a problem with package and name space.
require "/Mehran/DSGateEngineLib/general.pl";
use strict;
sub System_Status_Main_Service_Status_Intrusion_Prevention
{
my %idpstatus;
my @result;
&General_ReadHash("/var/dsg/idp/settings",\%idpstatus);
#print... (4 Replies)
Discussion started by: Zaxon
4 Replies
7. Shell Programming and Scripting
Hi foiks
i am unable to find what is wrong in my code
mu functionality is to exit from shell when i give 99 but it is not calling function ext
Could you please correct me.
read option
if ;
then
ext
else
echo "out"
fi
function ext
{
echo "tested 99 and exit... (12 Replies)
Discussion started by: kojo
12 Replies
8. Shell Programming and Scripting
Below is my script that is function properly per my conditions but I am facing one problem here that is when one function fails then Iy should not check other functions but it calls the other function too So anyone can help me how could i achieve this?
iNOUT i AM GIVING TO THE... (1 Reply)
Discussion started by: rohit22hamirpur
1 Replies
9. Shell Programming and Scripting
Hi all,
Does anyone know if it possible to append a parameter to a function name?
Something like the following:
function tnsrec_${SERVICE_NAME} {
code..
}
Any ideas? (6 Replies)
Discussion started by: jonnyd
6 Replies
10. Homework & Coursework Questions
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
1. The problem statement, all variables and given/known data:
2. Relevant commands, code, scripts, algorithms:
#! /bin/ksh
v="ORG_ID"
... (2 Replies)
Discussion started by: sujitdas2104
2 Replies
LEARN ABOUT DEBIAN
class::trait::reflection
Class::Trait::Reflection(3pm) User Contributed Perl Documentation Class::Trait::Reflection(3pm)
NAME
Class::Trait::Reflection - Reflection class used to find information about classes which use Traits.
SYNOPSIS
The Class::Trait::Reflection class used to find information about classes which use Traits.
DESCRIPTION
This class is to be used by other applications as a foundation from which to build various trait compostion tools. It attempts to decouple
others from the internal representation of traits (currently the Class::Trait::Config object) and provide a more abstract view of them.
METHODS
constructor
new If given either a Class::Trait::Config object, a blessed perl object which uses traits or a valid perl package name which uses traits.
This constructor will return a valid Class::Trait::Reflection object which can be used to examine the specific properties of the traits
utilized.
accessors
getName
Returns the name string for the trait.
getSubTraitList
Returns an array or an array ref in scalar context) of string names of all the sub-traits the trait includes.
getRequirements
Returns an array (or an array ref in scalar context) of method labels and operators which represent the requirements for the given
trait.
getMethods
Returns an hash ref of method label strings to method subroutine references.
getMethodLabels
Returns an array (or an array ref in scalar context) of method label strings.
getConflicts
Returns an array (or an array ref in scalar context) of method labels and operators which are in conflict for a given trait. This is
only applicable for COMPOSITE traits.
getOverloads
Returns an hash ref of operators to method label strings.
getOperators
Returns an array (or an array ref in scalar context) of all the operators for a given trait.
Utility methods
loadSubTraitByName
Given a trait name, this method attempts to load the trait using the Class::Trait module, and then uses that trait to construct a new
Class::Trait::Reflection object to examine the trait with. This can function both as a class method and an instance method.
getTraitDump
Returns a Data::Dumper string of the internals of a Class::Trait::Config object.
traverse
Given a subroutine reference, this method can be used to traverse a trait heirarchy. The subroutine reference needs to take two
parameters, the first is the current trait being examined, the second is the number representing the depth within the trait heirarchy.
Here is an example of printing out the trait heirarchy as tabbed in names:
my $reflected_trait = Class::Trait::Reflection->new($object_or_package);
$reflected_trait->traverse(sub {
my ($trait, $depth) = @_;
print((" " x $depth), $trait->getName(), "
");
});
This should produce output similar to this:
COMPOSITE
TCircle
TMagnitude
TEquality
TGeometry
TColor
TEquality
Note: COMPOSITE is the placeholder name for an unnamed composite trait such as the one found in a class.
SEE ALSO
Class::Trait, Class::Trait::Config
AUTHOR
Stevan Little <stevan@iinteractive.com>
COPYRIGHT AND LICENSE
Copyright 2004, 2005 by Infinity Interactive, Inc.
<http://www.iinteractive.com>
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.10.0 2010-04-25 Class::Trait::Reflection(3pm)