1. /*
  2. * @(#)ProxyInputStream.java 1.3 04/01/26
  3. *
  4. * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package com.sun.jmx.remote.internal;
  8. import java.io.IOException;
  9. import java.io.Serializable;
  10. import java.math.BigDecimal;
  11. import org.omg.CORBA.Any;
  12. import org.omg.CORBA.Context;
  13. import org.omg.CORBA.NO_IMPLEMENT;
  14. import org.omg.CORBA.ORB;
  15. import org.omg.CORBA.Principal;
  16. import org.omg.CORBA.TypeCode;
  17. import org.omg.CORBA.portable.BoxedValueHelper;
  18. import org.omg.CORBA_2_3.portable.InputStream;
  19. public class ProxyInputStream extends org.omg.CORBA_2_3.portable.InputStream {
  20. public ProxyInputStream(org.omg.CORBA.portable.InputStream in) {
  21. this.in = in;
  22. }
  23. public boolean read_boolean() {
  24. return in.read_boolean();
  25. }
  26. public char read_char() {
  27. return in.read_char();
  28. }
  29. public char read_wchar() {
  30. return in.read_wchar();
  31. }
  32. public byte read_octet() {
  33. return in.read_octet();
  34. }
  35. public short read_short() {
  36. return in.read_short();
  37. }
  38. public short read_ushort() {
  39. return in.read_ushort();
  40. }
  41. public int read_long() {
  42. return in.read_long();
  43. }
  44. public int read_ulong() {
  45. return in.read_ulong();
  46. }
  47. public long read_longlong() {
  48. return in.read_longlong();
  49. }
  50. public long read_ulonglong() {
  51. return in.read_ulonglong();
  52. }
  53. public float read_float() {
  54. return in.read_float();
  55. }
  56. public double read_double() {
  57. return in.read_double();
  58. }
  59. public String read_string() {
  60. return in.read_string();
  61. }
  62. public String read_wstring() {
  63. return in.read_wstring();
  64. }
  65. public void read_boolean_array(boolean[] value, int offset, int length) {
  66. in.read_boolean_array(value, offset, length);
  67. }
  68. public void read_char_array(char[] value, int offset, int length) {
  69. in.read_char_array(value, offset, length);
  70. }
  71. public void read_wchar_array(char[] value, int offset, int length) {
  72. in.read_wchar_array(value, offset, length);
  73. }
  74. public void read_octet_array(byte[] value, int offset, int length) {
  75. in.read_octet_array(value, offset, length);
  76. }
  77. public void read_short_array(short[] value, int offset, int length) {
  78. in.read_short_array(value, offset, length);
  79. }
  80. public void read_ushort_array(short[] value, int offset, int length) {
  81. in.read_ushort_array(value, offset, length);
  82. }
  83. public void read_long_array(int[] value, int offset, int length) {
  84. in.read_long_array(value, offset, length);
  85. }
  86. public void read_ulong_array(int[] value, int offset, int length) {
  87. in.read_ulong_array(value, offset, length);
  88. }
  89. public void read_longlong_array(long[] value, int offset, int length) {
  90. in.read_longlong_array(value, offset, length);
  91. }
  92. public void read_ulonglong_array(long[] value, int offset, int length) {
  93. in.read_ulonglong_array(value, offset, length);
  94. }
  95. public void read_float_array(float[] value, int offset, int length) {
  96. in.read_float_array(value, offset, length);
  97. }
  98. public void read_double_array(double[] value, int offset, int length) {
  99. in.read_double_array(value, offset, length);
  100. }
  101. public org.omg.CORBA.Object read_Object() {
  102. return in.read_Object();
  103. }
  104. public TypeCode read_TypeCode() {
  105. return in.read_TypeCode();
  106. }
  107. public Any read_any() {
  108. return in.read_any();
  109. }
  110. public Principal read_Principal() {
  111. return in.read_Principal();
  112. }
  113. public int read() throws IOException {
  114. return in.read();
  115. }
  116. public BigDecimal read_fixed() {
  117. return in.read_fixed();
  118. }
  119. public Context read_Context() {
  120. return in.read_Context();
  121. }
  122. public org.omg.CORBA.Object read_Object(java.lang.Class clz) {
  123. return in.read_Object(clz);
  124. }
  125. public ORB orb() {
  126. return in.orb();
  127. }
  128. public Serializable read_value() {
  129. return narrow().read_value();
  130. }
  131. public Serializable read_value(Class clz) {
  132. return narrow().read_value(clz);
  133. }
  134. public Serializable read_value(BoxedValueHelper factory) {
  135. return narrow().read_value(factory);
  136. }
  137. public Serializable read_value(String rep_id) {
  138. return narrow().read_value(rep_id);
  139. }
  140. public Serializable read_value(Serializable value) {
  141. return narrow().read_value(value);
  142. }
  143. public Object read_abstract_interface() {
  144. return narrow().read_abstract_interface();
  145. }
  146. public Object read_abstract_interface(Class clz) {
  147. return narrow().read_abstract_interface(clz);
  148. }
  149. protected org.omg.CORBA_2_3.portable.InputStream narrow() {
  150. if (in instanceof org.omg.CORBA_2_3.portable.InputStream)
  151. return (org.omg.CORBA_2_3.portable.InputStream) in;
  152. throw new NO_IMPLEMENT();
  153. }
  154. public org.omg.CORBA.portable.InputStream getProxiedInputStream() {
  155. return in;
  156. }
  157. protected final org.omg.CORBA.portable.InputStream in;
  158. }