Help with the SRX MAG Encoder (Java)

Hey guys, I have a question regarding the SRX MAG Encoder. How would one see the readings of the encoder in the code, and what measurement does the code output in.

I am trying to have the code read the measurements, and then act autonomously when going certain distances based on the revolutions. So, any sample code in Java would be much appreciated.

Thanks a latte.

I have not used them personally, but I believe there are programming examples provided by CTRE here:

You probably already know, but you need to install the Phoenix libraries this year, in addition to the wpilib plugins to be able to talk to the Talon SRX over CAN.