JavaScript Partitioning

I have 255 changes to the basic JavaScript, the first change, should be, get rid of the concept of an API


Partitions of objects

Partitioning permits any object to be divided both vertically and horizontally across multiple machines and in different formats both logically and physically.

Vertical partitions to group properties of an object (still just one object)

figured 1:

01	a = {index.name:'clif',index.id:1,age:12,dob:'',address:'','phone:''};
02
03	b = a.index;  	// b = {name:'clif',id:1}
04	c = a;        	// c = {name:'clif',id:1,age:12,dob:'',address:'',phone:''}; 
05	d = a.default;	// d = {age:12,dob:'',address:'',phone:''};

a~verticalPartitions.index 	= ['name','id'];
a~verticalPartitions.default 	= ['age','dob','address','phone'];

 

Horizontal partitions to define a group of rows in an Array, Matrix, or Table

figure 2:

01	a  = new Array();
02	a.~.horizontalPartition = function(){ return 
03		this.state + '.' +
04		this.county +'.' + 
06		this.school;
07	};
08
09	b = { state:'texas', county:'harris', school:'Sam Houston Elementary', name: 'clif', age:12, grade:3};
10	c = { state:'ohio', county:'buckeye', school:'Newark High School', name: 'rachel', age:16, grade:12};
11	a.push(b);
12	a.push(c);
13
14	alert(a.texas.harris.['Sam Houston Elementary'].name);
15	alert(a.ohio.buckeye);
16	alert(a.(text,ohio).name);

a.~.horizontalPartitions['texas']['harris']['Sam Houston Elementary'] = [b];
a.~.horizontalPartitions['ohio']['buckeye']['Newark High School'] = [c];