Fixed type checking on explicit type read in c++. Added explicit type read to java libs