Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

comb

Package Overview
Dependencies
Maintainers
1
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

comb - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

42

History.md

@@ -1,3 +0,9 @@

0.1.1/2012-04-20
===
#0.1.2/2012-07-17
* Bug fixes
* Changed comb.logging.PropertyConfigurator to deep merge porperties (Clone to config object)
* Added comb.array.multiply
* Updated docs to use [coddoc](https://github.comb/doug-martin/coddoc)
#0.1.1/2012-04-20
* Migrated all tests to use [it](http://github.com/doug-martin/it)

@@ -7,4 +13,4 @@ * More Tests

0.1.0/2012-03-02
===
#0.1.0/2012-03-02
* comb.define performance increase

@@ -14,4 +20,4 @@ * Changed HashTable to use strict equal

0.0.9 /2012-02-16
===
#0.0.9 /2012-02-16
* Complete redesign of comb.define to be more flexible and efficient

@@ -44,4 +50,4 @@ * this._super does not require and Arguments object any more to call super

0.0.8 / 2012-02-9
===
#0.0.8 / 2012-02-9
* Added new MethodMissing plugin

@@ -51,4 +57,4 @@ * Bug fixes

0.0.7 / 2012-02-04
==================
#0.0.7 / 2012-02-04
* Bug Fixes

@@ -66,4 +72,4 @@ * Fixed issue with array.zip

0.0.6 / 2011-12-29
==================
#0.0.6 / 2011-12-29
* Bug Fixes

@@ -80,4 +86,4 @@ * Added new Proxy methods

0.0.3 / 2011-06-23
==================
#0.0.3 / 2011-06-23
* 100% test coverage

@@ -95,5 +101,5 @@ * Bug fixes

0.0.2 / 2011-06-11
==================
#0.0.2 / 2011-06-11
* Added Logging

@@ -104,5 +110,5 @@ * More robust String formatting

0.0.1 / 2011-05-19
==================
#0.0.1 / 2011-05-19
* Initial release

@@ -1,1 +0,1 @@

module.exports = exports = require("./lib");
module.exports = require("./lib");

@@ -1,2 +0,2 @@

var obj = require("./object"), misc = require("./misc");
var obj = require("./object"), misc = require("./misc"), number = require("./number.js");

@@ -6,8 +6,8 @@

var isArray = exports.isArray = function(obj) {
var isArray = exports.isArray = function (obj) {
return obj && obj instanceof Array;
};
var cross = function(num, cross) {
var ret = cross.reduceRight(function(a, b) {
var cross = function (num, cross) {
var ret = cross.reduceRight(function (a, b) {
if (!isArray(b)) b = [b];

@@ -21,3 +21,3 @@ b.unshift(num)

var permute = function(num, cross, length) {
var permute = function (num, cross, length) {
var ret = [];

@@ -31,3 +31,3 @@ for (var i = 0; i < cross.length; i++) {

var intersection = function(a, b) {
var intersection = function (a, b) {
var ret = [];

@@ -53,2 +53,3 @@ if (isArray(a) && isArray(b)) {

comb.array = {
/**@lends comb.array*/

@@ -66,3 +67,3 @@

*/
toArray : function(o) {
toArray:function (o) {
var ret = [];

@@ -84,3 +85,3 @@ if (o != null) {

} else {
args.forEach(function(a) {
args.forEach(function (a) {
ret = ret.concat(array.toArray(a));

@@ -108,6 +109,6 @@ })

*/
sum : function(array) {
sum:function (array) {
array = array || [];
if (array.length) {
return array.reduce(function(a, b) {
return array.reduce(function (a, b) {
return a + b;

@@ -131,5 +132,5 @@ });

*/
removeDuplicates : function(arr) {
removeDuplicates:function (arr) {
if (isArray(arr)) {
var ret = arr.reduce(function(a, b) {
var ret = arr.reduce(function (a, b) {
if (a.indexOf(b) == -1) {

@@ -162,3 +163,3 @@ return a.concat(b);

*/
rotate : function(arr, numberOfTimes) {
rotate:function (arr, numberOfTimes) {
var ret = arr.slice();

@@ -197,3 +198,3 @@ if (typeof numberOfTimes != "number") {

*/
permutations : function(arr, length) {
permutations:function (arr, length) {
var ret = [];

@@ -210,3 +211,3 @@ if (isArray(arr)) {

} else if (length <= arr.length) {
ret = arr.reduce(function(a, b, i) {
ret = arr.reduce(function (a, b, i) {
if (length > 1) {

@@ -239,3 +240,3 @@ var ret = permute(b, array.rotate(copy, i).slice(1), length);

*/
zip : function() {
zip:function () {
var ret = [];

@@ -246,3 +247,3 @@ var arrs = argsToArray(arguments);

if (isArray(arr1)) {
ret = arr1.reduce(function(a, b, i) {
ret = arr1.reduce(function (a, b, i) {
var curr = [b];

@@ -275,9 +276,9 @@ for (var j = 0; j < arrs.length; j++) {

*/
transpose : function(arr) {
transpose:function (arr) {
var ret = [];
if (isArray(arr) && arr.length) {
var last;
arr.forEach(function(a) {
arr.forEach(function (a) {
if (isArray(a) && (!last || a.length == last.length)) {
a.forEach(function(b, i) {
a.forEach(function (b, i) {
!ret[i] && (ret[i] = []);

@@ -305,3 +306,3 @@ ret[i].push(b);

*/
valuesAt : function(arr, indexes) {
valuesAt:function (arr, indexes) {
var ret = [];

@@ -328,7 +329,7 @@ var indexes = argsToArray(arguments);

*/
union : function() {
union:function () {
var ret = [];
var arrs = argsToArray(arguments);
if (arrs.length > 1) {
ret = array.removeDuplicates(arrs.reduce(function(a, b) {
ret = array.removeDuplicates(arrs.reduce(function (a, b) {
return a.concat(b);

@@ -354,3 +355,3 @@ }, []));

*/
intersect : function(a, b) {
intersect:function (a, b) {
var collect = [], set;

@@ -366,3 +367,3 @@ var args = argsToArray(arguments);

var x = set.shift();
var collect = set.reduce(function(a, b) {
var collect = set.reduce(function (a, b) {
return intersection(a, b);

@@ -416,7 +417,7 @@ }, x);

*/
powerSet : function(arr) {
powerSet:function (arr) {
var ret = [];
if (isArray(arr) && arr.length) {
var ret = arr.reduce(function(a, b) {
var ret = a.map(function(c) {
var ret = arr.reduce(function (a, b) {
var ret = a.map(function (c) {
return c.concat(b);

@@ -466,3 +467,3 @@ })

*/
cartesian : function(a, b) {
cartesian:function (a, b) {
var ret = [];

@@ -485,6 +486,6 @@ if (isArray(a) && isArray(b) && a.length && b.length)

*/
compact : function(arr) {
compact:function (arr) {
var ret = [];
if (isArray(arr) && arr.length) {
ret = arr.filter(function(item) {
ret = arr.filter(function (item) {
return !misc.isUndefinedOrNull(item);

@@ -497,2 +498,23 @@ })

/**
* Creates a new array that is the result of the array concated the number of
* times. If times is not specified or it equals 0 then it defaults to 1.
* @param {Array} arr the array to multiply.
* @param {Number} [times=1] the number of times to multiple the array.
* @return {Array} a new array that is the result of the array multiplied the number of times specified.
*/
multiply:function (arr, times) {
times = number.isNumber(times) ? times : 1;
if (!times) {
//make sure times is greater than zero if it is zero then dont multiply it
times = 1;
}
arr = array.toArray(arr || []);
var ret = [], i = 0;
while (++i <= times) {
ret = ret.concat(arr);
}
return ret;
},
/**
* Flatten multiple arrays into a single array

@@ -507,3 +529,3 @@ *

*/
flatten : function(arr) {
flatten:function (arr) {
var set;

@@ -517,3 +539,3 @@ var args = argsToArray(arguments);

}
return set.reduce(function(a, b) {
return set.reduce(function (a, b) {
return a.concat(b);

@@ -520,0 +542,0 @@ }, []);

@@ -150,2 +150,4 @@ var string = require("./string").string;

/**@lends comb.date*/
/**

@@ -152,0 +154,0 @@ * Returns the number of days in the month of a date

@@ -14,2 +14,3 @@ var comb = exports;

comb.regexp = {
/**@lends comb.regexp*/
/**

@@ -23,3 +24,3 @@ * Escapes a string

*/
escapeString : function(/*String*/str, /*String?*/except) {
escapeString : function(str, except) {
return str.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g, function(ch) {

@@ -26,0 +27,0 @@ if (except && except.indexOf(ch) != -1) {

@@ -103,2 +103,4 @@ var comb = exports, date, misc = require("./misc");

comb.characters = {
/**@lends comb.characters*/
/**

@@ -864,2 +866,4 @@ * ☺

comb.string = {
/**@lends comb.string*/
/**

@@ -866,0 +870,0 @@ * Pads a string

@@ -88,2 +88,4 @@ var define = require("../define").define,

/**
*
* @ignoreCode
* @class <p>Andersson Trees are a version of a balanced Binary tree, while similar to RedBlack Trees the balancing is not as strict.</p>

@@ -90,0 +92,0 @@ *

@@ -152,2 +152,3 @@ var define = require("../define").define,

/**
* @ignoreCode
* @class <p>An AVL tree is a self-balancing binary search tree.

@@ -154,0 +155,0 @@ * In an AVL tree, the heights of the two child subtrees of any node differ by at most one.

@@ -6,2 +6,4 @@ var define = require("../define").define,

/**
*
* @ignoreCode
* @class <p>A Search tree that maintains the following properties</p>

@@ -8,0 +10,0 @@ * <ul>

var define = require("../define").define,
base = require("../base");
base = require("../base");
/**
* @ignoreCode
* @class Base class for all collections

@@ -9,50 +10,48 @@ * @name Collection

*/
var Collection = define(null, {
instance : {
/**@lends comb.collections.Collection.prototype*/
define(null, {
instance:{
/**@lends comb.collections.Collection.prototype*/
/**
* Concats two collections
*/
concat : function() {
throw new Error("Not Implemented");
},
/**
* Concats two collections
*/
concat:function () {
throw new Error("Not Implemented");
},
/**
* Joins two collections
*/
join : function() {
throw new Error("Not Implemented");
},
/**
* Joins two collections
*/
join:function () {
throw new Error("Not Implemented");
},
/**
* Slice a portion from a collection
*/
slice : function() {
throw new Error("Not Implemented");
},
/**
* Slice a portion from a collection
*/
slice:function () {
throw new Error("Not Implemented");
},
/**
* Convert a collection to a string
*/
toString : function() {
throw new Error("Not Implemented");
},
/**
* Convert a collection to a string
*/
toString:function () {
throw new Error("Not Implemented");
},
/**
* Find the index of an item in a collection
*/
indexOf : function() {
throw new Error("Not Implemented");
},
/**
* Find the index of an item in a collection
*/
indexOf:function () {
throw new Error("Not Implemented");
},
/**
* Find the last index of an item in a collection
*/
lastIndexOf : function() {
throw new Error("Not Implemented");
}
}
});
module.exports = exports = Collection;
/**
* Find the last index of an item in a collection
*/
lastIndexOf:function () {
throw new Error("Not Implemented");
}
}
}).as(module);
var define = require("../define").define,
Collection = require("./Collection"),
Iterable = require("./Iterable"),
base = require("../base");
Collection = require("./Collection"),
Iterable = require("./Iterable"),
base = require("../base");

@@ -18,97 +18,98 @@ var hashFunction = function (key) {

instance : {
instance:{
constructor : function() {
this.__entries = [];
},
constructor:function () {
this.__entries = [];
},
pushValue : function(key, value) {
this.__entries.push({key : key, value : value});
return value;
},
pushValue:function (key, value) {
this.__entries.push({key:key, value:value});
return value;
},
remove : function(key) {
var ret = null, map = this.__entries, val;
var i = map.length - 1;
for (; i >= 0; i--) {
if ((val = map[i]) != null && val.key === key) {
map[i] = null;
return val.value;
}
}
return ret;
},
remove:function (key) {
var ret = null, map = this.__entries, val;
var i = map.length - 1;
for (; i >= 0; i--) {
if ((val = map[i]) != null && val.key === key) {
map[i] = null;
return val.value;
}
}
return ret;
},
"set" : function(key, value) {
var ret = null, map = this.__entries;
var i = map.length - 1;
for (; i >= 0; i--) {
var val = map[i];
if (val && key === val.key) {
val.value = value;
ret = value;
break;
}
}
if (!ret) {
map.push({key : key, value : value});
}
return ret;
},
"set":function (key, value) {
var ret = null, map = this.__entries;
var i = map.length - 1;
for (; i >= 0; i--) {
var val = map[i];
if (val && key === val.key) {
val.value = value;
ret = value;
break;
}
}
if (!ret) {
map.push({key:key, value:value});
}
return ret;
},
find : function(key) {
var ret = null, map = this.__entries, val;
var i = map.length - 1;
for (; i >= 0; i--) {
val = map[i];
if (val && key === val.key) {
ret = val.value;
break;
}
}
return ret;
},
find:function (key) {
var ret = null, map = this.__entries, val;
var i = map.length - 1;
for (; i >= 0; i--) {
val = map[i];
if (val && key === val.key) {
ret = val.value;
break;
}
}
return ret;
},
getEntrySet : function(arr) {
var map = this.__entries, l = map.length;
if (l) {
for (var i = 0; i < l; i++) {
var e = map[i];
if (e) {
arr.push(e);
}
}
getEntrySet:function (arr) {
var map = this.__entries, l = map.length;
if (l) {
for (var i = 0; i < l; i++) {
var e = map[i];
if (e) {
arr.push(e);
}
},
}
}
},
getKeys : function(arr) {
var map = this.__entries, l = map.length;
if (l) {
for (var i = 0; i < l; i++) {
var e = map[i];
if (e) {
arr.push(e.key);
}
}
getKeys:function (arr) {
var map = this.__entries, l = map.length;
if (l) {
for (var i = 0; i < l; i++) {
var e = map[i];
if (e) {
arr.push(e.key);
}
return arr;
},
}
}
return arr;
},
getValues : function(arr) {
var map = this.__entries, l = map.length;
if (l) {
for (var i = 0; i < l; i++) {
var e = map[i];
if (e) {
arr.push(e.value);
}
}
getValues:function (arr) {
var map = this.__entries, l = map.length;
if (l) {
for (var i = 0; i < l; i++) {
var e = map[i];
if (e) {
arr.push(e.value);
}
return arr;
}
}
});
return arr;
}
}
});
/**
*@class <p>Implementation of a HashTable for javascript.
* @ignoreCode
* @class <p>Implementation of a HashTable for javascript.
* This HashTable implementation allows one to use anything as a key.

@@ -128,252 +129,252 @@ * </p>

*/
module.exports = exports = HashTable = define([Collection, Iterable], {
define([Collection, Iterable], {
instance : {
/**@lends comb.collections.HashTable.prototype*/
instance:{
/**@lends comb.collections.HashTable.prototype*/
constructor : function() {
this.__map = {};
},
constructor:function () {
this.__map = {};
},
__entrySet : function() {
var ret = [], es = [];
for (var i in this.__map) {
this.__map[i].getEntrySet(ret);
}
return ret;
},
__entrySet:function () {
var ret = [], es = [];
for (var i in this.__map) {
this.__map[i].getEntrySet(ret);
}
return ret;
},
/**
* Put a key, value pair into the table
*
* <b>NOTE :</b> the collection will not check if the key previously existed.
*
* @param {Anything} key the key to look up the object.
* @param {Anything} value the value that corresponds to the key.
*
* @returns the value
*/
put : function(key, value) {
var hash = hashFunction(key);
var bucket = null;
if ((bucket = this.__map[hash]) == null) {
bucket = (this.__map[hash] = new Bucket());
}
bucket.pushValue(key, value);
return value;
},
/**
* Put a key, value pair into the table
*
* <b>NOTE :</b> the collection will not check if the key previously existed.
*
* @param {Anything} key the key to look up the object.
* @param {Anything} value the value that corresponds to the key.
*
* @returns the value
*/
put:function (key, value) {
var hash = hashFunction(key);
var bucket = null;
if ((bucket = this.__map[hash]) == null) {
bucket = (this.__map[hash] = new Bucket());
}
bucket.pushValue(key, value);
return value;
},
/**
* Remove a key value pair from the table.
*
* @param key the key of the key value pair to remove.
*
* @returns the removed value.
*/
remove : function(key) {
var hash = hashFunction(key), ret = null;
var bucket = this.__map[hash];
if (bucket) {
ret = bucket.remove(key);
}
return ret;
},
/**
* Remove a key value pair from the table.
*
* @param key the key of the key value pair to remove.
*
* @returns the removed value.
*/
remove:function (key) {
var hash = hashFunction(key), ret = null;
var bucket = this.__map[hash];
if (bucket) {
ret = bucket.remove(key);
}
return ret;
},
/**
* Get the value corresponding to the key.
*
* @param key the key used to look up the value
*
* @returns null if not found, or the value.
*/
"get" : function(key) {
var hash = hashFunction(key), ret = null;
var bucket = null;
if ((bucket = this.__map[hash]) != null) {
ret = bucket.find(key);
}
return ret;
},
/**
* Get the value corresponding to the key.
*
* @param key the key used to look up the value
*
* @returns null if not found, or the value.
*/
"get":function (key) {
var hash = hashFunction(key), ret = null;
var bucket = null;
if ((bucket = this.__map[hash]) != null) {
ret = bucket.find(key);
}
return ret;
},
/**
* Set the value of a previously existing key,value pair or create a new entry.
*
* @param key the key to be be used
* @param value the value to be set
*
* @returns the value.
*/
"set" : function(key, value) {
var hash = hashFunction(key), ret = null, bucket = null, map = this.__map;
if ((bucket = map[hash]) != null) {
ret = bucket.set(key, value);
} else {
ret = (map[hash] = new Bucket()).pushValue(key, value);
}
return ret;
},
/**
* Set the value of a previously existing key,value pair or create a new entry.
*
* @param key the key to be be used
* @param value the value to be set
*
* @returns the value.
*/
"set":function (key, value) {
var hash = hashFunction(key), ret = null, bucket = null, map = this.__map;
if ((bucket = map[hash]) != null) {
ret = bucket.set(key, value);
} else {
ret = (map[hash] = new Bucket()).pushValue(key, value);
}
return ret;
},
/**
* Tests if the table contains a particular key
* @param key the key to test
*
* @returns {Boolean} true if it exitsts false otherwise.
*/
contains : function(key) {
var hash = hashFunction(key), ret = false;
var bucket = null;
if ((bucket = this.__map[hash]) != null) {
ret = bucket.find(key) != null;
}
return ret;
},
/**
* Tests if the table contains a particular key
* @param key the key to test
*
* @returns {Boolean} true if it exitsts false otherwise.
*/
contains:function (key) {
var hash = hashFunction(key), ret = false;
var bucket = null;
if ((bucket = this.__map[hash]) != null) {
ret = bucket.find(key) != null;
}
return ret;
},
/**
* Returns a new HashTable containing the values of this HashTable, and the other table.
* </br>
* <b> DOES NOT CHANGE THE ORIGINAL!</b>
* @param {comb.collections.HashTable} hashTable the hash table to concat with this.
*
* @returns {comb.collections.HashTable} a new HashTable containing all values from both tables.
*/
concat : function(hashTable) {
if (hashTable instanceof HashTable) {
var ret = new HashTable();
var otherEntrySet = hashTable.entrySet.concat(this.entrySet);
for (var i = otherEntrySet.length - 1; i >= 0; i--) {
var e = otherEntrySet[i];
ret.put(e.key, e.value);
}
return ret;
} else {
throw new TypeError("When joining hashtables the joining arg must be a HashTable");
}
},
/**
* Returns a new HashTable containing the values of this HashTable, and the other table.
* </br>
* <b> DOES NOT CHANGE THE ORIGINAL!</b>
* @param {comb.collections.HashTable} hashTable the hash table to concat with this.
*
* @returns {comb.collections.HashTable} a new HashTable containing all values from both tables.
*/
concat:function (hashTable) {
if (hashTable instanceof this._static) {
var ret = new this._static();
var otherEntrySet = hashTable.entrySet.concat(this.entrySet);
for (var i = otherEntrySet.length - 1; i >= 0; i--) {
var e = otherEntrySet[i];
ret.put(e.key, e.value);
}
return ret;
} else {
throw new TypeError("When joining hashtables the joining arg must be a HashTable");
}
},
/**
* Creates a new HashTable containg values that passed the filtering function.
*
* @param {Function} cb Function to callback with each item, the first aruguments is an object containing a key and value field
* @param {Object} scope the scope to call the function.
*
* @returns {comb.collections.HashTable} the HashTable containing the values that passed the filter.
*/
filter : function(cb, scope) {
var es = this.__entrySet(), ret = new HashTable();
es = es.filter.apply(es, arguments);
for (var i = es.length - 1; i >= 0; i--) {
var e = es[i];
ret.put(e.key, e.value);
}
return ret;
},
/**
* Creates a new HashTable containg values that passed the filtering function.
*
* @param {Function} cb Function to callback with each item, the first aruguments is an object containing a key and value field
* @param {Object} scope the scope to call the function.
*
* @returns {comb.collections.HashTable} the HashTable containing the values that passed the filter.
*/
filter:function (cb, scope) {
var es = this.__entrySet(), ret = new this._static();
es = es.filter.apply(es, arguments);
for (var i = es.length - 1; i >= 0; i--) {
var e = es[i];
ret.put(e.key, e.value);
}
return ret;
},
/**
* Loop through each value in the hashtable
*
* @param {Function} cb the function to call with an object containing a key and value field
* @param {Object} scope the scope to call the funciton in
*/
forEach : function(cb, scope) {
var es = this.__entrySet(), l = es.length, f = cb.bind(scope || this);
es.forEach.apply(es, arguments);
},
/**
* Loop through each value in the hashtable
*
* @param {Function} cb the function to call with an object containing a key and value field
* @param {Object} scope the scope to call the funciton in
*/
forEach:function (cb, scope) {
var es = this.__entrySet(), l = es.length, f = cb.bind(scope || this);
es.forEach.apply(es, arguments);
},
/**
* Determines if every item meets the condition returned by the callback.
*
* @param {Function} cb Function to callback with each item, the first aruguments is an object containing a key and value field
* @param {Object} [scope=this] scope to call the function in
*
* @returns {Boolean} True if every item passed false otherwise
*/
every : function() {
var es = this.__entrySet();
return es.every.apply(es, arguments);
},
/**
* Determines if every item meets the condition returned by the callback.
*
* @param {Function} cb Function to callback with each item, the first aruguments is an object containing a key and value field
* @param {Object} [scope=this] scope to call the function in
*
* @returns {Boolean} True if every item passed false otherwise
*/
every:function () {
var es = this.__entrySet();
return es.every.apply(es, arguments);
},
/**
* Loop through each value in the hashtable, collecting the value returned by the callback function.
* @param {Function} cb Function to callback with each item, the first aruguments is an object containing a key and value field
* @param {Object} [scope=this] scope to call the function in
*
* @returns {Array} an array containing the mapped values.
*/
map : function() {
var es = this.__entrySet(), ret = new HashTable();
return es.map.apply(es, arguments);
},
/**
* Loop through each value in the hashtable, collecting the value returned by the callback function.
* @param {Function} cb Function to callback with each item, the first aruguments is an object containing a key and value field
* @param {Object} [scope=this] scope to call the function in
*
* @returns {Array} an array containing the mapped values.
*/
map:function () {
var es = this.__entrySet(), ret = new this._static();
return es.map.apply(es, arguments);
},
/**
* Determines if some items meet the condition returned by the callback.
*
* @param {Function} cb Function to callback with each item, the first aruguments is an object containing a key and value field
* @param {Object} [scope=this] scope to call the function in
*
* @returns {Boolean} True if some items passed false otherwise
*/
some : function() {
var es = this.__entrySet();
return es.some.apply(es, arguments);
},
/**
* Determines if some items meet the condition returned by the callback.
*
* @param {Function} cb Function to callback with each item, the first aruguments is an object containing a key and value field
* @param {Object} [scope=this] scope to call the function in
*
* @returns {Boolean} True if some items passed false otherwise
*/
some:function () {
var es = this.__entrySet();
return es.some.apply(es, arguments);
},
/**
* Apply a function against an accumulator and each value of the array (from left-to-right) as to reduce it to a single value.
*
* @param {Function} callback Function to execute on each value in the array.
* @param initialValue Value to use as the first argument to the first call of the callback..
*/
reduce : function() {
var es = this.__entrySet();
return es.reduce.apply(es, arguments);
},
/**
* Apply a function against an accumulator and each value of the array (from left-to-right) as to reduce it to a single value.
*
* @param {Function} callback Function to execute on each value in the array.
* @param initialValue Value to use as the first argument to the first call of the callback..
*/
reduce:function () {
var es = this.__entrySet();
return es.reduce.apply(es, arguments);
},
/**
* Apply a function against an accumulator and each value of the array (from right-to-left) as to reduce it to a single value.
*
* @param {Function} callback Function to execute on each value in the array.
* @param initialValue Value to use as the first argument to the first call of the callback..
*/
reduceRight : function() {
var es = this.__entrySet();
return es.reduceRight.apply(es, arguments);
},
/**
* Apply a function against an accumulator and each value of the array (from right-to-left) as to reduce it to a single value.
*
* @param {Function} callback Function to execute on each value in the array.
* @param initialValue Value to use as the first argument to the first call of the callback..
*/
reduceRight:function () {
var es = this.__entrySet();
return es.reduceRight.apply(es, arguments);
},
/**
* Clears out all items from the table.
*/
clear : function() {
this.__map = {};
},
/**
* Clears out all items from the table.
*/
clear:function () {
this.__map = {};
},
getters : {
keys : function() {
var ret = [], es = [];
for (var i in this.__map) {
this.__map[i].getKeys(ret);
}
return ret;
},
getters:{
keys:function () {
var ret = [], es = [];
for (var i in this.__map) {
this.__map[i].getKeys(ret);
}
return ret;
},
values : function() {
var ret = [], es = [];
for (var i in this.__map) {
this.__map[i].getValues(ret);
}
return ret;
},
values:function () {
var ret = [], es = [];
for (var i in this.__map) {
this.__map[i].getValues(ret);
}
return ret;
},
entrySet : function() {
return this.__entrySet();
},
entrySet:function () {
return this.__entrySet();
},
isEmpty : function() {
return this.keys.length == 0;
}
}
isEmpty:function () {
return this.keys.length == 0;
}
}
}
});
}).as(module);
var comb = exports;
/**@namespace Various collections*/
/**
* @ignore
* @namespace Various collections*/
comb.collections = {

@@ -4,0 +6,0 @@ Collection : require("./Collection"),

var define = require("../define").define,
base = require("../base");
base = require("../base");
/**
* @ignoreCode
* @class Base class for all collections

@@ -9,4 +10,4 @@ * @name Iterable

*/
var Iterable = define(null, {
instance : {
define(null, {
instance:{
/**@lends comb.collections.Iterable.prototype*/

@@ -17,3 +18,3 @@

*/
filter : function(){
filter:function () {
throw new Error("Not Implemented");

@@ -25,3 +26,3 @@ },

*/
forEach : function(){
forEach:function () {
throw new Error("Not Implemented");

@@ -33,3 +34,3 @@ },

*/
every : function(){
every:function () {
throw new Error("Not Implemented");

@@ -41,3 +42,3 @@ },

*/
map : function(){
map:function () {
throw new Error("Not Implemented");

@@ -49,3 +50,3 @@ },

*/
some : function(){
some:function () {
throw new Error("Not Implemented");

@@ -57,3 +58,3 @@ },

*/
reduce : function(){
reduce:function () {
throw new Error("Not Implemented");

@@ -65,8 +66,6 @@ },

*/
reduceRight : function(){
reduceRight:function () {
throw new Error("Not Implemented");
}
}
});
module.exports = exports = Iterable;
}).as(module);

@@ -6,2 +6,4 @@ var define = require("../define").define,

/**
* @ignoreCode
*
* @class <p> Max Heap implementation, lowest value in heap is always at the root.</p>

@@ -8,0 +10,0 @@ * </br>

@@ -20,2 +20,3 @@ var define = require("../define").define,

* @memberOf comb.collections
* @ignoreCode
*/

@@ -22,0 +23,0 @@ module.exports = exports = define(Heap, {

@@ -17,3 +17,3 @@ var define = require("../define").define,

* @property {Number} [maxObjects=1] the maximum number of objects this pool should contain
* @ignoreCode
*/

@@ -20,0 +20,0 @@ exports = module.exports = define(null, {

@@ -9,4 +9,6 @@ var define = require("../define").define,

* Priority starts at 0, and the greatest value being the lowest priority;
* @name PriorityQueue
* @augments comb.collections.MinHeap
* @memberOf comb.collections
* @ignoreCode
*/

@@ -13,0 +15,0 @@ PriorityQueue = define(MinHeap, {

@@ -14,2 +14,3 @@ var define = require("../define").define,

* @property {Array} values a copy of the values contained in this queue
* @ignoreCode
*/

@@ -16,0 +17,0 @@ module.exports = exports = define(Collection, {

@@ -152,2 +152,3 @@ var define = require("../define").define,

* @memberOf comb.collections
* @ignoreCode
*/

@@ -154,0 +155,0 @@ module.exports = exports = define(Tree, {

@@ -14,2 +14,3 @@ var define = require("../define").define,

* @property {Array} values a copy of the values contained in this queue
* @ignoreCode
*/

@@ -16,0 +17,0 @@ module.exports = exports = define(Collection, {

@@ -97,7 +97,10 @@ /**

var child = this.prototype, childMeta = child.__meta, thisMeta = this.__meta, bases = child.__meta.bases, staticBases = bases.slice(),
staticSupers = thisMeta.supers, supers = childMeta.supers;
staticSupers = thisMeta.supers || [], supers = childMeta.supers|| [];
for (var i = 0; i < l; i++) {
var m = args[i];
defineMixinProps(child, m.prototype.__meta.proto);
defineMixinProps(this, m.__meta.proto);
var m = args[i], mProto = m.prototype;
var protoMeta = mProto.__meta, meta = m.__meta;
!protoMeta && (protoMeta = (mProto.__meta = {proto :mProto || {}}));
!meta && (meta = (m.__meta = {proto :m.__proto__ || {}}));
defineMixinProps(child, protoMeta.proto || {});
defineMixinProps(this, meta.proto || {});
//copy the bases for static,

@@ -453,2 +456,5 @@

*
* @name define
* @memberOf comb
*
* @param {Array|Class} super the supers of this class

@@ -474,3 +480,3 @@ * @param {Object} [proto] the object used to define this class

/**
* Defines a singleton instance of a Class
* Defines a singleton instance of a Class. See {@link define}
* @example

@@ -484,3 +490,7 @@ * var MyLab = comb.singleton([Mammal, Wolf, Dog, Breed]);

* myLab2.type => "collie"
* See {@link define}
*
*
* @name singleton
* @memberOf comb
*/

@@ -487,0 +497,0 @@ exports.singleton = function (sup, proto) {

var base = require("./base");
/**
* @projectName comb
*
* @github https://github.com/Pollenware/comb
*
* @header
*
* <h1>Comb</h1>
*
* <h2>Overview</h2>
*
* <p>Framework for node that provides a one stop shop for frequently needed utilities, including:</p>
*
* <ul>
* <li>OO utilties</li>
* <li>Collections</li>
* <li>Logging</li>
* <li>String &amp; date formatting</li>
* <li>Flow control</li>
* <li>Date Management</li>
* </ul>
*
*
* <p>See Usage for more details.</p>
*
* <h2>Installation</h2>
*
* <pre><code>npm install comb
* </code></pre>
*
* <h2>Why?</h2>
*
* <p>If your like us its fun to find new modules to use but often wish you didn&rsquo;t have to sift through NPM registry
* or the node modules page to find what you need.</p>
*
* <p> So&hellip;.</p>
*
* <p>We created a library of things we use often, or commons utilities that are used by our other APIs.</p>
*
* <h2>Highlights</h2>
*
* <ul>
* <li>&gt; 99% test coverage! And we&rsquo;re always adding more!</li>
* <li>comb(<a href="./comb.html#.define">define</a>|<a
* href="./comb.html#.singleton">singleton</a>)
*
* <ul>
* <li>The back bone of comb.</li>
* <li>Options for classical inheritance models as well as mixins(pseudo multi-inheritance)</li>
* <li>You can call this._super from any method. Including statically defined ones!</li>
* <li>Access to you class level properties within an instance</li>
* <li>And <a href="./comb.html#.define">much more&hellip;</a></li>
* </ul>
* </li>
* <li>Logging
*
* <ul>
* <li><a href="http://pollenware.github.com/comb_logging_Logger.html">Powerful logging API!</a></li>
* <li>Logger inheritance through name spaces</li>
* <li><a href="./comb_logging_Level.html">Predefined level definition along
* with the ability to define your own.</a></li>
* <li>Multiple appenders including
*
* <ul>
* <li><a href="./comb_logging_appenders_FileAppender.html">FileAppender</a>
* - log it to a file
* </li>
* <li><a href="./comb_logging_appenders_RollingFileAppender.html">RollingFileAppender</a>
* - log it to a file up to a customizable size then create a new one!
* </li>
* <li><a href="./comb_logging_appenders_JSONAppender.html">JSONAppender</a>
* - write it out as JSON to a file.
* </li>
* <li><a href="./comb_logging_appenders_ConsoleAppender.html">ConsoleAppender</a>
* - log it to the console
* </li>
* </ul>
* </li>
* <li>All appenders can be using with custom levels, separately, or all together.</li>
* <li>Configurable with <a href="./comb_logging_BasicConfigurator.html">files
* OR programatically</a></li>
* </ul>
* </li>
* <li>Collections
*
* <ul>
* <li><a href="./comb_collections_RedBlackTree.html">RedBlackTree</a>, <a
* href="./comb_collections_AVLTree.html">AVLTree</a>, <a
* href="./comb_collections_AnderssonTree.html">AnderssonTree</a>, <a
* href="./comb_collections_BinaryTree.html">BinaryTree</a>, <a
* href="./comb_collections_HashTable.html">HashTable</a>, <a
* href="./comb_collections_MaxHeap.html">MaxHeap</a>, <a
* href="./comb_collections_MinHeap.html">MinHeap</a>, <a
* href="./comb_collections_Pool.html">Pool</a>, <a
* href="./comb_collections_PriorityQueue.html">PriorityQueue</a>, <a
* href="./comb_collections_Queue.html">Queue</a>, <a
* href="./comb_collections_Stack.html">Stack</a></li>
* </ul>
* </li>
* <li>Flow control
*
* <ul>
* <li><a href="./comb_Promise.html">Promises</a></li>
* <li><a href="./comb.PromiseList.html">PromiseLists</a></li>
* </ul>
* </li>
* <li><a href="./comb.html">Tell me more!</a></li>
* </ul>
*
*
* <h2>Usage</h2>
*
* <ul>
* <li>OO system
*
* <ul>
* <li><a href="./comb.html#.define">define</a></li>
* <li><a href="./comb.html#.singleton">singleton</a></li>
* </ul>
* </li>
* <li>Collections
*
* <ul>
* <li><a href="./comb_collections_RedBlackTree.html">RedBlackTree</a></li>
* <li><a href="./comb_collections_AVLTree.html">AVLTree</a></li>
* <li><a href="./comb_collections_AnderssonTree.html">AnderssonTree</a></li>
* <li><a href="./comb_collections_BinaryTree.html">BinaryTree</a></li>
* <li><a href="./comb_collections_HashTable.html">HashTable</a></li>
* <li><a href="./comb_collections_MaxHeap.html">MaxHeap</a></li>
* <li><a href="./comb_collections_MinHeap.html">MinHeap</a></li>
* <li><a href="./comb_collections_Pool.html">Pool</a></li>
* <li><a href="./comb_collections_PriorityQueue.html">PriorityQueue</a></li>
* <li><a href="./comb_collections_Queue.html">Queue</a></li>
* <li><a href="./comb_collections_Stack.html">Stack</a></li>
* </ul>
* </li>
* <li>Logging
*
* <ul>
* <li><a href="./comb_logging_Logger.html">Logger</a></li>
* <li><a href="./comb_logging_Level.html">Level</a></li>
* <li>Appenders
*
* <ul>
* <li><a href="./comb_logging_appenders_Appender.html">Appender</a>
* </li>
* <li><a href="./comb_logging_appenders_ConsoleAppender.html">ConsoleAppender</a>
* </li>
* <li><a href="./comb_logging_appenders_FileAppender.html">FileAppender</a>
* </li>
* <li><a href="./comb_logging_appenders_JSONAppender.html">JSONAppender</a>
* </li>
* <li><a href="./comb_logging_appenders_RollingFileAppender.html">RollingFileAppender</a>
* </li>
* </ul>
* </li>
* <li>Configurators
*
* <ul>
* <li><a href="./comb_logging_BasicConfigurator.html">BasicConfigurator</a>
* </li>
* <li><a href="./comb_logging_PropertyConfigurator.html">PropertyConfigurator</a>
* </li>
* </ul>
* </li>
* </ul>
* </li>
* <li>Plugins for objects defined with comb
*
* <ul>
* <li><a href="./comb_plugins_Broadcaster.html">Broadcaster</a></li>
* <li><a href="./comb_plugins_Middleware.html">Middleware </a></li>
* </ul>
* </li>
* <li><a href="./comb.Promise.html">Promises</a></li>
* <li><a href="./comb.PromiseList.html">PromiseLists</a></li>
* <li>Utilities
*
* <ul>
* <li><a href="./comb.html">comb</a></li>
* <li><a href="./comb_array.html">Array</a></li>
* <li><a href="./comb_date.html">Date</a></li>
* <li><a href="./comb_number.html">Number</a></li>
* <li><a href="./comb_regexp.html">Regexp</a></li>
* <li><a href="./comb_string.html">String</a></li>
* <li><a href="./comb_characters.html">Characters</a></li>
* </ul>
* </li>
* </ul>
*
*
* <h2>License</h2>
*
* <p>MIT <a href="https://github.com/Pollenware/comb/raw/master/LICENSE">https://github.com/Pollenware/comb/raw/master/LICENSE</a>
* </p>
*
* <h2>Meta</h2>
*
* <ul>
* <li>Code: <code>git clone git://github.com/Pollenware/comb.git</code></li>
* <li>JsDoc: <a href="http://pollenware.github.com/comb">http://pollenware.github.com/comb</a></li>
* <li>Website: <a href="http://pollenware.com">http://pollenware.com</a> - Twitter: <a
* href="http://twitter.com/pollenware">http://twitter.com/pollenware</a> - 877.465.4045
* </li>
* </ul>
*
*/
/**
* Utilities for javascript, optimized for the server environment.

@@ -5,0 +213,0 @@ *

@@ -29,82 +29,83 @@ var define = require("../../define.js").define, base = require("../../base"), Level = require("../level");

* @property {comb.logging.Level} level the level of this Appender.
* @ignoreCode
*/
var Appender = (exports = module.exports = define(null, {
instance : {
/**@lends comb.logging.appenders.Appender.prototype*/
define(null, {
instance:{
/**@lends comb.logging.appenders.Appender.prototype*/
constructor : function(options) {
options = options || {};
this.name = options.name || "appender";
this.pattern = options.pattern || "[{[yyyy-MM-ddTHH:mm:ss:SSS (z)]timeStamp}] {[- 5]levelName} {[-20]name} - {message}";
var level = options.level;
if(options.level && (level = Level.toLevel(level))){
this.__level = level;
}
},
constructor:function (options) {
options = options || {};
this.name = options.name || "appender";
this.pattern = options.pattern || "[{[yyyy-MM-ddTHH:mm:ss:SSS (z)]timeStamp}] {[- 5]levelName} {[-20]name} - {message}";
var level = options.level;
if (options.level && (level = Level.toLevel(level))) {
this.__level = level;
}
},
/**
* Appends a message to a log.
* <b>This method is abstract and must be implemented in subclasses</b>
* @param {Object} event the logging event to log.
* @param {Date} event.timeStamp the timeStamp of the event.
* @param {comb.logging.Level} level the level of the event.
* @param {String} name the name of the logger the event was emitted from.
* @param {String} message the message that is being logged.
*
*/
append : function(event) {
throw new Error("abstract method");
},
/**
* Appends a message to a log.
* <b>This method is abstract and must be implemented in subclasses</b>
* @param {Object} event the logging event to log.
* @param {Date} event.timeStamp the timeStamp of the event.
* @param {comb.logging.Level} level the level of the event.
* @param {String} name the name of the logger the event was emitted from.
* @param {String} message the message that is being logged.
*
*/
append:function (event) {
throw new Error("abstract method");
},
_canAppend : function(event) {
return !base.isUndefinedOrNull(this.__level) && event.level.isGreaterOrEqualToo(this.__level);
},
_canAppend:function (event) {
return !base.isUndefinedOrNull(this.__level) && event.level.isGreaterOrEqualToo(this.__level);
},
/**@ignore*/
setters : {
/**@ignore*/
/**@ignore*/
setters:{
/**@ignore*/
level : function(level) {
if (level && level instanceof Level) {
this.__level = level;
} else {
//try to get the level
level = Level.toLevel(level);
if (level) {
this.__level = level;
}
}
},
level:function (level) {
if (level && level instanceof Level) {
this.__level = level;
} else {
//try to get the level
level = Level.toLevel(level);
if (level) {
this.__level = level;
}
}
},
pattern : function(patt){
if(base.isString(patt)){
this.__pattern = patt;
}
},
pattern:function (patt) {
if (base.isString(patt)) {
this.__pattern = patt;
}
},
name : function(name){
if(base.isString(name)){
this.__name = name;
}
}
},
name:function (name) {
if (base.isString(name)) {
this.__name = name;
}
}
},
/**@ignore*/
getters : {
/**@ignore*/
/**@ignore*/
getters:{
/**@ignore*/
level : function() {
return this.__level;
},
level:function () {
return this.__level;
},
name : function() {
return this.__name;
},
name:function () {
return this.__name;
},
pattern : function(){
return this.__pattern;
}
}
}
pattern:function () {
return this.__pattern;
}
}
}
}));
}).as(module);

@@ -18,8 +18,8 @@ var define = require("../../define.js").define,

*
* <pre class="code">
* var fileAppender = new comb.logging.appenders.FileAppender({
* file : "/var/log/myLog.log"
* });
* </pre>
* @example
* var fileAppender = new comb.logging.appenders.FileAppender({
* file : "/var/log/myLog.log"
* });
*
*
* @name FileAppender

@@ -49,3 +49,3 @@ * @augments comb.logging.appenders.Appender

* @param {Boolean} [options.overwrite=false] if true the log file is overwritten otherwise it is appended to.
*
* @ignoreCode
*/

@@ -52,0 +52,0 @@ exports = module.exports = define(Appender, {

var define = require("../../define.js").define,
base = require("../../base"),
string = base.string,
escape = base.regexp.escapeString,
FileAppender = require("./fileAppender"),
format = string.format,
Level = require("../level"),
fs = require("fs");
base = require("../../base"),
string = base.string,
escape = base.regexp.escapeString,
FileAppender = require("./fileAppender"),
format = string.format,
Level = require("../level"),
fs = require("fs");

@@ -15,3 +15,3 @@

*
* <pre class="code">
* @example
* //example log.json

@@ -27,3 +27,2 @@ * [

*
*</pre>
*

@@ -53,35 +52,37 @@ * @name JSONAppender

* @param {String} [options.encoding="utf8"] the encoding of the file.
*
* @ignoreCode
*/
exports = module.exports = define(FileAppender, {
instance : {
define(FileAppender, {
instance:{
constructor : function(options) {
options = options || {};
this.name = options.name || "JSONAppender";
this.__count = 0;
this.__file = options.file || "./log.json";
this.__encoding = options.encoding || "utf8";
this.__writeStream = options.writeStream || fs.createWriteStream(this.__file, { flags: "w", encoding: this.__encoding});
this.__writeStream.write("[\n");
this.level = options.level;
//explicit overwrite of patter
this.__pattern = '{"timestamp" : "{timeStamp}", "level" : "{levelName}", "name" : "{name}", "message" : "{message}"}';
base.listenForExit(base.hitch(this, "__onExit"));
},
constructor:function (options) {
options = options || {};
this.name = options.name || "JSONAppender";
this.__count = 0;
this.__file = options.file || "./log.json";
this.__encoding = options.encoding || "utf8";
this.__writeStream = options.writeStream || fs.createWriteStream(this.__file, { flags:"w", encoding:this.__encoding});
this.__writeStream.write("[\n");
this.level = options.level;
//explicit overwrite of patter
this.__pattern = '{"timestamp" : "{timeStamp}", "level" : "{levelName}", "name" : "{name}", "message" : "{message}"}';
base.listenForExit(base.hitch(this, "__onExit"));
},
append : function(event) {
if (this._canAppend(event)) {
event.message = event.message.replace(/\n+/g, "\\n");
var message = (this.__count ? ",\n" : "\n") + format(this.__pattern, event);
this.__writeStream.write(message);
this.__count++;
}
},
append:function (event) {
if (this._canAppend(event)) {
event.message = event.message.replace(/\n+/g, "\\n");
var message = (this.__count ? ",\n" : "\n") + format(this.__pattern, event);
this.__writeStream.write(message);
this.__count++;
}
},
__onExit : function() {
this.__writeStream.write("]");
this._super(arguments);
}
}
});
__onExit:function () {
this.__writeStream.write("]");
this._super(arguments);
}
}
}).as(module);

@@ -34,8 +34,8 @@ var define = require("../../define.js").define,

* @class Appends messages to a file. Rolls files over when a size limit has been reached. Once the max file size has
* been reached it is rolled over to a file called <logName>.log.n where n is a number.
*
* been reached it is rolled over to a file called &lt;logName&gt;.log.n where n is a number.
* </br></br>
* <p>Example. RollingFileAppender is current writing to myLog.log, the log reaches is max size to it is
* renamed to myLog.log.1 and a new myLog.log is created.</p>
*
* <p>If maxBackupIndex is reached then the log at that index is deleted. If maxBackupIndex is set to 0 then no log is
* </br>
* If maxBackupIndex is reached then the log at that index is deleted. If maxBackupIndex is set to 0 then no log is
* rolled over.</p>

@@ -42,0 +42,0 @@ *

@@ -33,3 +33,3 @@ var define = require("../define.js").define, base = require("../base"), fs = require('fs');

for (var j = appenderArr.length - 1; j >= 0; j--) {
var appenderProps = appenderArr[j], type = appenderProps.type;
var appenderProps = base.merge({}, appenderArr[j]), type = appenderProps.type;
appenderProps.type = null;

@@ -69,2 +69,3 @@ if (type) {

* @memberOf comb.logging
* @ignoreCode
*

@@ -158,2 +159,3 @@ */

* @memberOf comb.logging
* @ignoreCode
*

@@ -213,3 +215,3 @@ */

if (base.isHash(properties)) {
parseProperties(properties);
parseProperties(base.deepMerge({}, properties));
} else {

@@ -216,0 +218,0 @@ fs.readFile(properties, function (err, res) {

@@ -137,7 +137,11 @@ var define = require("../define.js"),

var comb = exports;
/**@namespace logging package*/
/**
* @ignore
* @namespace logging package*/
comb.logging = base.merge({
Level:Level
}, configurators);
/**@namespace appenders for logging*/
/**
* @ignore
* @namespace appenders for logging*/
comb.logging.appenders = appenders;

@@ -227,2 +231,3 @@

* @property {comb.logging.appenders.Appender} appenders list of appenders this logger currently contains.
* @ignoreCode
*/

@@ -229,0 +234,0 @@ var Logger = (logging.Logger = define.define(null, {

@@ -50,2 +50,3 @@ var define = require("../define.js").define, base = require("../base");

* @property {String} name the name of level.
* @ignoreCode
*/

@@ -52,0 +53,0 @@ var Level = (exports = module.exports = define(null, {

@@ -44,3 +44,2 @@ var hitch = require("./base/functions").hitch,

* myFunc2.chain(myfunc).addCallback(do something...)
* @memberOf comb
* @constructs

@@ -587,3 +586,3 @@ */

try {
when(base.isFunction(item) ? item() : item,
when(base.isFunction(item) ? item() : item).then(
base.partial(callNextSuccess, list, index, results, isErrored, ret),

@@ -590,0 +589,0 @@ base.partial(callNextError, index, results, isErrored, ret));

{
"name": "comb",
"description": "A framework for node",
"version": "0.1.1",
"version": "0.1.2",
"keywords" : ["OO", "Object Oriented", "Collections", "Tree", "HashTable", "Pool", "Logging", "Promise", "Promises", "Proxy"],
"repository": {
"type": "git",
"url": "git@github.com:Pollen/comb.git"
"url": "git@github.com:Pollenware/comb.git"
},

@@ -10,0 +10,0 @@ "homepage": "http://pollenware.github.com/comb/symbols/comb.html",

@@ -1,9 +0,8 @@

Comb
=========
#Comb
##NOTE: v0.1.1 removed proxy code out of core see [comb-proxy](http://github.com/Pollenware/comb-proxy)
Overview
--------
###NOTE: v0.1.1 removed proxy code out of core see [comb-proxy](http://github.com/Pollenware/comb-proxy)
##Overview
Framework for node that provides a one stop shop for frequently needed utilities, including:

@@ -25,5 +24,5 @@

Why?
----
##Why?
If your like us its fun to find new modules to use but often wish you didn't have to sift through NPM registry or the node modules page to find what you need.

@@ -35,7 +34,6 @@

Highlights
---------
* > 99% test coverage! And we're always adding more!
* [Full api documentation with examples!](http://pollenware.github.com/comb/symbols/comb.html)
* comb([define](http://pollenware.github.com/comb/symbols/comb.html#.define)|[singleton](http://pollenware.github.com/comb/symbols/comb.html#.singleton))
##Highlights
* &gt; 99% test coverage! And we're always adding more!
* comb([define](http://pollenware.github.com/comb/comb.html#.define)|[singleton](http://pollenware.github.com/comb/comb.html#.singleton))
* The back bone of comb.

@@ -45,77 +43,77 @@ * Options for classical inheritance models as well as mixins(pseudo multi-inheritance)

* Access to you class level properties within an instance
* And [much more...](http://pollenware.github.com/comb/symbols/comb.html#.define)
* And [much more...](http://pollenware.github.com/comb/comb.html#.define)
* Logging
* [Powerful logging API!](http://pollenware.github.com/comb/symbols/comb.logging.Logger.html)
* [Powerful logging API!](http://pollenware.github.com/comb_logging_Logger.html)
* Logger inheritance through name spaces
* [Predefined level definition along with the ability to define your own.](http://pollenware.github.com/comb/symbols/comb.logging.Level.html)
* [Predefined level definition along with the ability to define your own.](http://pollenware.github.com/comb/comb_logging_Level.html)
* Multiple appenders including
* [FileAppender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.FileAppender.html) - log it to a file
* [RollingFileAppender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.RollingFileAppender.html) - log it to a file up to a customizable size then create a new one!
* [JSONAppender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.JSONAppender.html) - write it out as JSON to a file.
* [ConsoleAppender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.ConsoleAppender.html) - log it to the console
* [FileAppender](http://pollenware.github.com/comb/comb_logging_appenders_FileAppender.html) - log it to a file
* [RollingFileAppender](http://pollenware.github.com/comb/comb_logging_appenders_RollingFileAppender.html) - log it to a file up to a customizable size then create a new one!
* [JSONAppender](http://pollenware.github.com/comb/comb_logging_appenders_JSONAppender.html) - write it out as JSON to a file.
* [ConsoleAppender](http://pollenware.github.com/comb/comb_logging_appenders_ConsoleAppender.html) - log it to the console
* All appenders can be using with custom levels, separately, or all together.
* Configurable with [files OR programatically](http://pollenware.github.com/comb/symbols/comb.logging.BasicConfigurator.html)
* Configurable with [files OR programatically](http://pollenware.github.com/comb/comb_logging_BasicConfigurator.html)
* Collections
* [RedBlackTree](http://pollenware.github.com/comb/symbols/comb.collections.RedBlackTree.html), [AVLTree](http://pollenware.github.com/comb/symbols/comb.collections.AVLTree.html), [AnderssonTree](http://pollenware.github.com/comb/symbols/comb.collections.AnderssonTree.html), [BinaryTree](http://pollenware.github.com/comb/symbols/comb.collections.BinaryTree.html), [HashTable](http://pollenware.github.com/comb/symbols/comb.collections.HashTable.html), [MaxHeap](http://pollenware.github.com/comb/symbols/comb.collections.MaxHeap.html), [MinHeap](http://pollenware.github.com/comb/symbols/comb.collections.MinHeap.html), [Pool](http://pollenware.github.com/comb/symbols/comb.collections.Pool.html), [PriorityQueue](http://pollenware.github.com/comb/symbols/comb.collections.PriorityQueue.html), [Queue](http://pollenware.github.com/comb/symbols/comb.collections.Queue.html), [Stack](http://pollenware.github.com/comb/symbols/comb.collections.Stack.html)
* [RedBlackTree](http://pollenware.github.com/comb/comb_collections_RedBlackTree.html), [AVLTree](http://pollenware.github.com/comb/comb_collections_AVLTree.html), [AnderssonTree](http://pollenware.github.com/comb/comb_collections_AnderssonTree.html), [BinaryTree](http://pollenware.github.com/comb/comb_collections_BinaryTree.html), [HashTable](http://pollenware.github.com/comb/comb_collections_HashTable.html), [MaxHeap](http://pollenware.github.com/comb/comb_collections_MaxHeap.html), [MinHeap](http://pollenware.github.com/comb/comb_collections_MinHeap.html), [Pool](http://pollenware.github.com/comb/comb_collections_Pool.html), [PriorityQueue](http://pollenware.github.com/comb/comb_collections_PriorityQueue.html), [Queue](http://pollenware.github.com/comb/comb_collections_Queue.html), [Stack](http://pollenware.github.com/comb/comb_collections_Stack.html)
* Flow control
* [Promises](http://pollenware.github.com/comb/symbols/comb.Promise.html)
* [PromiseLists](http://pollenware.github.com/comb/symbols/comb.PromiseList.html)
* [Tell me more!](http://pollenware.github.com/comb/symbols/comb.html)
* [Promises](http://pollenware.github.com/comb/comb_Promise.html)
* [PromiseLists](http://pollenware.github.com/comb/comb_PromiseList.html)
* [Tell me more!](http://pollenware.github.com/comb/comb.html)
Usage
-----
##Usage
* OO system
* [define](http://pollenware.github.com/comb/symbols/comb.html#.define)
* [singleton](http://pollenware.github.com/comb/symbols/comb.html#.singleton)
* [define](http://pollenware.github.com/comb/comb.html#.define)
* [singleton](http://pollenware.github.com/comb/comb.html#.singleton)
* Collections
* [RedBlackTree](http://pollenware.github.com/comb/symbols/comb.collections.RedBlackTree.html)
* [AVLTree](http://pollenware.github.com/comb/symbols/comb.collections.AVLTree.html)
* [AnderssonTree](http://pollenware.github.com/comb/symbols/comb.collections.AnderssonTree.html)
* [BinaryTree](http://pollenware.github.com/comb/symbols/comb.collections.BinaryTree.html)
* [HashTable](http://pollenware.github.com/comb/symbols/comb.collections.HashTable.html)
* [MaxHeap](http://pollenware.github.com/comb/symbols/comb.collections.MaxHeap.html)
* [MinHeap](http://pollenware.github.com/comb/symbols/comb.collections.MinHeap.html)
* [Pool](http://pollenware.github.com/comb/symbols/comb.collections.Pool.html)
* [PriorityQueue](http://pollenware.github.com/comb/symbols/comb.collections.PriorityQueue.html)
* [Queue](http://pollenware.github.com/comb/symbols/comb.collections.Queue.html)
* [Stack](http://pollenware.github.com/comb/symbols/comb.collections.Stack.html)
* [RedBlackTree](http://pollenware.github.com/comb/comb_collections_RedBlackTree.html)
* [AVLTree](http://pollenware.github.com/comb/comb_collections_AVLTree.html)
* [AnderssonTree](http://pollenware.github.com/comb/comb_collections_AnderssonTree.html)
* [BinaryTree](http://pollenware.github.com/comb/comb_collections_BinaryTree.html)
* [HashTable](http://pollenware.github.com/comb/comb_collections_HashTable.html)
* [MaxHeap](http://pollenware.github.com/comb/comb_collections_MaxHeap.html)
* [MinHeap](http://pollenware.github.com/comb/comb_collections_MinHeap.html)
* [Pool](http://pollenware.github.com/comb/comb_collections_Pool.html)
* [PriorityQueue](http://pollenware.github.com/comb/comb_collections_PriorityQueue.html)
* [Queue](http://pollenware.github.com/comb/comb_collections_Queue.html)
* [Stack](http://pollenware.github.com/comb/comb_collections_Stack.html)
* Logging
* [Logger](http://pollenware.github.com/comb/symbols/comb.logging.Logger.html)
* [Level](http://pollenware.github.com/comb/symbols/comb.logging.Level.html)
* [Logger](http://pollenware.github.com/comb/comb_logging_Logger.html)
* [Level](http://pollenware.github.com/comb/comb_logging_Level.html)
* Appenders
* [Appender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.Appender.html)
* [ConsoleAppender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.ConsoleAppender.html)
* [FileAppender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.FileAppender.html)
* [JSONAppender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.JSONAppender.html)
* [RollingFileAppender](http://pollenware.github.com/comb/symbols/comb.logging.appenders.RollingFileAppender.html)
* [Appender](http://pollenware.github.com/comb/comb_logging_appenders_Appender.html)
* [ConsoleAppender](http://pollenware.github.com/comb/comb_logging_appenders_ConsoleAppender.html)
* [FileAppender](http://pollenware.github.com/comb/comb_logging_appenders_FileAppender.html)
* [JSONAppender](http://pollenware.github.com/comb/comb_logging_appenders_JSONAppender.html)
* [RollingFileAppender](http://pollenware.github.com/comb/comb_logging_appenders_RollingFileAppender.html)
* Configurators
* [BasicConfigurator](http://pollenware.github.com/comb/symbols/comb.logging.BasicConfigurator.html)
* [PropertyConfigurator](http://pollenware.github.com/comb/symbols/comb.logging.PropertyConfigurator.html)
* [BasicConfigurator](http://pollenware.github.com/comb/comb_logging_BasicConfigurator.html)
* [PropertyConfigurator](http://pollenware.github.com/comb/comb_logging_PropertyConfigurator.html)
* Plugins for objects defined with comb
* [Broadcaster](http://pollenware.github.com/comb/symbols/comb.plugins.Broadcaster.html)
* [Middleware ](http://pollenware.github.com/comb/symbols/comb.plugins.Middleware.html)
* [Promises](http://pollenware.github.com/comb/symbols/comb.Promise.html)
* [PromiseLists](http://pollenware.github.com/comb/symbols/comb.PromiseList.html)
* [Broadcaster](http://pollenware.github.com/comb/comb_plugins_Broadcaster.html)
* [Middleware ](http://pollenware.github.com/comb/comb_plugins_Middleware.html)
* [Promises](http://pollenware.github.com/comb/comb_Promise.html)
* [PromiseLists](http://pollenware.github.com/comb/comb_PromiseList.html)
* Utilities
* [comb](http://pollenware.github.com/comb/symbols/comb.html)
* [Array](http://pollenware.github.com/comb/symbols/comb.array.html)
* [Date](http://pollenware.github.com/comb/symbols/comb.date.html)
* [Number](http://pollenware.github.com/comb/symbols/comb.number.html)
* [Regexp](http://pollenware.github.com/comb/symbols/comb.regexp.html)
* [String](http://pollenware.github.com/comb/symbols/comb.string.html)
* [Characters](http://pollenware.github.com/comb/symbols/comb.characters.html)
* [comb](http://pollenware.github.com/comb/comb.html)
* [Array](http://pollenware.github.com/comb/comb_array.html)
* [Date](http://pollenware.github.com/comb/comb_date.html)
* [Number](http://pollenware.github.com/comb/comb_number.html)
* [Regexp](http://pollenware.github.com/comb/comb_regexp.html)
* [String](http://pollenware.github.com/comb/comb_string.html)
* [Characters](http://pollenware.github.com/comb/comb_characters.html)
License
-------
##License
MIT <https://github.com/Pollenware/comb/raw/master/LICENSE>
Meta
----
##Meta
* Code: `git clone git://github.com/pollenware/comb.git`
* Code: `git clone git://github.com/Pollenware/comb.git`
* JsDoc: <http://pollenware.github.com/comb>
* Website: <http://pollenware.com> - Twitter: <http://twitter.com/pollenware> - 877.465.4045
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc