Completed Class Protocol.as

Fixed the issue in function readn but it is yet to be tested. Missing
function implemented as readBytesAndReturn