Re: Fabric-sdk-jAVA #fabric-sdk-java

Mark Lewis

The BlockEvent itself has lots of helpful accessor methods to help you navigate to useful data within the block, so you should probably prefer those if they do what you need. getBlock() returns the Block protobuf message, which is defined in the Fabric protocol buffer definitions:

The overall structure is quite complex, containing nested serialized protobuf messages. The Block object itself is a Java stub built from the protobuf definitions and contains methods to access data, so there is no need to "decode" it -- that has already been done. The protocol buffer documentation describes how the stubs packaged in fabric-sdk-java relate to the protocol buffer definitions and the API they provide:

Join to automatically receive all group messages.