abstract-object
Advanced tools
Comparing version 1.3.6 to 1.4.0
@@ -101,3 +101,8 @@ /** `Object#toString` result shortcuts */ | ||
}, | ||
//just replace the ctor.super to superCtor, | ||
inheritsDirectly: function(ctor, superCtor) { | ||
ctor.super_ = superCtor; | ||
ctor.__super__ = superCtor.prototype; //for coffeeScirpt super keyword. | ||
ctor.prototype = util.newPrototype(superCtor, ctor); | ||
}, | ||
/** | ||
@@ -149,2 +154,3 @@ * Inherit the prototype methods from one constructor into another. | ||
} | ||
if (result) result = ctor; | ||
return result; | ||
@@ -151,0 +157,0 @@ }, |
{ | ||
"name": "abstract-object", | ||
"version": "1.3.6", | ||
"version": "1.4.0", | ||
"description": "AbstractObject with Object State Events Support, RefObject with RefCount and AddRef/Release Support.", | ||
@@ -5,0 +5,0 @@ "homepage": "https://github.com/snowyu/abstract-object", |
@@ -64,3 +64,3 @@ # AbtractObject | ||
# if you do not wanna use `AbstractObject.create`, you MUST remember this: | ||
# even the constructor is empty, you should can the parent's constructor manually. | ||
# even the constructor is empty, you should call the parent's constructor manually. | ||
# myObj = new MyObject() | ||
@@ -161,3 +161,3 @@ | ||
createError(typeName, errorCode) | ||
createError(typeName, errorCode[, parentErrorClass]) | ||
@@ -168,2 +168,3 @@ __arguments__ | ||
* errorCode: *(number)*: the error code, it should be greater than 1000. | ||
* parentErrorClass: *(class)*: the optional parent error class. defaults to AbstractError. | ||
@@ -170,0 +171,0 @@ __return__ |
Sorry, the diff of this file is not supported yet
57106
526
197