Following is the sample code for how to unformatting binary message into the JavaBean Person.
public static void main(String[] args) throws Exception { //Read btt.xml from the default package in class-path InitManager.reset("jar:///btt.xml"); //Create a instance of Person, left the field data blank Person person = new Person(); //Get the defined format element by id "PersonFormat" FormatElement format = FormatFactory.getFormatElement("PersonFormat"); //Create a WriteAdapter for person WriteAdapter write = new JavaWriteAdapter(person); //Prepare binary message byte[] bytes = HexCodecUtil.decodeHex("06C785969987850400000012".toCharArray()); Message message = new Message(bytes); //Perform unformat procedure format.unformat(message, write);