/**
* Static method for writing a CORBA standard exception to an Any.
* @param any The Any to write the SystemException into.
*/
public static void insertSystemException(SystemException ex, Any any) {
OutputStream out = any.create_output_stream();
ORB orb = (ORB)(out.orb());
String name = ex.getClass().getName();
String repID = ORBUtility.repositoryIdOf(name);
out.write_string(repID);
out.write_long(ex.minor);
out.write_long(ex.completed.value());
any.read_value(out.create_input_stream(),
getSystemExceptionTypeCode(orb, repID, name));
}