The Encoder class is for a quadrature encoder, which is why it uses two DIO ports (not PWM). The encoder you linked needs to be connected to an analog input. Its output voltage is proportional to the angle.
Here is some psuedo-Java that could be used to get an angle:
Code:
AnalogInput encoder = new AnalogEncoder(0);
double angle = (encoder.getVoltage() / 5.0) * 360.0;
You could also try looking at AnalogPotentiometer, which can do the scaling for you.