//--------------------------------------------------------------// Copyright (C) 2008 Wall Street on Demand (http://www.wallst.com).// All rights reserved.//--------------------------------------------------------------if(typeof font == "undefined") font={};
function font_class() {};
font_class.Extend(WSDOM.getClass("Remoting"));
font_class.prototype.setFontSize = function(oInputs) {
	return this.load({
		protocolType:"JSONRPC",
		context:oInputs.context || this,
		onload:oInputs.onload,
		onerror:oInputs.onerror,
		data:{
			className:"font",
			method:"SetFontSize",
			arguments:oInputs.arguments || {}
		},
		url:'/Remoting/WSOD.Web.Clients.CLKing.Class.Font,WSOD.Web.Clients.CLKing.ashx'
	});
}
font = new font_class();

if(typeof BondListRemoting == "undefined") BondListRemoting={};
function BondListRemoting_class() {};
BondListRemoting_class.Extend(WSDOM.getClass("Remoting"));
BondListRemoting_class.prototype.getBondList = function(oInputs) {
	return this.load({
		protocolType:"JSONRPC",
		context:oInputs.context || this,
		onload:oInputs.onload,
		onerror:oInputs.onerror,
		data:{
			className:"BondListRemoting",
			method:"GetBondListData",
			arguments:oInputs.arguments || {}
		},
		url:'/Remoting/WSOD.Web.Clients.CLKing.Data.BondListRequest,WSOD.Web.Clients.CLKing.ashx'
	});
}
BondListRemoting = new BondListRemoting_class();

//DataSetConverter
if(typeof WSDOM == "undefined") WSDOM={};
if(typeof WSDOM.Data == "undefined") WSDOM.Data={};
if(typeof WSDOM.Data.DataSet == "undefined") WSDOM.Data.DataSet={};

WSDOM.Data.DataSet = function(t) {
	this.__type = "System.Data.DataSet,System.Data";
	this.Tables = [];
	this.addTable = function(t) {
		this.Tables.push(t);
	};
	if(t != null) {
		for(var i=0; i<t.length; i++) {
			this.addTable(t[i]);
		}
	}
};

//DataTableConverter
if(typeof WSDOM == "undefined") WSDOM={};
if(typeof WSDOM.Data == "undefined") WSDOM.Data={};
if(typeof WSDOM.Data.DataTable == "undefined") WSDOM.Data.DataTable={};

WSDOM.Data.DataTable = function(c, r) {
	this.__type = "System.Data.DataTable,System.Data";
	this.Columns = [];
	this.Rows = [];
	this.addColumn = function(name, type) {
		this.Columns.push({Name:name,__type:type});
	};
	this.addRow = function(row) {
		this.Rows.push(row);
	};
	if(c != null) {
		for(var i=0; i<c.length; i++)
			this.addColumn(c[i][0], c[i][1]);
	}
	if(r != null) {
		for(var y=0; y<r.length; y++) {
			var row = {};
			for(var z=0; z<this.Columns.length && z<r[y].length; z++)
				row[this.Columns[z].Name] = r[y][z];
			this.addRow(row);
		}
	}
};
