ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » DFDL hex initiators

Post new topic  Reply to topic
 DFDL hex initiators « View previous topic :: View next topic » 
Author Message
msnyder
PostPosted: Thu May 10, 2012 5:21 am    Post subject: DFDL hex initiators Reply with quote

Apprentice

Joined: 24 May 2002
Posts: 32
Location: Jacksonville, FL

I have a situation where record types are identified by 2 byte little endian integers. The parser is not finding a choice branch when the initiator is specified as a hex value, e.g. dfdl:initiator="%#x0411;" for a record type of 1041. From the documentation, it seems this should be supported. Is this correct or do initiators have to be text in this version?
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu May 10, 2012 5:42 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Technically, the initiator property is a DFDL string literal. The DFDL entity "%#x0411;" is specifying a 'HexadecimalCodePoint' according to section 6.3.1.2 of the DFDL specification : http://www.ogf.org/dfdl/DFDL_1.0_Web/dfdl_6_3.html

But you do not want to specify a Unicode code point - you want to specify two raw bytes. To do that, you need two DFDL byte value entities, as specified in section 6.3.1.4. Like this:
Code:
"%#r11;%#r04;"
Back to top
View user's profile Send private message
msnyder
PostPosted: Thu May 10, 2012 5:45 am    Post subject: Reply with quote

Apprentice

Joined: 24 May 2002
Posts: 32
Location: Jacksonville, FL

Yes, I tried that but got an exception saying something to the effect that it is not supported in the IBM implementation.
Back to top
View user's profile Send private message
msnyder
PostPosted: Thu May 10, 2012 5:52 am    Post subject: Reply with quote

Apprentice

Joined: 24 May 2002
Posts: 32
Location: Jacksonville, FL

After further review, I tried it like
Code:
"%#r1104;"
and got the aforementioned exception. According to the spec, 1 or more pairs is acceptable. However, after separating into 2, the exception is no more but a branch is not found.
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu May 10, 2012 6:01 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
According to the spec, 1 or more pairs is acceptable.
I assume you are referring to this sentence: "To specify a string of byte values, a sequence of two or more byte value entities must be used."
I think it is trying to say that you need exactly one entity per raw byte. But the wording could be clearer.
Quote:
after separating into 2, the exception is no more...
OK - that's a relief.
Quote:
but a branch is not found
Have you looked at the DFDL trace yet? Any clues there?
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu May 10, 2012 6:11 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

I've just tried this out, and it works for me. Might be worth changing the order of the two %#r entities in case my attempt at a littleEndian integer was wrong.
Back to top
View user's profile Send private message
msnyder
PostPosted: Thu May 10, 2012 7:04 am    Post subject: Reply with quote

Apprentice

Joined: 24 May 2002
Posts: 32
Location: Jacksonville, FL

Yes I noticed that it was backwards. However, I had added another byte to the mix and miskeyed it. After changing, it worked like a charm. Thanks for your help.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » DFDL hex initiators
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.