Comparing version 1.2.2 to 1.2.3
@@ -10,3 +10,3 @@ { | ||
}], | ||
"version": "1.2.2", | ||
"version": "1.2.3", | ||
"description": "Powerful and flexible generator objects with the possibility of inheritance", | ||
@@ -13,0 +13,0 @@ "main": "refine.js", |
/** | ||
* RefineJS v1.2.2 - Powerful and flexible generator objects with the possibility of inheritance for JavaScript | ||
* RefineJS v1.2.3 - Powerful and flexible generator objects with the possibility of inheritance for JavaScript | ||
* Copyright 2011-2014 Dmitrii Pakhtinov (spb.piksel@gmail.com) | ||
* Released under the MIT license | ||
* Update: 11/20/2014 | ||
* Update: 11/23/2014 | ||
*/ | ||
@@ -29,6 +29,6 @@ (function(factory) { | ||
Boolean = globalScope['Boolean'], | ||
toString = Object.prototype.toString, | ||
ObjectPrototype = Object.prototype, | ||
defineProperty = Object.defineProperty, | ||
hasOwnProperty = Object.prototype.hasOwnProperty, | ||
isNeedProto = !(Object.getPrototypeOf || Object.prototype.__proto__), | ||
hasOwnProperty = ObjectPrototype.hasOwnProperty, | ||
isNeedProto = !(Object.getPrototypeOf || "__proto__" in ObjectPrototype), | ||
emptyFunction = (function() { | ||
@@ -91,3 +91,3 @@ return function() { | ||
if (argv[argn] && typeof argv[argn] === 'object' && !(argv[argn] instanceof Array) && | ||
argv[argn].constructor && argv[argn].constructor !== Object.prototype.constructor) { | ||
argv[argn].constructor && argv[argn].constructor !== ObjectPrototype.constructor) { | ||
if (VBInc && defineProperty) { | ||
@@ -523,3 +523,3 @@ try { | ||
value = object[index]; | ||
if (((all && value !== Object.prototype[index]) || hasOwnProperty.call(object, index)) && | ||
if (((all && value !== ObjectPrototype[index]) || hasOwnProperty.call(object, index)) && | ||
callback.call(value, index, value) === False) { | ||
@@ -534,3 +534,3 @@ length = False; | ||
if ((hasOwnProperty.call(object, dontEnums[index]) || | ||
(all && dontEnums[index] in object && value !== Object.prototype[dontEnums[index]])) && | ||
(all && dontEnums[index] in object && value !== ObjectPrototype[dontEnums[index]])) && | ||
callback.call(value, dontEnums[index], value) === False) { | ||
@@ -537,0 +537,0 @@ break; |
/** | ||
* RefineJS v1.2.2 - Powerful and flexible generator objects with the possibility of inheritance for JavaScript | ||
* RefineJS v1.2.3 - Powerful and flexible generator objects with the possibility of inheritance for JavaScript | ||
* Copyright 2011-2014 Dmitrii Pakhtinov (spb.piksel@gmail.com) | ||
* Released under the MIT license | ||
* Update: 11/20/2014 | ||
* Update: 11/23/2014 | ||
*/ | ||
(function(Q){"function"===typeof define&&define.amd?define("object"!==typeof document||"loading"!==document.readyState?[]:"refinejs",Q):"object"===typeof exports&&"undefined"!==typeof module?module.exports=Q():Q()})(function(){function T(a,b){return function(){throw Error("'"+a+"' property is "+(b?"read":"write")+"-only");}}function X(a){return function(){return a}}function l(a,b,i,h,K){function f(){function d(){var n;!e&&!N&&"function"===typeof o.i&&(n=o.i.apply(m?g:c,b));return n===D?g:n}var c=this,b=arguments,e=c instanceof U,m=e?b[4]:c instanceof f,p=!e||b[2]===D||E!==D?E:b[2];if(!p&&!e&&!m&&b.length&&"__refine__"in b[0])return R.call(f,b[0]);var k=O,q=r,l=K.apply({isParent:e,isInstance:m,options:h},e? | ||
b[0]:b),w=e&&b[3]||r,g=N||w||l,o=e?b[1]:{a:l};for(F(I,function(n,J){y.call(l,n)||(l[n]=J)});k--;)if("function"!==typeof i[k]&&("string"===typeof i[k]?i[k]=Y(i[k],a):(i[k]=X(i[k]),p=p===D?S:p)),z.prototype=q=i[k].call(new U,b,o,p,w,m),0<k&&(o.i=r),g=w=new z,!p)g.parent=q,Z&&(g.__proto__=q);if(O||e||N){var C=function(n){return p?n:"function"===typeof n?function(){var J=o.a,a=J.parent;!p&&(J.parent=q);var b=n.apply(this===g||this==j?J:this,arguments);!p&&(J.parent=a);return b}:n};F(l,function(n,a){if(a&& | ||
"object"===typeof a&&("set"in a&&(a.set=C(a.set)),"get"in a))a.get=C(a.get);g[n]=C(a)});o.a=e?o.a:g}p||(g.__refine__=f);y.call(g,u)?o.i=g[u]:y.call(g,"constructor")&&(o.i=g.constructor);if(!e&&0!==A){if(!G||H)F(H?g:A,function(a){var b=g[a],d=a,c=0;if(c=H?b&&"object"===typeof b&&"parent"!==a&&"__proto__"!==a?(y.call(b,"set")?1:0)+(y.call(b,"get")?2:0):0===a.indexOf("get ")?4:0===a.indexOf("set ")?8:G&&"toString"===a?16:0:A[a])if(H&&16!==(A[a]=c)&&x++,c&3?(z.prototype=b,b=new z):(d=a.split(" ").pop(), | ||
8!==c&&"function"!==typeof b&&(b=function(a){return function(){return a}}(b))),G)c&22&&s.push("Public "+(c&16?"Default ":"")+"Property Get ["+d+"]","Call VBCorrectVal("+(b?"[(accessors)].["+a+"]"+(c&2?".get":"")+".call(me,[(accessors)].["+a+"])":"window.undefined")+",["+d+"])","End Property"),c&25&&s.push("Public Property Let ["+d+"](val)",c=(c&16?"Set [(accessors)].["+a+"]=val":b?"Call [(accessors)].["+a+"]"+(c&1?".set":"")+".call(me,val,[(accessors)].["+a+"])":"")+"\nEnd Property","Public Property Set ["+ | ||
d+"](val)",c);else{var f=p?D:T(d,1),e=p?D:T(d,0);if(c&1?b.set:8===c&&b)f=function(a){(c&1?b.set:b).call(this,a,b)};if(c&2?b.get:4===c&&b)e=function(){return(c&2?b.get:b).call(this,b)};y.call(g,a)&&delete g[a];L?(a=t.getOwnPropertyDescriptor(g,d),L(g,d,{enumerable:M?0:1,configurable:1,set:4===c&&a&&a.set||f,get:8===c&&a&&a.get||e})):((f=4===c&&g.__lookupSetter__(d)||f)&&g.__defineSetter__(d,f),(e=8===c&&g.__lookupGetter__(d)||e)&&g.__defineGetter__(d,e))}else G&&(50===v.length&&(s.push("Public ["+ | ||
v.join("],[")+"]"),v.length=0),v[v.length]=a)},H);H&&!(H=0)&&0===x?v=s=A=0:G&&(x&&(B="StaticClass"+P+M++,s.unshift("Class "+B),s.push((v.length?"Public ["+v.join("],[")+"]\n":"")+"Private [(accessors)]","Private Sub Class_Initialize()","Set [(accessors)]="+B+"FactoryJS()","End Sub","End Class","Function "+B+"Factory()","Set "+B+"Factory=New "+B,"End Function"),j[B+"FactoryJS"]=function(){return s},j.execVBScript(s.join("\n")),x=v=s=r),s={},o.a=j[B+"Factory"](),F(g,function(a,b){if(A.hasOwnProperty(a))if(A[a]& | ||
3){z.prototype=g[a];s[a]=new z}else s[a]=A[a]!==8&&typeof b!=="function"?function(){return b}:g[a];else o.a[a]=(!O||p)&&typeof b==="function"&&a!=="__refine__"?function(){return b.apply(this===g||this==j?o.a:this,arguments)}:b},1),g=o.a)}return m?new d:d()}var e,m,q,G=M,H=1,d=arguments,c=d.length-1,u="constructor",B=r,s=[],v=[],x=0,A=M===r?0:{},N,k,I,E,O,C=this instanceof l,K=d[c--]||{};if(d[c]&&"object"===typeof d[c]&&!(d[c]instanceof w)&&d[c].constructor&&d[c].constructor!==t.prototype.constructor){if(M&& | ||
L)try{L(d[c],"t"+P,{configurable:1,set:function(a){G=a}}),d[c]["t"+P]=0,delete d[c]["t"+P]}catch(W){}N=G?r:(E=S,d[c--])}h=!d[c]||d[c]instanceof w||"object"!==typeof d[c]?"boolean"===typeof d[c]||"number"===typeof d[c]?{compact:d[c--]}:{}:d[c--];E=E||h.compact;e=h.context;m=h.extend;q=h.mixins;I=h.statics||(e||m||q||"compact"in h?{}:h);i=d[c]instanceof w?d[c--]:"function"===typeof d[c]?[d[c--]]:"string"===typeof d[c-1]&&(""+d[c--]).replace(/(^|\s)(extends|implements)(\s|$)/g,",").replace(/^[\s,]+|\s(?=\s)|[\s,]+$/g, | ||
"").replace(/\s*,\s*/g,",").split(",")||[];k="string"===typeof d[c]&&d[c--].split(/extends|implements|,/g)||[];a=d[c--]||e||l.refineScope||(l.refineScope=j);b=(k.shift()||"").replace(/^\s+|\s+$/g,"");e=(k=k.join(",").replace(/^[\s,]+|[\s,]+$/g,"").replace(/\s*,\s*/g,","))?k.split(","):[];m=(m=m||[])instanceof w?m:[m];q=(q=q||[])instanceof w?q:[q];i=e.concat.call(e,i.concat.call(i,m.concat.call(m,q)));if(!(O=i.length)&&!(b||E!==D))E=S;if("function"!==typeof K)var V=K,K=function(){z.prototype=V.constructor.prototype; | ||
k=new z;F(V,function(a,b){k[a]=b});return k};f.toString=function(){return"[object "+(b||"Function")+"]"};f.getInstanceOf=R;f.baseContext=a;F(I,function(a,b){f[a]=b});if(f.b=b){e=a;d=(k=b.split(".")).shift();do 0===k.length?e[u=d]=f:(d in e||(e[d]={}),e=e[d]);while(d=k.shift())}return C?new f:f}function C(a,b){var i=r,h=b,j,f;if("string"===typeof a){for(f=a.split(".");(j=f.shift())&&(b=b[j]););"function"===typeof b&&h===b.baseContext&&(i=b)}return i}function Y(a,b){var i=C(a,b)||C(a,j)||"function"=== | ||
typeof l.autoload&&l.autoload(a,b)||r;if(!i)throw Error("Parent constructor '"+a+"' not Initialized or Undefined");return i}function F(a,b,i){var h,j=u.length,f;for(h in a)if(f=a[h],(i&&f!==t.prototype[h]||y.call(a,h))&&b.call(f,h,f)===I){j=I;break}if(j&&W)for(h=0;h<j&&!(f=a[u[h]],(y.call(a,u[h])||i&&u[h]in a&&f!==t.prototype[u[h]])&&b.call(f,u[h],f)===I);h++);}function R(a){for(;a&&a.__refine__!=r;){if(a.__refine__===this)return a;a=t.getPrototypeOf?t.getPrototypeOf(a):a.__proto__}return r}var S= | ||
!0,I=!1,r=null,D=void 0,j=("object"===typeof window?window:"undefined"!==typeof global?global:this)||{},x=j.JSON,w=j.Array,t=j.Object,U=j.Boolean,L=t.defineProperty,y=t.prototype.hasOwnProperty,Z=!(t.getPrototypeOf||t.prototype.__proto__),z=function(){return function(){}}(),P=(new Date).getTime(),W=!{toString:1}.propertyIsEnumerable("toString"),u="toString,toLocaleString,valueOf,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,constructor".split(",");l.instanceOf=function(a,b){return!!R.call(b,a)}; | ||
var M=function(a,b){function i(b){a=b}try{L(a,"t",{set:i})}catch(h){try{a.__defineSetter__("t",i)}catch(l){}}a.t=0;a&&(a=1,"execVBscript"in j||("execScript"in j?j.execScript("Function execVBscript(code) ExecuteGlobal(code) End Function\nFunction VBCorrectVal(o,r) If IsObject(o) Then Set r=o Else r=o End If End Function","VBScript"):a=r),a&&"function"===typeof b&&(x.stringify=function(a){if(a&&!(a instanceof t)){var e={};F(a,function(a,b){"__proto__"!==a&&(e[a]=b)});arguments[0]=e}return b.apply(x,arguments)}));return a}({},x&&x.stringify);l.refineScope=l.refineScope||j;return j.refine=j.refinejs=l}); | ||
(function(R){"function"===typeof define&&define.amd?define("object"!==typeof document||"loading"!==document.readyState?[]:"refinejs",R):"object"===typeof exports&&"undefined"!==typeof module?module.exports=R():R()})(function(){function U(a,b){return function(){throw Error("'"+a+"' property is "+(b?"read":"write")+"-only");}}function Y(a){return function(){return a}}function l(a,b,i,h,K){function f(){function d(){var n;!e&&!N&&"function"===typeof o.i&&(n=o.i.apply(m?g:c,b));return n===C?g:n}var c=this,b=arguments,e=c instanceof V,m=e?b[4]:c instanceof f,p=!e||b[2]===C||D!==C?D:b[2];if(!p&&!e&&!m&&b.length&&"__refine__"in b[0])return S.call(f,b[0]);var k=O,q=r,l=K.apply({isParent:e,isInstance:m,options:h},e? | ||
b[0]:b),v=e&&b[3]||r,g=N||v||l,o=e?b[1]:{a:l};for(E(I,function(n,J){y.call(l,n)||(l[n]=J)});k--;)if("function"!==typeof i[k]&&("string"===typeof i[k]?i[k]=Z(i[k],a):(i[k]=Y(i[k]),p=p===C?T:p)),z.prototype=q=i[k].call(new V,b,o,p,v,m),0<k&&(o.i=r),g=v=new z,!p)g.parent=q,$&&(g.__proto__=q);if(O||e||N){var w=function(n){return p?n:"function"===typeof n?function(){var J=o.a,a=J.parent;!p&&(J.parent=q);var b=n.apply(this===g||this==j?J:this,arguments);!p&&(J.parent=a);return b}:n};E(l,function(n,a){if(a&& | ||
"object"===typeof a&&("set"in a&&(a.set=w(a.set)),"get"in a))a.get=w(a.get);g[n]=w(a)});o.a=e?o.a:g}p||(g.__refine__=f);y.call(g,t)?o.i=g[t]:y.call(g,"constructor")&&(o.i=g.constructor);if(!e&&0!==A){if(!F||G)E(G?g:A,function(a){var b=g[a],d=a,c=0;if(c=G?b&&"object"===typeof b&&"parent"!==a&&"__proto__"!==a?(y.call(b,"set")?1:0)+(y.call(b,"get")?2:0):0===a.indexOf("get ")?4:0===a.indexOf("set ")?8:F&&"toString"===a?16:0:A[a])if(G&&16!==(A[a]=c)&&x++,c&3?(z.prototype=b,b=new z):(d=a.split(" ").pop(), | ||
8!==c&&"function"!==typeof b&&(b=function(a){return function(){return a}}(b))),F)c&22&&s.push("Public "+(c&16?"Default ":"")+"Property Get ["+d+"]","Call VBCorrectVal("+(b?"[(accessors)].["+a+"]"+(c&2?".get":"")+".call(me,[(accessors)].["+a+"])":"window.undefined")+",["+d+"])","End Property"),c&25&&s.push("Public Property Let ["+d+"](val)",c=(c&16?"Set [(accessors)].["+a+"]=val":b?"Call [(accessors)].["+a+"]"+(c&1?".set":"")+".call(me,val,[(accessors)].["+a+"])":"")+"\nEnd Property","Public Property Set ["+ | ||
d+"](val)",c);else{var f=p?C:U(d,1),e=p?C:U(d,0);if(c&1?b.set:8===c&&b)f=function(a){(c&1?b.set:b).call(this,a,b)};if(c&2?b.get:4===c&&b)e=function(){return(c&2?b.get:b).call(this,b)};y.call(g,a)&&delete g[a];L?(a=H.getOwnPropertyDescriptor(g,d),L(g,d,{enumerable:M?0:1,configurable:1,set:4===c&&a&&a.set||f,get:8===c&&a&&a.get||e})):((f=4===c&&g.__lookupSetter__(d)||f)&&g.__defineSetter__(d,f),(e=8===c&&g.__lookupGetter__(d)||e)&&g.__defineGetter__(d,e))}else F&&(50===u.length&&(s.push("Public ["+ | ||
u.join("],[")+"]"),u.length=0),u[u.length]=a)},G);G&&!(G=0)&&0===x?u=s=A=0:F&&(x&&(B="StaticClass"+P+M++,s.unshift("Class "+B),s.push((u.length?"Public ["+u.join("],[")+"]\n":"")+"Private [(accessors)]","Private Sub Class_Initialize()","Set [(accessors)]="+B+"FactoryJS()","End Sub","End Class","Function "+B+"Factory()","Set "+B+"Factory=New "+B,"End Function"),j[B+"FactoryJS"]=function(){return s},j.execVBScript(s.join("\n")),x=u=s=r),s={},o.a=j[B+"Factory"](),E(g,function(a,b){if(A.hasOwnProperty(a))if(A[a]& | ||
3){z.prototype=g[a];s[a]=new z}else s[a]=A[a]!==8&&typeof b!=="function"?function(){return b}:g[a];else o.a[a]=(!O||p)&&typeof b==="function"&&a!=="__refine__"?function(){return b.apply(this===g||this==j?o.a:this,arguments)}:b},1),g=o.a)}return m?new d:d()}var e,m,q,F=M,G=1,d=arguments,c=d.length-1,t="constructor",B=r,s=[],u=[],x=0,A=M===r?0:{},N,k,I,D,O,Q=this instanceof l,K=d[c--]||{};if(d[c]&&"object"===typeof d[c]&&!(d[c]instanceof v)&&d[c].constructor&&d[c].constructor!==w.constructor){if(M&& | ||
L)try{L(d[c],"t"+P,{configurable:1,set:function(a){F=a}}),d[c]["t"+P]=0,delete d[c]["t"+P]}catch(X){}N=F?r:(D=T,d[c--])}h=!d[c]||d[c]instanceof v||"object"!==typeof d[c]?"boolean"===typeof d[c]||"number"===typeof d[c]?{compact:d[c--]}:{}:d[c--];D=D||h.compact;e=h.context;m=h.extend;q=h.mixins;I=h.statics||(e||m||q||"compact"in h?{}:h);i=d[c]instanceof v?d[c--]:"function"===typeof d[c]?[d[c--]]:"string"===typeof d[c-1]&&(""+d[c--]).replace(/(^|\s)(extends|implements)(\s|$)/g,",").replace(/^[\s,]+|\s(?=\s)|[\s,]+$/g, | ||
"").replace(/\s*,\s*/g,",").split(",")||[];k="string"===typeof d[c]&&d[c--].split(/extends|implements|,/g)||[];a=d[c--]||e||l.refineScope||(l.refineScope=j);b=(k.shift()||"").replace(/^\s+|\s+$/g,"");e=(k=k.join(",").replace(/^[\s,]+|[\s,]+$/g,"").replace(/\s*,\s*/g,","))?k.split(","):[];m=(m=m||[])instanceof v?m:[m];q=(q=q||[])instanceof v?q:[q];i=e.concat.call(e,i.concat.call(i,m.concat.call(m,q)));if(!(O=i.length)&&!(b||D!==C))D=T;if("function"!==typeof K)var W=K,K=function(){z.prototype=W.constructor.prototype; | ||
k=new z;E(W,function(a,b){k[a]=b});return k};f.toString=function(){return"[object "+(b||"Function")+"]"};f.getInstanceOf=S;f.baseContext=a;E(I,function(a,b){f[a]=b});if(f.b=b){e=a;d=(k=b.split(".")).shift();do 0===k.length?e[t=d]=f:(d in e||(e[d]={}),e=e[d]);while(d=k.shift())}return Q?new f:f}function Q(a,b){var i=r,h=b,j,f;if("string"===typeof a){for(f=a.split(".");(j=f.shift())&&(b=b[j]););"function"===typeof b&&h===b.baseContext&&(i=b)}return i}function Z(a,b){var i=Q(a,b)||Q(a,j)||"function"=== | ||
typeof l.autoload&&l.autoload(a,b)||r;if(!i)throw Error("Parent constructor '"+a+"' not Initialized or Undefined");return i}function E(a,b,i){var h,j=t.length,f;for(h in a)if(f=a[h],(i&&f!==w[h]||y.call(a,h))&&b.call(f,h,f)===I){j=I;break}if(j&&X)for(h=0;h<j&&!(f=a[t[h]],(y.call(a,t[h])||i&&t[h]in a&&f!==w[t[h]])&&b.call(f,t[h],f)===I);h++);}function S(a){for(;a&&a.__refine__!=r;){if(a.__refine__===this)return a;a=H.getPrototypeOf?H.getPrototypeOf(a):a.__proto__}return r}var T=!0,I=!1,r=null,C=void 0, | ||
j=("object"===typeof window?window:"undefined"!==typeof global?global:this)||{},x=j.JSON,v=j.Array,H=j.Object,V=j.Boolean,w=H.prototype,L=H.defineProperty,y=w.hasOwnProperty,$=!(H.getPrototypeOf||"__proto__"in w),z=function(){return function(){}}(),P=(new Date).getTime(),X=!{toString:1}.propertyIsEnumerable("toString"),t="toString,toLocaleString,valueOf,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,constructor".split(",");l.instanceOf=function(a,b){return!!S.call(b,a)};var M=function(a,b){function i(b){a= | ||
b}try{L(a,"t",{set:i})}catch(h){try{a.__defineSetter__("t",i)}catch(l){}}a.t=0;a&&(a=1,"execVBscript"in j||("execScript"in j?j.execScript("Function execVBscript(code) ExecuteGlobal(code) End Function\nFunction VBCorrectVal(o,r) If IsObject(o) Then Set r=o Else r=o End If End Function","VBScript"):a=r),a&&"function"===typeof b&&(x.stringify=function(a){if(a&&!(a instanceof H)){var e={};E(a,function(a,b){"__proto__"!==a&&(e[a]=b)});arguments[0]=e}return b.apply(x,arguments)}));return a}({},x&&x.stringify);l.refineScope=l.refineScope||j;return j.refine=j.refinejs=l}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
46690