I'm looking to create a Java class using IDL, that is then converted to CDR, and then access its CDR representation as a series of bytes. However, I'm not looking to implement an ORB, just the CDR functionality in the data streams. E.g. I see there is org.omg.CORBA.portable.OutputStream (no way to access the data that I can see though, so it seems the CDR goodness is hidden) and com.sun.corba.se.impl.encoding.CDROutputStream (but this requires a non-null ORB to intialize it even though there is a "toByteArray" method).
Does anyone know any way to do this?