01: package org.cougaar.qos.ResourceStatus;
02:
03: /**
04: * org/cougaar/qos/ResourceStatus/QualifierHelper.java .
05: * Generated by the IDL-to-Java compiler (portable), version "3.2"
06: * from qrs.idl
07: * Tuesday, August 7, 2007 11:57:30 AM EDT
08: */
09:
10: abstract public class QualifierHelper {
11: private static String _id = "IDL:org/cougaar/qos/ResourceStatus/Qualifier:1.0";
12:
13: public static void insert(org.omg.CORBA.Any a,
14: org.cougaar.qos.ResourceStatus.Qualifier that) {
15: org.omg.CORBA.portable.OutputStream out = a
16: .create_output_stream();
17: a.type(type());
18: write(out, that);
19: a.read_value(out.create_input_stream(), type());
20: }
21:
22: public static org.cougaar.qos.ResourceStatus.Qualifier extract(
23: org.omg.CORBA.Any a) {
24: return read(a.create_input_stream());
25: }
26:
27: private static org.omg.CORBA.TypeCode __typeCode = null;
28:
29: synchronized public static org.omg.CORBA.TypeCode type() {
30: if (__typeCode == null) {
31: __typeCode = org.omg.CORBA.ORB
32: .init()
33: .create_interface_tc(
34: org.cougaar.qos.ResourceStatus.QualifierHelper
35: .id(), "Qualifier");
36: }
37: return __typeCode;
38: }
39:
40: public static String id() {
41: return _id;
42: }
43:
44: public static org.cougaar.qos.ResourceStatus.Qualifier read(
45: org.omg.CORBA.portable.InputStream istream) {
46: return narrow(istream.read_Object(_QualifierStub.class));
47: }
48:
49: public static void write(
50: org.omg.CORBA.portable.OutputStream ostream,
51: org.cougaar.qos.ResourceStatus.Qualifier value) {
52: ostream.write_Object((org.omg.CORBA.Object) value);
53: }
54:
55: public static org.cougaar.qos.ResourceStatus.Qualifier narrow(
56: org.omg.CORBA.Object obj) {
57: if (obj == null)
58: return null;
59: else if (obj instanceof org.cougaar.qos.ResourceStatus.Qualifier)
60: return (org.cougaar.qos.ResourceStatus.Qualifier) obj;
61: else if (!obj._is_a(id()))
62: throw new org.omg.CORBA.BAD_PARAM();
63: else {
64: org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl) obj)
65: ._get_delegate();
66: org.cougaar.qos.ResourceStatus._QualifierStub stub = new org.cougaar.qos.ResourceStatus._QualifierStub();
67: stub._set_delegate(delegate);
68: return stub;
69: }
70: }
71:
72: public static org.cougaar.qos.ResourceStatus.Qualifier unchecked_narrow(
73: org.omg.CORBA.Object obj) {
74: if (obj == null)
75: return null;
76: else if (obj instanceof org.cougaar.qos.ResourceStatus.Qualifier)
77: return (org.cougaar.qos.ResourceStatus.Qualifier) obj;
78: else {
79: org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl) obj)
80: ._get_delegate();
81: org.cougaar.qos.ResourceStatus._QualifierStub stub = new org.cougaar.qos.ResourceStatus._QualifierStub();
82: stub._set_delegate(delegate);
83: return stub;
84: }
85: }
86:
87: }
|