以下两个扩展函数实现的功能有什么区别?

DUtil = {};
DUtil.extend = function (destination, source) {
    destination = destination || {};
    if (source) {
        for (var property in source) {
            var value = source[property];
            if (value !== undefined) {
                destination[property] = value;
            }
        }
        var sourceIsEvt = typeof window.Event == "function" && source instanceof window.Event;
        if (!sourceIsEvt && source.hasOwnProperty && source.hasOwnProperty('toString')) {
            destination.toString = source.toString;
        }
    }
    return destination;
};

DObject = function () {
    var Class = function () {
        if (arguments && arguments[0] != null) {
            this.construct.apply(this, arguments);
        }
    };
    var extended = {};
    var parent;
    for (var i = 0; i < arguments.length; ++i) {
        if (typeof arguments[i] == "function") {
            parent = arguments[i].prototype;
        } else {
            parent = arguments[i];
        }
        DUtil.extend(extended, parent);
    }
    Class.prototype = extended;
    return Class;
};

DUtil.extend用于扩展,DObject函数是用于继承(貌似也是扩展)?不知这个理解对不对?哪位能详细说下吗

扩展是本身行为,内容不定;而继承是基于父级的前提下获取内容,内容容量取决于父级