﻿
/*******************************************************************/
/*                                                                 */
/* Copyright (c) 2005-2009 Jasob.com                               */
/*                                                                 */
/* This obfuscated code was created by Jasob 3.5 Trial Version.    */
/* The code may be used for evaluation purposes only.              */
/* To obtain full rights to the obfuscated code you have to        */
/* purchase the license key (http://www.jasob.com/Purchase.html).  */
/*                                                                 */
/*******************************************************************/

dataConversionObj=function(){};dataConversionObj.prototype={mktInfoDataParse:function(inputString){var record=new Object();var fields=inputString.split(',');var i;var pair;for(i=0;i<fields.length;i++){pair=fields[i].split(':');if(pair.length!=2)continue;switch(pair[0]){case 'TD':record.tradingDay=pair[1];break;case 'MI':record.marketIndex=parseFloat(pair[1]);break;case 'IC':record.indexChange=parseFloat(pair[1]);break;case 'TT':record.totalTrade=parseInt(pair[1]);break;case 'TS':record.totalShares=parseInt(pair[1]);break;case 'TV':record.totalValue=parseInt(pair[1]);break;case 'ADV':record.advances=parseInt(pair[1]);break;case 'DEC':record.declines=parseInt(pair[1]);break;case 'NC':record.noChange=parseInt(pair[1]);break;case 'MM':record.marketMessage=pair[1];break;case 'MS':record.marketStatus=pair[1];break;case '0I':record.auctionIndex1=parseFloat(pair[1]);break;case '0C':record.indexChange1=parseFloat(pair[1]);break;case '0V':record.totalValue1=parseInt(pair[1]);break;case '1I':record.auctionIndex2=parseFloat(pair[1]);break;case '1C':record.indexChange2=parseFloat(pair[1]);break;case '1V':record.totalValue2=parseInt(pair[1]);break;case '2I':record.auctionIndex3=parseFloat(pair[1]);break;case '2C':record.indexChange3=parseFloat(pair[1]);break;case '2V':record.totalValue3=parseInt(pair[1]);break;case 'OC':record.onlineCounter=parseInt(pair[1]);break;default:break;}}return record;},stockInfoDataParsePutThrough:function(inputString){var record=new Object();var change_list=inputString.split('|');var change_idx;var field_idx=0;var pair;var field_value;for(change_idx=0;change_idx<change_list.length-1;change_idx++){pair=change_list[change_idx].split(':');if(pair.length==2){field_value=pair[1];field_idx=parseInt(pair[0]);}else{field_value=pair[0];};}return record;},stockInfoDataParseHOSE:function(inputString){var record=new Object();var change_list=inputString.split(',');var change_idx;var field_idx=0;record.StockSymbol=change_list[change_list.length-1];var pair;var field_value;for(change_idx=0;change_idx<change_list.length-1;change_idx++){pair=change_list[change_idx].split(':');if(pair.length==2){field_value=pair[1];field_idx=parseInt(pair[0]);}else{field_value=pair[0];};switch(field_idx){case 0:record.bestBidPrice1=parseInt(field_value)*100;break;case 1:record.bestBidVolume1=parseInt(field_value)*10;break;case 2:record.bestOfferPrice1=parseInt(field_value)*100;break;case 3:record.bestOfferVolume1=parseInt(field_value)*10;break;case 4:record.bestBidPrice2=parseInt(field_value)*100;break;case 5:record.bestBidVolume2=parseInt(field_value)*10;break;case 6:record.bestOfferPrice2=parseInt(field_value)*100;break;case 7:record.bestOfferVolume2=parseInt(field_value)*10;break;case 8:record.bestBidPrice3=parseInt(field_value)*100;break;case 9:record.bestBidVolume3=parseInt(field_value)*10;break;case 10:record.bestOfferPrice3=parseInt(field_value)*100;break;case 11:record.bestOfferVolume3=parseInt(field_value)*10;break;case 12:record.totalTraded=parseInt(field_value)*10;break;case 13:record.totalValue=parseInt(field_value)*1000;break;case 14:record.lastPrice=parseInt(field_value)*100;break;case 15:record.lastVolume=parseInt(field_value)*10;break;case 16:record.totalRoom=parseInt(field_value)*10;break;case 17:record.currentRoom=parseInt(field_value)*10;break;case 18:record.highestPrice=parseInt(field_value)*100;break;case 19:record.lowestPrice=parseInt(field_value)*100;break;case 20:record.foreignBuyVolume=parseInt(field_value)*10;break;case 21:record.foreignBuyValue=parseInt(field_value)*1000;break;case 22:record.putthroughVolume=parseInt(field_value)*10;break;case 23:record.putthroughValue=parseInt(field_value)*1000;break;case 24:record.openPrice=parseInt(field_value)*100;break;case 25:record.closePrice=parseInt(field_value)*100;break;case 26:record.averagePrice=parseInt(field_value)*100;break;case 27:record.referencePrice=parseInt(field_value)*100;break;case 28:record.floorPrice=parseInt(field_value)*100;break;case 29:record.ceilingPrice=parseInt(field_value)*100;break;default:break;}field_idx++;}return record;},stockInfoDataParseHASE:function(inputString){var record=new Object();var change_list=inputString.split(',');var change_idx;var field_idx=0;record.StockSymbol=change_list[change_list.length-1];var pair;var field_value;for(change_idx=0;change_idx<change_list.length-1;change_idx++){pair=change_list[change_idx].split(':');if(pair.length==2){field_value=pair[1];field_idx=parseInt(pair[0]);}else{field_value=pair[0];};switch(field_idx){case 0:record.bestBidPrice1=parseInt(field_value)*100;break;case 1:record.bestBidVolume1=parseInt(field_value)*10;break;case 2:record.bestOfferPrice1=parseInt(field_value)*100;break;case 3:record.bestOfferVolume1=parseInt(field_value)*10;break;case 4:record.bestBidPrice2=parseInt(field_value)*100;break;case 5:record.bestBidVolume2=parseInt(field_value)*10;break;case 6:record.bestOfferPrice2=parseInt(field_value)*100;break;case 7:record.bestOfferVolume2=parseInt(field_value)*10;break;case 8:record.bestBidPrice3=parseInt(field_value)*100;break;case 9:record.bestBidVolume3=parseInt(field_value)*10;break;case 10:record.bestOfferPrice3=parseInt(field_value)*100;break;case 11:record.bestOfferVolume3=parseInt(field_value)*10;break;case 12:record.totalTraded=parseInt(field_value)*10;break;case 13:record.totalValue=parseInt(field_value)*1000;break;case 14:record.lastPrice=parseInt(field_value)*100;break;case 15:record.lastVolume=parseInt(field_value)*10;break;case 16:record.totalRoom=parseInt(field_value)*10;break;case 17:record.currentRoom=parseInt(field_value)*10;break;case 18:record.highestPrice=parseInt(field_value)*100;break;case 19:record.lowestPrice=parseInt(field_value)*100;break;case 20:record.totalBidVolume=parseInt(field_value)*10;break;case 21:record.totalOfferVolume=parseInt(field_value)*10;break;case 22:record.foreignSellVolume=parseInt(field_value)*10;break;case 23:record.foreignSellValue=parseInt(field_value)*1000;break;case 24:record.foreignBuyVolume=parseInt(field_value)*10;break;case 25:record.foreignBuyValue=parseInt(field_value)*1000;break;case 26:record.putthroughVolume=parseInt(field_value)*10;break;case 27:record.putthroughValue=parseInt(field_value)*1000;break;case 28:record.openPrice=parseInt(field_value)*100;break;case 29:record.closePrice=parseInt(field_value)*100;break;case 30:record.averagePrice=parseInt(field_value)*100;break;case 31:record.referencePrice=parseInt(field_value)*100;break;case 32:record.floorPrice=parseInt(field_value)*100;break;case 33:record.ceilingPrice=parseInt(field_value)*100;break;default:break;}field_idx++;}return record;},stockInfoDataParseUpCom:function(inputString){var record=new Object();var change_list=inputString.split('#');var change_idx;var field_idx=0;record.StockSymbol=change_list[change_list.length-1];var pair;var field_value;for(change_idx=0;change_idx<change_list.length-1;change_idx++){pair=change_list[change_idx].split(':');if(pair.length==2){field_value=pair[1];field_idx=parseInt(pair[0]);}else{field_value=pair[0];};switch(field_idx){case 0:record.bestBidPrice1=parseInt(field_value)*100;break;case 1:record.bestBidVolume1=parseInt(field_value)*10;break;case 2:record.bestOfferPrice1=parseInt(field_value)*100;break;case 3:record.bestOfferVolume1=parseInt(field_value)*10;break;case 4:record.bestBidPrice2=parseInt(field_value)*100;break;case 5:record.bestBidVolume2=parseInt(field_value)*10;break;case 6:record.bestOfferPrice2=parseInt(field_value)*100;break;case 7:record.bestOfferVolume2=parseInt(field_value)*10;break;case 8:record.bestBidPrice3=parseInt(field_value)*100;break;case 9:record.bestBidVolume3=parseInt(field_value)*10;break;case 10:record.bestOfferPrice3=parseInt(field_value)*100;break;case 11:record.bestOfferVolume3=parseInt(field_value)*10;break;case 12:record.totalTraded=parseInt(field_value)*10;break;case 13:record.totalValue=parseInt(field_value)*1000;break;case 14:record.lastPrice=parseInt(field_value)*100;break;case 15:record.lastVolume=parseInt(field_value)*10;break;case 16:record.totalRoom=parseInt(field_value)*10;break;case 17:record.currentRoom=parseInt(field_value)*10;break;case 18:record.highestPrice=parseInt(field_value)*100;break;case 19:record.lowestPrice=parseInt(field_value)*100;break;case 20:record.totalBidVolume=parseInt(field_value)*10;break;case 21:record.totalOfferVolume=parseInt(field_value)*10;break;case 22:record.foreignSellVolume=parseInt(field_value)*10;break;case 23:record.foreignSellValue=parseInt(field_value)*1000;break;case 24:record.foreignBuyVolume=parseInt(field_value)*10;break;case 25:record.foreignBuyValue=parseInt(field_value)*1000;break;case 26:record.openPrice=parseInt(field_value)*100;break;case 27:record.closePrice=parseInt(field_value)*100;break;case 28:record.averagePrice=parseInt(field_value)*100;break;case 29:record.referencePrice=parseInt(field_value)*100;break;case 30:record.floorPrice=parseInt(field_value)*100;break;case 31:record.ceilingPrice=parseInt(field_value)*100;break;case 32:record.BuyQuantityDetail1=field_value;break;case 33:record.BuyQuantityDetail2=field_value;break;case 34:record.BuyQuantityDetail3=field_value;break;case 35:record.SellQuantityDetail1=field_value;break;case 36:record.SellQuantityDetail2=field_value;break;case 37:record.SellQuantityDetail3=field_value;break;default:break;}field_idx++;}return record;}};miscObj=function(){};miscObj.prototype={cmpStockInfo:function(arrItm,symbol){if(arrItm.StockSymbol>symbol)return 1;else if(arrItm.StockSymbol<symbol)return-1;else return 0;},cmp2StockInfo:function(a,b){if(a.StockSymbol>b.StockSymbol)return 1;else if(a.StockSymbol<b.StockSymbol)return-1;else return 0;},cmp2String:function(a,b){if(a>b)return 1;else if(a<b)return-1;else return 0;},findPriceCellColorName:function(price,record){if(price==0){return Conf.NoChangeColor;}if(price==record.ceilingPrice){return Conf.CeilingColor;}else if(price>record.referencePrice){return Conf.UpColor;}else if(price==record.referencePrice){return Conf.NoChangeColor;}else if(price==record.floorPrice){return Conf.FloorColor;}else if(price<record.referencePrice){return Conf.DownColor;}},findPriceCellColorNameForPutthrough:function(price,record){if(price==0){return Conf.NoChangeColor;}if(price==record.ceilingPrice){return Conf.CeilingColor;}else if(price>record.referencePrice){return Conf.UpColor;}else if(price==record.referencePrice){return Conf.NoChangeColor;}else if(price==record.floorPrice){return Conf.FloorColor;}else if(price<record.referencePrice){return Conf.DownColor;}},findPriceCellClassName:function(price,record){if(price==0){return 'BasicPrice';}if(price==record.ceilingPrice){return 'CeilingCell';}else if(price>record.referencePrice){return 'UpCell';}else if(price==record.referencePrice){return 'BasicPrice';}else if(price==record.floorPrice){return 'FloorCell';}else if(price<record.referencePrice){return 'DownCell';}},findPriceTrendingSignHOSE:function(price,record){if(price==0){return '<img src="Images/nochange.gif" alt=" " />';}if(price==record.ceilingPrice){return '<img src="Images/cell.gif" alt=" " />';}else if(price>record.referencePrice){return '<img src="Images/up.gif" alt=" " />';}else if(price==record.referencePrice){return '<img src="Images/nochange.gif" alt=" " />';}else if(price==record.floorPrice){return '<img src="Images/floor.gif" alt=" " />';}else if(price<record.referencePrice){return '<img src="Images/down.gif" alt=" " />';}},findPriceTrendingSignHASE:function(price,record){if(price==0){return '<img src="Images/nochange.gif" alt=" "  />';}if(price==record.ceilingPrice){return '<img src="Images/cell.gif" alt=" " />';}else if(price>record.referencePrice){return '<img src="Images/up.gif" alt=" " />';}else if(price==record.referencePrice){return '<img src="Images/nochange.gif" alt=" " />';}else if(price==record.floorPrice){return '<img src="Images/floor.gif" alt=" " />';}else if(price<record.referencePrice){return '<img src="Images/down.gif" alt=" " />';}}};var misc=new miscObj();var dataConversion=new dataConversionObj();
