public final boolean isWriteTypeInfo(Object object) {
        long features = context.features;
        if ((features & WriteClassName.mask) == 0) {
            return false;
        }

        if ((features & NotWriteHashMapArrayListClassName.mask) != 0
                && object != null) {
            Class objectClass = object.getClass();
            if (objectClass == HashMap.class || objectClass == ArrayList.class) {
                return false;
            }
        }

        return (features & NotWriteRootClassName.mask) == 0
                || object != this.rootObject;
    }
If ReferenceDetection has been set, returns the path of the current object, otherwise returns null
@since 2.0.51
@return the path of the current object
core/src/main/java/com/alibaba/fastjson2/JSONWriter.java