]>
git.saurik.com Git - wxWidgets.git/blob - wxPython/wxSWIG/Modules/perl5.h
   1 /**************************************************************************** 
   2  * Simplified Wrapper and Interface Generator  (SWIG) 
   4  * Author : David Beazley 
   6  * Department of Computer Science         
   7  * University of Chicago 
  10  * beazley@cs.uchicago.edu 
  12  * Please read the file LICENSE for the copyright and terms by which SWIG 
  13  * can be used and distributed. 
  14  ****************************************************************************/ 
  16 /************************************************************************** 
  19  * A Perl 5 implementation 
  20  **************************************************************************/ 
  22 class PERL5 
: public Language 
{ 
  30   String  pm
;                      // Package initialization code 
  31   String  magic
;                   // Magic variable wrappers 
  35   void   get_pointer(char *iname
, char *srcname
, char *src
, char *dest
, 
  36                         DataType 
*t
, String 
&f
, char *ret
); 
  37   char     *usage_var(char *, DataType 
*); 
  38   char     *usage_func(char *, DataType 
*, ParmList 
*); 
  39   char     *usage_const(char *, DataType 
*, char *); 
  43 // The following variables are used to manage Perl5 classes 
  45   int      blessed
;                // Enable object oriented features 
  46   Hash     classes
;                // A hash table for storing the classes we've seen so far 
  49   int      have_data_members
; 
  50   char     *class_name
;            // Name of the class (what Perl thinks it is) 
  51   char     *class_type
;            // Type of class "struct", "class", "union" 
  52   char     *real_classname
;        // Real name of C/C++ class 
  53   String   
*base_class
;            // Base class (if using inheritance) 
  54   String   
*pcode
;                 // Perl code associated with each class 
  55   String   
*blessedmembers
;        // Member data associated with each class 
  56   int      member_func
;            // Set to 1 when wrapping a member function 
  57   char     *realpackage
;           // Name of real module  
  58   String   func_stubs
;             // Function stubs 
  59   String   var_stubs
;              // Variable stubs 
  60   String   
*member_keys
;            // Keys for all member data 
  61   String   exported
;               // Exported symbols 
  73   void parse_args(int, char *argv
[]); 
  75   void create_function(char *, char *, DataType 
*, ParmList 
*); 
  76   void link_variable(char *, char *, DataType 
*); 
  77   void declare_const(char *, char *, DataType 
*, char *); 
  78   void initialize(void); 
  81   void set_module(char *, char **); 
  82   void set_init(char *); 
  83   void add_native(char *, char *); 
  84   void create_command(char *, char *); 
  85   char *type_mangle(DataType 
*); 
  87   // Support for blessed perl thingies.... 
  89   void cpp_open_class(char *classname
, char *rename
, char *ctype
, int strip
); 
  90   void cpp_close_class(); 
  91   void cpp_member_func(char *name
, char *iname
, DataType 
*t
, ParmList 
*l
); 
  92   void cpp_static_func(char *name
, char *iname
, DataType 
*t
, ParmList 
*l
); 
  93   void cpp_variable(char *name
, char *iname
, DataType 
*t
); 
  94   void cpp_constructor(char *name
, char *iname
, ParmList 
*l
); 
  95   void cpp_destructor(char *name
, char *newname
); 
  96   void cpp_inherit(char **baseclass
, int mode 
= INHERIT_ALL
); 
  97   void cpp_declare_const(char *name
, char *iname
, DataType 
*type
, char *value
); 
  98   void cpp_class_decl(char *, char *, char *); 
  99   void add_typedef(DataType 
*t
, char *name
); 
 100   void pragma(char *, char *, char *); 
 101   void import(char *filename
);