1 # Automatically generated sample implementation code
2 # PLEASE EDIT PLEASE EDIT PLEASE EDIT.
3 # Generated on Sat Nov 20 23:40:13 1999 by idl2perl 2.1 with command:
4 # /usr/bin/idl2perl -o . -imp /home/ruff/xmlBlaster/src/idl/xmlBlaster.idl
5
6 use clientIdl::BlasterCallback_types;
7 use clientIdl::BlasterCallback_skel;
8
9 # interface clientIdl::BlasterCallback (IDL:org.xmlBlaster/clientIdl/BlasterCallback:1.0)
10
11 package clientIdl::BlasterCallback_impl;
12 use COPE::CORBA::Servant;
13 @clientIdl::BlasterCallback_impl::ISA=qw(CORBA::BOA::_Servant);
14 sub _skelname($) { 'clientIdl::BlasterCallback_skel' }
15
16 use COPE::CORBA::Exception;
17 use Experimental::Exception;
18
19 use vars '%ones';
20 # operation update (IDL:org.xmlBlaster/clientIdl/BlasterCallback/update:1.0)
21
22 sub new {
23 my($class, $oid) = @_;
24
25 # Rather than creating a new object, just create a
26 # CORBA object reference (IOR)
27 my $ior = $CORBA::BOA::_The_Boa->create_reference_with_id($oid, $class->_interface);
28
29 # Put the object data in our "database"
30 # Note that we don't save the IOR; we can recreate it any time from
31 # the oid
32 $ones{$oid} = 1;
33
34 # and return the object reference
35 return $ior;
36 }
37
38 sub GetId ($) {
39 my($self) = @_;
40
41 # Extract the object ID from the call
42 my $oid = $CORBA::BOA::_The_Boa->servant_to_id($self);
43
44 # If this was a real application, we could use $oid to look up
45 # the object info in our database
46
47 # Another client might have deleted the object from the database...
48 if (!exists($ones{$oid})) {
49 throw new CORBA::OBJECT_NOT_EXIST minor => 0, completed=> Corba::CompletionStatus::COMPLETED_NO;
50 }
51
52 return $oid;
53 }
54
55 sub update ($$$) {
56 print "*********** INVOKED UPDATE ***********\n";
57 my($self,$msgUnitArr) = @_;
58 print "*********** INVOKED UPDATE ***********\n";
59 }
60
61 sub init() {
62 my $default = bless {}, 'clientIdl::BlasterCallback_impl';
63 $CORBA::BOA::_The_Boa->activate_object($default);
64 $CORBA::BOA::_The_Boa->set_servant($default->_interface, $default);
65 }
66
67 1;
syntax highlighted by Code2HTML, v. 0.9.1