summaryrefslogtreecommitdiff
path: root/libvxi11client/perlbits/Client.xs
diff options
context:
space:
mode:
authordaniel <danieruru@gmail.com>2013-01-17 18:01:30 +0900
committerdaniel <danieruru@gmail.com>2013-01-17 18:01:30 +0900
commit74d4fb6c3b452599e9fc40c2f7df683bb1cf16d6 (patch)
treefacd2a62c7b420332cc4c855b3a4e26034827c67 /libvxi11client/perlbits/Client.xs
parent44fa490c0a2bf5f85f914ed48c85db0d51afa875 (diff)
make module perlish (object methods)
Diffstat (limited to 'libvxi11client/perlbits/Client.xs')
-rw-r--r--libvxi11client/perlbits/Client.xs98
1 files changed, 66 insertions, 32 deletions
diff --git a/libvxi11client/perlbits/Client.xs b/libvxi11client/perlbits/Client.xs
index 3bd831f..2da6581 100644
--- a/libvxi11client/perlbits/Client.xs
+++ b/libvxi11client/perlbits/Client.xs
@@ -4,60 +4,86 @@
#include "ppport.h"
+#include "perlglue.h"
+
+typedef VXI11Context* VXI11__Client;
+
MODULE = VXI11::Client PACKAGE = VXI11::Client
PROTOTYPES: ENABLE
int
-abort()
+startinterruptserver()
CODE:
- RETVAL = vxi11_abort();
+ RETVAL = glue_start_interrupt_server();
OUTPUT:
RETVAL
+int
+stopinterruptserver()
+ CODE:
+ RETVAL = glue_stop_interrupt_server();
+ OUTPUT:
+ RETVAL
+
int
-clear(waitforlock)
+abort(context)
+ VXI11::Client context
+ CODE:
+ RETVAL = vxi11_abort(context);
+ OUTPUT:
+ RETVAL
+
+int
+clear(context,waitforlock)
+ VXI11::Client context
bool waitforlock
CODE:
- RETVAL = vxi11_clear(waitforlock);
+ RETVAL = vxi11_clear(context, waitforlock);
OUTPUT:
RETVAL
int
-close()
+close(context)
+ VXI11::Client context
CODE:
- RETVAL = vxi11_close();
+ RETVAL = vxi11_close(context);
OUTPUT:
RETVAL
int
-create_intr_chan()
+create_intr_chan(context)
+ VXI11::Client context
CODE:
- RETVAL = vxi11_create_intr_chan();
+ RETVAL = vxi11_create_intr_chan(context);
OUTPUT:
RETVAL
int
-destroy_intr_chan()
+destroy_intr_chan(context)
+ VXI11::Client context
CODE:
- RETVAL = vxi11_destroy_intr_chan();
+ RETVAL = vxi11_destroy_intr_chan(context);
OUTPUT:
RETVAL
int
-docmd(cmd, waitforlock)
+docmd(context, cmd, waitforlock)
+ VXI11::Client context
unsigned long cmd
bool waitforlock
CODE:
- RETVAL = vxi11_docmd();
+ RETVAL = vxi11_docmd(context, cmd, waitforlock);
OUTPUT:
RETVAL
int
-enable_srq(enable)
+enable_srq(context, enable, handle)
+ VXI11::Client context
bool enable
+ char* handle
CODE:
- RETVAL = glue_enable_srq(enable);
+ RETVAL = vxi11_enable_srq(context,enable,handle);
OUTPUT:
RETVAL
@@ -70,80 +96,88 @@ wait_for_interrupt()
int
-local(waitforlock)
+local(context, waitforlock)
+ VXI11::Client context
bool waitforlock
CODE:
- RETVAL = vxi11_local(waitforlock);
+ RETVAL = vxi11_local(context, waitforlock);
OUTPUT:
RETVAL
int
-lock(waitforlock)
+lock(context, waitforlock)
+ VXI11::Client context
bool waitforlock
CODE:
- RETVAL = vxi11_lock(waitforlock);
+ RETVAL = vxi11_lock(context, waitforlock);
OUTPUT:
RETVAL
-int
+VXI11::Client
open(address, device)
char * address
char * device
CODE:
- RETVAL = vxi11_open(address, device);
+ RETVAL = glue_open(address, device);
OUTPUT:
RETVAL
int
-read(buffer, bufferlen, waitlock, termchrset, termchr)
+read(context, buffer, bufferlen, waitlock, termchrset, termchr)
+ VXI11::Client context
char * buffer
unsigned int bufferlen
bool waitlock
bool termchrset
char termchr
CODE:
- RETVAL = vxi11_read(buffer, bufferlen, waitlock, termchrset, termchr);
+ RETVAL = vxi11_read(context, buffer, bufferlen, waitlock, termchrset, termchr);
OUTPUT:
RETVAL
int
-readstatusbyte(waitforlock)
+readstatusbyte(context, waitforlock)
+ VXI11::Client context
bool waitforlock
CODE:
- RETVAL = vxi11_readstatusbyte();
+ RETVAL = vxi11_readstatusbyte(context, waitforlock);
OUTPUT:
RETVAL
int
-remote(waitforlock)
+remote(context, waitforlock)
+ VXI11::Client context
bool waitforlock
CODE:
- RETVAL = vxi11_remote();
+ RETVAL = vxi11_remote(context, waitforlock);
OUTPUT:
RETVAL
int
-trigger(waitforlock)
+trigger(context, waitforlock)
+ VXI11::Client context
bool waitforlock
CODE:
- RETVAL = vxi11_trigger();
+ RETVAL = vxi11_trigger(context, waitforlock);
OUTPUT:
RETVAL
int
-unlock()
+unlock(context)
+ VXI11::Client context
CODE:
- RETVAL = vxi11_unlock();
+ RETVAL = vxi11_unlock(context);
OUTPUT:
RETVAL
int
-write(data, len, waitlock, end)
+write(context,data, len, waitlock, end)
+ VXI11::Client context
char * data
unsigned int len
bool waitlock
bool end
CODE:
- RETVAL = vxi11_write(data, len, waitlock, end);
+ RETVAL = vxi11_write(context, data, len, waitlock, end);
OUTPUT:
RETVAL