Posted: Wed Sep 06, 2006 8:31 am Post subject: Parsing a MQ String message
Newbie
Joined: 06 Sep 2006 Posts: 2
Hi,
I am using the MQ base java api
I currently receive a message with the following string format:
12668800000022222876Y789YHDHDHDHY77778878877
I know the fixed field lengths for each segment of the message.
Is there a why to bind my message to my java objects? By passing in a descriptor file or something? I know I can get the message as a string and then parse it using java but I am trying to find something a bit more managable
Once you get the bytes from the message, you are left with "how do I marshall and unmarshall a Java object".
That is, there's nothing unique about MQ in your question. It's just like if you stored the same data as a single column in a database, and fetched it back again.
You might look at SDOs, or consider using XML instead of a fixed width structure. _________________ I am *not* the model of the modern major general.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum