Module: R2CORBA::PortableServer::POA
- Defined in:
- lib/corba/jbase/poa.rb,
lib/corba/jbase/policies.rb
Instance Method Summary collapse
-
#activate_object(p_servant) ⇒ Object
of attribute get_the_children.
-
#activate_object_with_id(r_id, p_servant) ⇒ Object
of operation activate_object.
-
#create_id_assignment_policy(value) ⇒ Object
of operation create_id_uniqueness_policy.
-
#create_id_uniqueness_policy(value) ⇒ Object
of operation create_lifespan_policy.
-
#create_implicit_activation_policy(value) ⇒ Object
of operation create_id_assignment_policy.
-
#create_lifespan_policy(value) ⇒ Object
of operation create_thread_policy.
-
#create_POA(adapter_name, a_POAManager, policies) ⇒ Object
of operation id_to_reference.
-
#create_reference(intf) ⇒ Object
of operation deactivate_object.
-
#create_reference_with_id(oid, intf) ⇒ Object
of operation create_reference.
-
#create_request_processing_policy(value) ⇒ Object
of operation create_servant_retention_policy.
-
#create_servant_retention_policy(value) ⇒ Object
of operation create_implicit_activation_policy.
- #create_thread_policy(value) ⇒ Object
-
#deactivate_object(oid) ⇒ Object
of operation activate_object_with_id.
- #destroy(etherealize_objects, wait_for_completion) ⇒ Object
-
#find_POA(adapter_name, activate_it) ⇒ Object
of operation create_POA.
-
#id_to_reference(oid) ⇒ Object
of operation id_to_servant.
-
#id_to_servant(oid) ⇒ Object
of operation reference_to_id.
-
#reference_to_id(reference) ⇒ Object
of operation reference_to_servant.
-
#reference_to_servant(reference) ⇒ Object
of operation servant_to_reference.
-
#servant_to_id(p_servant) ⇒ Object
of operation create_reference_with_id.
-
#servant_to_reference(p_servant) ⇒ Object
of operation servant_to_id.
-
#the_children ⇒ Object
of attribute get_the_parent.
-
#the_name ⇒ Object
of operation destroy.
-
#the_parent ⇒ Object
of attribute get_the_POAManager.
-
#the_POAManager ⇒ Object
of attribute get_the_name.
Instance Method Details
#activate_object(p_servant) ⇒ Object
of attribute get_the_children
77 78 79 80 81 82 83 |
# File 'lib/corba/jbase/poa.rb', line 77 def activate_object(p_servant) begin String.from_java_bytes(self.objref_.activate_object(p_servant.srvref_)) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#activate_object_with_id(r_id, p_servant) ⇒ Object
of operation activate_object
85 86 87 88 89 90 91 |
# File 'lib/corba/jbase/poa.rb', line 85 def activate_object_with_id(r_id, p_servant) begin self.objref_.activate_object_with_id(r_id.to_s.to_java_bytes, p_servant.srvref_) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_id_assignment_policy(value) ⇒ Object
of operation create_id_uniqueness_policy
173 174 175 176 177 178 179 180 181 |
# File 'lib/corba/jbase/policies.rb', line 173 def create_id_assignment_policy(value) begin PortableServer::IdAssignmentPolicy._narrow( CORBA::Object._wrap_native( self.objref_.create_id_assignment_policy(PortableServer::Native::IdAssignmentPolicyValue.from_int(value)))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_id_uniqueness_policy(value) ⇒ Object
of operation create_lifespan_policy
163 164 165 166 167 168 169 170 171 |
# File 'lib/corba/jbase/policies.rb', line 163 def create_id_uniqueness_policy(value) begin PortableServer::IdUniquenessPolicy._narrow( CORBA::Object._wrap_native( self.objref_.create_id_uniqueness_policy(PortableServer::Native::IdUniquenessPolicyValue.from_int(value)))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_implicit_activation_policy(value) ⇒ Object
of operation create_id_assignment_policy
183 184 185 186 187 188 189 190 191 |
# File 'lib/corba/jbase/policies.rb', line 183 def create_implicit_activation_policy(value) begin PortableServer::ImplicitActivationPolicy._narrow( CORBA::Object._wrap_native( self.objref_.create_implicit_activation_policy(PortableServer::Native::ImplicitActivationPolicyValue.from_int(value)))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_lifespan_policy(value) ⇒ Object
of operation create_thread_policy
153 154 155 156 157 158 159 160 161 |
# File 'lib/corba/jbase/policies.rb', line 153 def create_lifespan_policy(value) begin PortableServer::LifespanPolicy._narrow( CORBA::Object._wrap_native( self.objref_.create_lifespan_policy(PortableServer::Native::LifespanPolicyValue.from_int(value)))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_POA(adapter_name, a_POAManager, policies) ⇒ Object
of operation id_to_reference
165 166 167 168 169 170 171 172 173 174 175 176 |
# File 'lib/corba/jbase/poa.rb', line 165 def create_POA(adapter_name, a_POAManager, policies) raise CORBA::BAD_PARAM.new('expected POAManager', 0, CORBA::COMPLETED_NO) unless a_POAManager.is_a?(PortableServer::POAManager) CORBA::PolicyList._tc.validate(policies) unless policies.nil? || policies.empty? jpolicies = CORBA::Native::Reflect::Array.newInstance(CORBA::Native::Policy.java_class, policies.nil? ? 0 : policies.size) policies.each_with_index { |p, i| jpolicies[i] = p.objref_ } unless policies.nil? begin PortableServer::POA._narrow(CORBA::Object._wrap_native(self.objref_.create_POA(adapter_name, a_POAManager.objref_, jpolicies))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_reference(intf) ⇒ Object
of operation deactivate_object
101 102 103 104 105 106 107 |
# File 'lib/corba/jbase/poa.rb', line 101 def create_reference(intf) begin CORBA::Object._wrap_native(self.objref_.create_reference(intf.to_s)) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_reference_with_id(oid, intf) ⇒ Object
of operation create_reference
109 110 111 112 113 114 115 |
# File 'lib/corba/jbase/poa.rb', line 109 def create_reference_with_id(oid, intf) begin CORBA::Object._wrap_native(self.objref_.create_reference_with_id(oid.to_s.to_java_bytes, intf.to_s)) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_request_processing_policy(value) ⇒ Object
of operation create_servant_retention_policy
203 204 205 206 207 208 209 210 211 |
# File 'lib/corba/jbase/policies.rb', line 203 def create_request_processing_policy(value) begin PortableServer::RequestProcessingPolicy._narrow( CORBA::Object._wrap_native( self.objref_.create_request_processing_policy(PortableServer::Native::RequestProcessingPolicyValue.from_int(value)))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_servant_retention_policy(value) ⇒ Object
of operation create_implicit_activation_policy
193 194 195 196 197 198 199 200 201 |
# File 'lib/corba/jbase/policies.rb', line 193 def create_servant_retention_policy(value) begin PortableServer::ServantRetentionPolicy._narrow( CORBA::Object._wrap_native( self.objref_.create_servant_retention_policy(PortableServer::Native::ServantRetentionPolicyValue.from_int(value)))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#create_thread_policy(value) ⇒ Object
143 144 145 146 147 148 149 150 151 |
# File 'lib/corba/jbase/policies.rb', line 143 def create_thread_policy(value) begin PortableServer::ThreadPolicy._narrow( CORBA::Object._wrap_native( self.objref_.create_thread_policy(PortableServer::Native::ThreadPolicyValue.from_int(value)))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#deactivate_object(oid) ⇒ Object
of operation activate_object_with_id
93 94 95 96 97 98 99 |
# File 'lib/corba/jbase/poa.rb', line 93 def deactivate_object(oid) begin self.objref_.deactivate_object(oid.to_s.to_java_bytes) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#destroy(etherealize_objects, wait_for_completion) ⇒ Object
37 38 39 40 41 42 43 |
# File 'lib/corba/jbase/poa.rb', line 37 def destroy(etherealize_objects, wait_for_completion) begin self.objref_.destroy(etherealize_objects != false, wait_for_completion != false) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#find_POA(adapter_name, activate_it) ⇒ Object
of operation create_POA
178 179 180 181 182 183 184 |
# File 'lib/corba/jbase/poa.rb', line 178 def find_POA(adapter_name, activate_it) begin PortableServer::POA._narrow(CORBA::Object._wrap_native(self.objref_.find_POA(adapter_name, activate_it))) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#id_to_reference(oid) ⇒ Object
of operation id_to_servant
157 158 159 160 161 162 163 |
# File 'lib/corba/jbase/poa.rb', line 157 def id_to_reference(oid) begin CORBA::Object._wrap_native(self.objref_.id_to_reference(oid.to_s.to_java_bytes)) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#id_to_servant(oid) ⇒ Object
of operation reference_to_id
149 150 151 152 153 154 155 |
# File 'lib/corba/jbase/poa.rb', line 149 def id_to_servant(oid) begin self.objref_.id_to_servant(oid.to_s.to_java_bytes).rbServant rescue ::NativeException CORBA::Exception.native2r($!) end end |
#reference_to_id(reference) ⇒ Object
of operation reference_to_servant
141 142 143 144 145 146 147 |
# File 'lib/corba/jbase/poa.rb', line 141 def reference_to_id(reference) begin String.from_java_bytes(self.objref_.reference_to_id(reference.objref_)) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#reference_to_servant(reference) ⇒ Object
of operation servant_to_reference
133 134 135 136 137 138 139 |
# File 'lib/corba/jbase/poa.rb', line 133 def reference_to_servant(reference) begin self.objref_.reference_to_servant(reference.objref_).rbServant rescue ::NativeException CORBA::Exception.native2r($!) end end |
#servant_to_id(p_servant) ⇒ Object
of operation create_reference_with_id
117 118 119 120 121 122 123 |
# File 'lib/corba/jbase/poa.rb', line 117 def servant_to_id(p_servant) begin String.from_java_bytes(self.objref_.servant_to_id(p_servant.srvref_)) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#servant_to_reference(p_servant) ⇒ Object
of operation servant_to_id
125 126 127 128 129 130 131 |
# File 'lib/corba/jbase/poa.rb', line 125 def servant_to_reference(p_servant) begin CORBA::Object._wrap_native(self.objref_.servant_to_reference(p_servant.srvref_)) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#the_children ⇒ Object
of attribute get_the_parent
69 70 71 72 73 74 75 |
# File 'lib/corba/jbase/poa.rb', line 69 def the_children begin self.objref_.the_children.collect { |c| PortableServer::POA._narrow(CORBA::Object._wrap_native(c)) } rescue ::NativeException CORBA::Exception.native2r($!) end end |
#the_name ⇒ Object
of operation destroy
45 46 47 48 49 50 51 |
# File 'lib/corba/jbase/poa.rb', line 45 def the_name begin self.objref_.the_name rescue ::NativeException CORBA::Exception.native2r($!) end end |
#the_parent ⇒ Object
of attribute get_the_POAManager
61 62 63 64 65 66 67 |
# File 'lib/corba/jbase/poa.rb', line 61 def the_parent begin PortableServer::POA._narrow(CORBA::Object._wrap_native(self.objref_.the_parent)) rescue ::NativeException CORBA::Exception.native2r($!) end end |
#the_POAManager ⇒ Object
of attribute get_the_name
53 54 55 56 57 58 59 |
# File 'lib/corba/jbase/poa.rb', line 53 def the_POAManager begin PortableServer::POAManager._narrow(CORBA::Object._wrap_native(self.objref_.the_POAManager)) rescue ::NativeException CORBA::Exception.native2r($!) end end |