本文整理汇总了Java中org.omg.CORBA.portable.ApplicationException.getInputStream方法的典型用法代码示例。如果您正苦于以下问题:Java ApplicationException.getInputStream方法的具体用法?Java ApplicationException.getInputStream怎么用?Java ApplicationException.getInputStream使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.omg.CORBA.portable.ApplicationException
的用法示例。
在下文中一共展示了ApplicationException.getInputStream方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: readException
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
public Exception readException( ApplicationException ae )
{
// Note that the exception ID is present in both ae
// and in the input stream from ae. The exception
// reader must actually read the exception ID from
// the stream.
InputStream is = (InputStream)ae.getInputStream() ;
String excName = ae.getId() ;
int index = findDeclaredException( excName ) ;
if (index < 0) {
excName = is.read_string() ;
Exception res = new UnexpectedException( excName ) ;
res.initCause( ae ) ;
return res ;
}
return rws[index].read( is ) ;
}
示例2: establish_components
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void establish_components(IORInfo info)
{
InputStream input = null;
try
{
OutputStream output = _request("establish_components", true);
output.write_Object(info);
input = _invoke(output);
}
catch (ApplicationException ex)
{
input = ex.getInputStream();
String id = ex.getId();
throw new MARSHAL(id);
}
catch (RemarshalException remarsh)
{
establish_components(info);
}
finally
{
_releaseReply(input);
}
}
示例3: destroy
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void destroy()
{
InputStream input = null;
try
{
OutputStream output = _request("destroy", true);
input = _invoke(output);
}
catch (ApplicationException ex)
{
input = ex.getInputStream();
String id = ex.getId();
throw new MARSHAL(id);
}
catch (RemarshalException remarsh)
{
destroy();
}
finally
{
_releaseReply(input);
}
}
示例4: destroy
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void destroy()
{
InputStream input = null;
try
{
OutputStream output = _request("destroy", true);
input = _invoke(output);
}
catch (ApplicationException ex)
{
input = ex.getInputStream();
String id = ex.getId();
throw new MARSHAL(id);
}
catch (RemarshalException remarsh)
{
destroy();
}
finally
{
_releaseReply(input);
}
}
示例5: destroy
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/**
* Destroy the remote IDL type object.
*/
public void destroy()
{
InputStream in = null;
try
{
OutputStream out = _request("destroy", true);
in = _invoke(out);
}
catch (ApplicationException ex)
{
in = ex.getInputStream();
throw new org.omg.CORBA.MARSHAL(ex.getId());
}
catch (RemarshalException rex)
{
destroy();
}
finally
{
_releaseReply(in);
}
}
示例6: components_established
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void components_established(IORInfo info)
{
InputStream input = null;
try
{
OutputStream output = _request("components_established", true);
output.write_Object(info);
input = _invoke(output);
}
catch (ApplicationException ex)
{
input = ex.getInputStream();
String id = ex.getId();
throw new MARSHAL(id);
}
catch (RemarshalException remarsh)
{
components_established(info);
}
finally
{
_releaseReply(input);
}
}
示例7: theField
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/**
* Set the field value.
*/
public void theField(int newTheField)
{
InputStream in = null;
try
{
// The special name of operation instructs just to set
// the field value rather than calling the method.
OutputStream out = _request("_set_theField", true);
out.write_long(newTheField);
in = _invoke(out);
}
catch (ApplicationException ex)
{
in = ex.getInputStream();
throw new MARSHAL(ex.getId());
}
catch (RemarshalException _rm)
{
theField(newTheField);
}
finally
{
_releaseReply(in);
}
}
示例8: new_context
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/** {@inheritDoc} */
public NamingContext new_context()
{
InputStream in = null;
try
{
OutputStream out = _request("new_context", true);
in = _invoke(out);
NamingContext __result = NamingContextHelper.read(in);
return __result;
}
catch (ApplicationException ex)
{
in = ex.getInputStream();
throw new MARSHAL(ex.getId());
}
catch (RemarshalException remarsh)
{
return new_context();
}
finally
{
_releaseReply(in);
}
}
示例9: def_kind
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/**
* Get the definition kind of the remote IDL type object. The method is
* written following OMG specification, treating the typecode
* as a read only attribute rather than a method. This means,
* the operation name is "_get_def_kind".
*
* @return a definition kind, returned by remote IDL type object.
*/
public DefinitionKind def_kind()
{
InputStream in = null;
try
{
OutputStream out = _request("_get_def_kind", true);
in = _invoke(out);
return DefinitionKindHelper.read(in);
}
catch (ApplicationException ex)
{
in = ex.getInputStream();
throw new org.omg.CORBA.MARSHAL(ex.getId());
}
catch (RemarshalException rex)
{
return def_kind();
}
finally
{
_releaseReply(in);
}
}
示例10: sayHello
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/**
* One way call of the remote method.
*/
public void sayHello()
{
InputStream in = null;
try
{
// As we do not expect any response, the second
// parameter is 'false'.
OutputStream out = _request("sayHello", false);
in = _invoke(out);
}
catch (ApplicationException ex)
{
in = ex.getInputStream();
throw new MARSHAL(ex.getId());
}
catch (RemarshalException _rm)
{
sayHello();
}
finally
{
_releaseReply(in);
}
}
示例11: rebind_context
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/** {@inheritDoc} */
public void rebind_context(NameComponent[] a_name, NamingContext a_context)
throws NotFound, CannotProceed, InvalidName
{
InputStream in = null;
try
{
OutputStream out = _request("rebind_context", true);
NameHelper.write(out, a_name);
NamingContextHelper.write(out, a_context);
in = _invoke(out);
}
catch (ApplicationException ex)
{
in = ex.getInputStream();
String id = ex.getId();
throw4(in, id);
}
catch (RemarshalException remarsh)
{
rebind_context(a_name, a_context);
}
finally
{
_releaseReply(in);
}
}
示例12: passStrings
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/**
Passes and returns the string sequence.
*/
public String[] passStrings(String[] arg)
{
InputStream in = null;
try
{
// Get the stream where the parameters must be written:
OutputStream out = _request("passStrings", true);
// Wrap the string array using the string sequence helper.
StringSeqHelper.write(out, arg);
// Invoke the method.
in = _invoke(out);
// Read the returned result using the string sequence helper.
String[] result = StringSeqHelper.read(in);
return result;
}
catch (ApplicationException ex)
{
// Handle the exception, thrown on remote side.
in = ex.getInputStream();
throw new MARSHAL(ex.getId());
}
catch (RemarshalException _rm)
{
return passStrings(arg);
}
finally
{
_releaseReply(in);
}
}
示例13: bind_new_context
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/** {@inheritDoc} */
public NamingContext bind_new_context(NameComponent[] a_name)
throws NotFound, AlreadyBound, CannotProceed,
InvalidName
{
InputStream in = null;
try
{
OutputStream out = _request("bind_new_context", true);
NameHelper.write(out, a_name);
in = _invoke(out);
NamingContext __result = NamingContextHelper.read(in);
return __result;
}
catch (ApplicationException ex)
{
in = ex.getInputStream();
String id = ex.getId();
throw5(in, id);
throw new InternalError();
}
catch (RemarshalException remarsh)
{
return bind_new_context(a_name);
}
finally
{
_releaseReply(in);
}
}
示例14: passTree
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/**
* Pass and return the tree structure
*/
public void passTree(TreeNodeHolder tree)
{
InputStream in = null;
try
{
// Get the stream where the parameters must be written.
OutputStream out = _request("passTree", true);
// Write the tree (TreeNode with its chilred, grandchildren and so on),
// using the appropriate helper.
TreeNodeHelper.write(out, tree.value);
// Call the method.
in = _invoke(out);
// Read the returned tree.
tree.value = TreeNodeHelper.read(in);
}
catch (ApplicationException ex)
{
// Handle eception on remote side.
in = ex.getInputStream();
throw new MARSHAL(ex.getId());
}
catch (RemarshalException _rm)
{
passTree(tree);
}
finally
{
_releaseReply(in);
}
}
示例15: name
import org.omg.CORBA.portable.ApplicationException; //导入方法依赖的package包/类
/** {@inheritDoc} */
public String name()
{
InputStream input = null;
try
{
OutputStream output = _request("name", true);
input = _invoke(output);
String returns = input.read_string();
return returns;
}
catch (ApplicationException ex)
{
input = ex.getInputStream();
String id = ex.getId();
throw new MARSHAL(id);
}
catch (RemarshalException remarsh)
{
return name();
}
finally
{
_releaseReply(input);
}
}