private < T > FakeEncodedItem readNextItem ( Class < T > clazz ) { FakeEncodedItem item = data [ dataPosition ] ; if ( item == null ) { // While Parcel will treat these as zeros, in tests, this is almost always an error. throw new UnreliableBehaviorError ( "Reading uninitialized data at position " + dataPosition ) ; } checkConsistentReadAndIncrementPosition ( clazz , item ) ; return item ; }
Reads a complete item in the byte buffer .