code: private Class<?> readNewClass(boolean unshared) throws ClassNotFoundException, IOException {
          ObjectStreamClass classDesc = readClassDesc();
          if (classDesc == null) {
              throw missingClassDescriptor();
          }
          Class<?> localClass = classDesc.forClass();
          if (localClass != null) {
              registerObjectRead(localClass, nextHandle(), unshared);
          }
          return localClass;
      }
docs: Reads a new class from the receiver. It is assumed the class has not been
  read yet (not a cyclic reference). Return the class read.
  
  @param unshared
  read the object unshared
  @return The {@code java.lang.Class} read from the stream.
  
  @throws IOException
  If an IO exception happened when reading the class.
  @throws ClassNotFoundException
  If a class for one of the objects could not be found