").css(d.noDataStyle).css({top:d.height/2+"px",width:d.width+"px",position:"absolute","text-align":"center"})).appendTo(a),this},c.prototype.initEvent=function(){return this},c.prototype.addCallback=function(a){this._aCallback.push(a)},c.prototype.show=function(a){this._$element.find("> div").html(a).end().show()},c.prototype.hide=function(){this._$element.hide()},a.BigScatterChart2.MessagePlugin=c}(window,jQuery),function(a,b){"use strict";function c(a){this._init(a)}c.prototype._init=function(a){this._featureImage=a,this._aCallback=[]},c.prototype.initElement=function(a,c,d){var e=d.width,f=d.height,g=e/2,h=f/2,i=200,j=130,k="setting-min-"+parseInt(1e5*Math.random()),l="setting-max-"+parseInt(1e5*Math.random());this._$elConfigButton=b("
").css({padding:"4px 0px 4px 20px"}).append(b("
![]()
").attr({src:this._featureImage,alt:"Open Config",title:"Open Config"})).appendTo(c);var m=['
"].join("");return this._$element=b(m),this._$element.css({width:e+"px",height:f+"px",display:"none",position:"relative"}),this._$element.find(".config-bg").css({width:e+"px",height:f+"px",opacity:.3,"z-index":1100,position:"absolute","background-color":"#000"}),this._$element.find(".dropdown-menu").css({top:h-j/2+"px",left:g-i/2+"px",width:i+"px",height:j+"px",display:"block","z-index":1101}),this._$element.find("label:first").attr("for",k),this._$element.find("label:last").attr("for",l),this._$element.find("input[type=text]:first").attr("id",k).val(d.minY),this._$element.find("input[type=text]:last").attr("id",l).val(d.maxY),a.append(this._$element),this},c.prototype.hide=function(){this._$element.hide()},c.prototype.show=function(){this._$element.show()},c.prototype.initEvent=function(a){var c=this;return this._$elConfigButton.click(function(){c.show()}),this._$element.find(".cancel").click(function(){c.hide()}),this._$element.find(".apply").click(function(d){d.preventDefault();var e=parseInt(c._$element.find("input[type=text]:first").val(),10),f=parseInt(c._$element.find("input[type=text]:last").val(),10);return e>=f?void alert("Min of Y axis is should be smaller than "+f):(b.each(c._aCallback,function(b,c){c(a,{min:e,max:f})}),void c.hide())}),this},c.prototype.addCallback=function(a){return this._aCallback.push(a),this},a.BigScatterChart2.SettingPlugin=c}(window,jQuery),function(a,b){"use strict";function c(a){this._init(a)}c.prototype._init=function(a){this._featureImage=a,this._aCallback=[],this._bDisabled=!1},c.prototype.initElement=function(a,c,d){return this._bDisabled=d.realtime,this._$element=b("
',chartDirective:Handlebars.compile('
')},css:{borderWidth:2,height:180,navbarHeight:70,titleHeight:30},sumChart:{width:260,height:120},otherChart:{width:120,height:60},"const":{MIN_Y:10}}),pinpointApp.controller("RealtimeChartCtrl",["RealtimeChartCtrlConfig","$scope","$element","$rootScope","$compile","$timeout","$window","globalConfig","$location","RealtimeWebsocketService","AnalyticsService","TooltipService",function(b,c,d,e,f,g,h,i,j,k,l,m){function n(){p("sum")===!1&&(Q.append(f(b.template.chartDirective({width:b.sumChart.width,height:b.sumChart.height,namespace:"sum",chartColor:"sumChartColor",xAxisCount:O,showExtraInfo:"true",timeoutMaxCount:N}))(c)),$.sum=-1)}function o(){angular.isDefined($.sum)?($={},$.sum=-1):$={}}function p(a){return angular.isDefined($[a])}function q(d){var e=a(b.template.agentChart).append(f(b.template.chartDirective({width:b.otherChart.width,height:b.otherChart.height,namespace:Z.length,chartColor:"agentChartColor",xAxisCount:O,showExtraInfo:"false",timeoutMaxCount:N}))(c));T.append(e),w(d,Z.length),Z.push(e)}function r(){var a=k.open({onopen:function(a){D()},onmessage:function(a){s(a)},onclose:function(a){c.$apply(function(){H()})},ondelay:function(){k.close()},retry:function(){c.retryConnection()}});a&&n()}function s(a){switch(U.hide(),a[b.keys.TYPE]){case b.values.PING:k.send(fa);break;case b.values.RESPONSE:var c=a[b.keys.RESULT];if(c[b.keys.APPLICATION_NAME]!==Y)return;var d=c[b.keys.ACTIVE_THREAD_COUNTS],e=A(d);B(e),t(d,e,c[b.keys.TIME_STAMP])}}function t(a,d,e){var f=Math.max(C(),b["const"].MIN_Y),g=0,h=!0;for(var i in a)v(i,g),a[i][b.keys.CODE]===P?(h=!1,c.$broadcast("realtimeChartDirective.onData."+$[i],a[i][b.keys.STATUS],e,f,h)):c.$broadcast("realtimeChartDirective.onError."+$[i],a[i],e,f),y(g),g++;c.$broadcast("realtimeChartDirective.onData.sum",d,e,f,h),S.html(g)}function u(a){return ga[b.keys.PARAMETERS][b.keys.APPLICATION_NAME]=a,JSON.stringify(ga)}function v(a,b){p(a)===!1&&(x(b)?w(a,b):q(a)),z(b,a)}function w(a,b){$[a]=b}function x(a){return Z.length>a}function y(a){Z[a].show()}function z(a,b){Z[a].find("div").html(b)}function A(a){var c=[0,0,0,0];for(var d in a)a[d][b.keys.CODE]===P&&jQuery.each(a[d][b.keys.STATUS],function(a,b){c[a]+=b});return c}function B(a){_.push(a.reduce(function(a,b){return a+b})),_.length>O&&_.shift()}function C(){return d3.max(_,function(a){return a})}function D(){k.send(u(Y))}function E(){k.isOpened()===!1?r():D(),da=!0}function F(){da=!1,k.stopReceive(u(""))}function G(){e.$broadcast("realtimeChartDirective.clear.sum"),a.each(Z,function(a,b){e.$broadcast("realtimeChartDirective.clear."+a),b.hide()})}function H(){U.css("background-color","rgba(200, 200, 200, 0.9)"),U.find("h4").css("color","red").html("Closed connection.
Select node again."),U.find("button").show(),U.show()}function I(){U.css("background-color","rgba(138, 171, 136, 0.5)"),U.find("h4").css("color","blue").html("Waiting Connection..."),U.find("button").hide(),U.show()}function J(){d.animate({bottom:-ea,left:0},500,function(){V.removeClass("glyphicon-chevron-down").addClass("glyphicon-chevron-up")})}function K(){d.animate({bottom:0,left:0},500,function(){V.removeClass("glyphicon-chevron-up").addClass("glyphicon-chevron-down")})}function L(){d.innerWidth(d.parent().width()-b.css.borderWidth+"px")}function M(){W.css("color",aa?"red":"")}d=a(d);var N=10,O=10,P=0,Q=d.find("div.agent-sum-chart"),R=d.find("div.agent-sum-chart div:first-child span:first-child"),S=d.find("div.agent-sum-chart div:first-child span:last-child"),T=d.find("div.agent-chart-list"),U=d.find(".connection-message"),V=d.find(".handle .glyphicon"),W=d.find(".glyphicon-pushpin"),X="",Y="",Z=[],$={},_=[0],aa=!0,ba=!1,ca=!1,da=!0,ea=b.css.height,fa=function(){var a={};return a[b.keys.TYPE]=b.values.PONG,JSON.stringify(a)}(),ga=function(){var a={};return a[b.keys.TYPE]=b.values.REQUEST,a[b.keys.COMMAND]=b.values.ACTIVE_THREAD_COUNT,a[b.keys.PARAMETERS]={},a}(),ha=null;m.init("realtime"),c.sumChartColor=["rgba(44, 160, 44, 1)","rgba(60, 129, 250, 1)","rgba(248, 199, 49, 1)","rgba(246, 145, 36, 1)"],c.agentChartColor=["rgba(44, 160, 44, .8)","rgba(60, 129, 250, .8)","rgba(248, 199, 49, .8)","rgba(246, 145, 36, .8)"],c.requestLabelNames=["1s","3s","5s","Slow"],c.bInitialized=!1,U.hide(),R.html(""),S.html("0"),a(document).on("visibilitychange",function(){switch(document.visibilityState){case"hidden":ha=g(function(){k.close(),ha=null},6e4);break;case"visible":null!==ha?g.cancel(ha):c.retryConnection(),ha=null}}),c.$on("realtimeChartController.close",function(){J();var a=da;c.closePopup(),da=a,M()}),c.$on("realtimeChartController.initialize",function(a,b,d,e){if((aa!==!0||X!==e)&&/^\/main/.test(j.path())!==!1&&(ba=angular.isUndefined(b)?!1:b,d=angular.isUndefined(d)?"":d,X=e,R.html(Y=d),i.useRealTime!==!1&&da!==!1)){if(ba===!1)return void J();o(),L(),c.bInitialized=!0,K(),c.closePopup(),R.html(Y=d),I(),E(),M()}}),c.retryConnection=function(){I(),E()},c.pin=function(){aa=!aa,M()},c.resizePopup=function(){l.send(l.CONST.MAIN,l.CONST.TG_REALTIME_CHART_RESIZE),ca?(ea=b.css.height,d.css({height:b.css.height+"px",bottom:"0px"}),T.css("height","150px")):(ea=h.innerHeight-b.css.navbarHeight,d.css({height:ea+"px",bottom:"0px"}),T.css("height",ea-b.css.titleHeight+"px")),ca=!ca},c.toggleRealtime=function(){ba!==!1&&(da===!0?(l.send(l.CONST.MAIN,l.CONST.CLK_REALTIME_CHART_HIDE),J(),F(),G(),da=!1):(l.send(l.CONST.MAIN,l.CONST.CLK_REALTIME_CHART_SHOW),K(),I(),E(),da=!0))},c.closePopup=function(){F(),G(),U.hide(),R.html(Y=""),S.html("0")},a(h).on("resize",function(){L()})}])}(jQuery),function(){"use strict";pinpointApp.controller("MainCtrl",["filterConfig","$scope","$timeout","$routeParams","locationService","NavbarVoService","$window","SidebarTitleVoService","filteredMapUtilService","$rootElement","AnalyticsService",function(a,b,c,d,e,f,g,h,i,j,k){k.send(k.CONST.MAIN_PAGE);var l,m,n,o,p,q;b.hasScatter=!1,g.htoScatter={},m=!0,n=!1,b.sidebarLoading=!0,c(function(){l=new f,d.application&&l.setApplication(d.application),d.readablePeriod&&l.setReadablePeriod(d.readablePeriod),d.queryEndDateTime&&l.setQueryEndDateTime(d.queryEndDateTime),l.isRealtime()?b.$broadcast("navbarDirective.initialize.realtime.andReload",l):angular.isDefined(d.application)&&angular.isUndefined(d.readablePeriod)&&angular.isUndefined(d.readablePeriod)?b.$broadcast("navbarDirective.initialize.andReload",l):(g.$routeParams=d,l.autoCalculateByQueryEndDateTimeAndReadablePeriod(),b.$broadcast("navbarDirective.initialize",l),b.$broadcast("scatterDirective.initialize",l),b.$broadcast("serverMapDirective.initialize",l))},500),o=function(){return e.path().split("/")[1]||"main"},p=function(){var a="/"+o()+"/"+l.getApplication()+"/";l.isRealtime()?(a+=l.getPeriodType(),g.$routeParams={application:l.getApplication(),readablePeriod:l.getPeriodType()}):a+=l.getReadablePeriod()+"/"+l.getQueryEndDateTime(),e.path()!==a&&("/main"===e.path()?e.path(a).replace():e.skipReload().path(a).replace(),g.$routeParams={application:l.getApplication(),readablePeriod:l.getReadablePeriod().toString(),queryEndDateTime:l.getQueryEndDateTime().toString()},b.$$phase||b.$apply())},q=function(a,b){var c=i.getFilteredMapUrlWithFilterVo(l,a,b);g.open(c,"")},b.getMainContainerClass=function(){return n?"no-data":""},b.getInfoDetailsClass=function(){var a=[];return b.hasScatter&&a.push("has-scatter"),b.hasFilter&&a.push("has-filter"),a.join(" ")},b.$on("serverMapDirective.hasData",function(a){n=!1,b.sidebarLoading=!1}),b.$on("serverMapDirective.hasNoData",function(a){n=!0,b.sidebarLoading=!1}),b.$on("navbarDirective.changed",function(a,c){n=!1,l=c,p(l),g.htoScatter={},b.hasScatter=!1,b.sidebarLoading=!0,b.$broadcast("sidebarTitleDirective.empty.forMain"),b.$broadcast("nodeInfoDetailsDirective.hide"),b.$broadcast("linkInfoDetailsDirective.hide"),b.$broadcast("scatterDirective.initialize",l),b.$broadcast("serverMapDirective.initialize",l),b.$broadcast("sidebarTitleDirective.empty.forMain")}),b.$on("serverMapDirective.passingTransactionResponseToScatterChart",function(a,c){b.$broadcast("scatterDirective.initializeWithNode",c)}),b.$on("serverMapDirective.nodeClicked",function(a,c,d,e,f,g){m=!0;var i=new h;i.setImageType(e.serviceType),e.isWas===!0?(b.hasScatter=!0,i.setTitle(e.applicationName),b.$broadcast("scatterDirective.initializeWithNode",e)):e.unknownNodeGroup?(i.setTitle(e.serviceType.replace("_"," ")),
+b.hasScatter=!1):(i.setTitle(e.applicationName),b.hasScatter=!1),b.hasFilter=!1,b.$broadcast("sidebarTitleDirective.initialize.forMain",i,e),b.$broadcast("nodeInfoDetailsDirective.initialize",c,d,e,f,l,null,g),b.$broadcast("linkInfoDetailsDirective.hide")}),b.$on("serverMapDirective.linkClicked",function(a,c,d,e,f){m=!1;var g=new h;e.unknownLinkGroup?g.setImageType(e.sourceInfo.serviceType).setTitle("Unknown Group from "+e.sourceInfo.applicationName):g.setImageType(e.sourceInfo.serviceType).setTitle(e.sourceInfo.applicationName).setImageType2(e.targetInfo.serviceType).setTitle2(e.targetInfo.applicationName),b.hasScatter=!1;var j=i.findFilterInNavbarVo(e.sourceInfo.applicationName,e.sourceInfo.serviceType,e.targetInfo.applicationName,e.targetInfo.serviceType,l);j?(b.hasFilter=!0,b.$broadcast("filterInformationDirective.initialize.forMain",j.oServerMapFilterVoService)):b.hasFilter=!1,b.$broadcast("sidebarTitleDirective.initialize.forMain",g),b.$broadcast("nodeInfoDetailsDirective.hide"),b.$broadcast("linkInfoDetailsDirective.initialize",c,d,e,f,l)}),b.$on("serverMapDirective.openFilteredMap",function(a,b,c){q(b,c)}),b.$on("linkInfoDetailsDirective.openFilteredMap",function(a,b,c){q(b,c)}),b.$on("linkInfoDetailsDirective.openFilterWizard",function(a,c,d){b.$broadcast("serverMapDirective.openFilterWizard",c,d)}),b.$on("linkInfoDetailsDirective.ResponseSummary.barClicked",function(a,b){q(b)}),b.$on("linkInfoDetailsDirective.showDetailInformationClicked",function(a,c,d){b.hasScatter=!1;var e=new h;e.setImageType(d.sourceInfo.serviceType).setTitle(d.sourceInfo.applicationName).setImageType2(d.targetInfo.serviceType).setTitle2(d.targetInfo.applicationName),b.$broadcast("sidebarTitleDirective.initialize.forMain",e),b.$broadcast("nodeInfoDetailsDirective.hide")}),b.$on("nodeInfoDetailDirective.showDetailInformationClicked",function(a,c,d){b.hasScatter=!1;var e=new h;e.setImageType(d.serviceType),d.unknownNodeGroup?(e.setTitle(d.serviceType.replace("_"," ")),b.hasScatter=!1):(e.setTitle(d.applicationName),b.hasScatter=!1),b.$broadcast("sidebarTitleDirective.initialize.forMain",e),b.$broadcast("linkInfoDetailsDirective.hide")}),b.loadingOption={hideTip:"init"},b.$watch("loadingOption.hideTip",function(a){if("init"!=a&&g.localStorage){var b=new Date;b.setDate(b.getDate()+30),g.localStorage.setItem("__HIDE_LOADING_TIP",a?b.valueOf():"-")}})}])}(),function(){"use strict";pinpointApp.controller("InspectorCtrl",["$scope","$timeout","$routeParams","locationService","NavbarVoService","AnalyticsService",function(a,b,c,d,e,f){f.send(f.CONST.INSPECTOR_PAGE);var g,h,i,j,k,l;b(function(){g=new e,c.application&&g.setApplication(c.application),c.readablePeriod&&g.setReadablePeriod(c.readablePeriod),c.queryEndDateTime&&g.setQueryEndDateTime(c.queryEndDateTime),c.agentId&&g.setAgentId(c.agentId),g.autoCalculateByQueryEndDateTimeAndReadablePeriod(),a.$emit("navbarDirective.initializeWithStaticApplication",g),a.$emit("agentListDirective.initialize",g)},500),a.$on("navbarDirective.changed",function(a,b){g=b,j()}),a.$on("agentListDirective.agentChanged",function(b,c){h=c,g.setAgentId(c.agentId),l()&&j(),h&&a.$emit("agentInfoDirective.initialize",g,h)}),i=function(){var a=d.path().split("/");return a[1]||"inspector"},j=function(){var b=k();l()&&("/inspector"===d.path()||d.skipReload().path(b).replace(),a.$emit("navbarDirective.initializeWithStaticApplication",g),a.$emit("agentListDirective.initialize",g))},k=function(){var a="/"+i()+"/"+g.getApplication()+"/"+g.getReadablePeriod()+"/"+g.getQueryEndDateTime();return g.getAgentId()&&(a+="/"+g.getAgentId()),a},l=function(){var a=k();return d.path()!==a}}])}(),function(){"use strict";pinpointApp.constant("TransactionListConfig",{applicationUrl:"/transactionmetadata.pinpoint",MAX_FETCH_BLOCK_SIZE:100}),pinpointApp.controller("TransactionListCtrl",["TransactionListConfig","$scope","$location","$routeParams","$rootScope","$timeout","$window","$http","webStorage","TimeSliderVoService","TransactionDaoService","AnalyticsService","helpContentService",function(a,b,c,d,e,f,g,h,i,j,k,l,m){l.send(l.CONST.TRANSACTION_LIST_PAGE);var n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H;f(function(){n=1,o=0,b.transactionDetailUrl="index.html#/transactionDetail",b.sidebarLoading=!0;var a=E(),c=F(),e=!angular.isUndefined(d.transactionInfo);if(e){var h=d.transactionInfo.lastIndexOf("-"),i=d.transactionInfo.lastIndexOf("-",h-1);s=[d.transactionInfo.substring(0,i),d.transactionInfo.substring(i+1,h),d.transactionInfo.substring(h+1)]}a&&c?(p=A(g.name),B(p.applicationName)?(q=C(p),G(e)):H(m.transactionList.openError.noData.replace(/\{\{application\}\}/,p.applicationName))):e===!1?H(m.transactionList.openError.noParent):(p=D(),q=[[s[1],s[2],s[0]]],G(e)),f(function(){$("#main-container").layout({north__minSize:20,north__size:(window.innerHeight-40)/2,center__maskContents:!0})},100)},100),H=function(a){alert(a),g.location.replace(g.location.href.replace("transactionList","main"))},G=function(a){r=new j,r.setTotal(q.length),t(a)},E=function(){return angular.isDefined(g.opener)},F=function(){if(angular.isUndefined(g.opener)||null===g.opener)return!1;var a=g.opener.$routeParams;if(angular.isDefined(d)&&angular.isDefined(a))if("realtime"===a.readablePeriod){if(angular.equals(d.application,a.application))return!0}else if(angular.equals(d.application,a.application)&&angular.equals(d.readablePeriod,a.readablePeriod)&&angular.equals(d.queryEndDateTime,a.queryEndDateTime))return!0;return!1},A=function(a){var b=a.split("|");return 4===b.length?{applicationName:b[0],type:b[1],min:b[2],max:b[3]}:{applicationName:b[0],nXFrom:b[1],nXTo:b[2],nYFrom:b[3],nYTo:b[4]}},D=function(){return{applicationName:d.application.split("@")[0],nXFrom:parseInt(s[1])-1e3,nXTo:parseInt(s[1])+1e3,nYFrom:0,nYTo:0}},B=function(a){return angular.isDefined(g.opener.htoScatter[a])},C=function(a){var b=g.opener.htoScatter[a.applicationName];return a.type?b.getDataByRange(a.type,a.min,a.max):b.getDataByXY(a.nXFrom,a.nXTo,a.nYFrom,a.nYTo)},w=function(a){b.$emit("transactionTableDirective.appendTransactionList",a.metadata)},x=function(){if(!q)return g.alert("Query failed - Query parameter cache deleted.\n\nPossibly due to scatter chart being refreshed."),!1;for(var b=[],c=o,d=0;c
0&&b.push("&"),b=b.concat(["I",d,"=",q[c][0]]),b=b.concat(["&T",d,"=",q[c][1]]),b=b.concat(["&R",d,"=",q[c][2]]),o++;return n++,b},u=function(){y(x(),function(c){return 0===c.metadata.length?(b.$emit("timeSliderDirective.disableMore"),b.$emit("timeSliderDirective.changeMoreToDone"),!1):(c.metadata.length=180?b.Geometry.parse("M30 0 B270 "+d+" 30 30 30 30"):b.Geometry.parse("M30 -60 B270 "+d+" 30 -30 30 30")})),a.$(b.Panel,b.Panel.Spot,{name:"NODE_PANEL",alignment:b.Spot.TopLeft,alignmentFocus:b.Spot.TopLeft},a.$(b.Panel,b.Panel.Vertical,{alignment:b.Spot.TopLeft,alignmentFocus:b.Spot.TopLeft,minSize:new b.Size(120,NaN)},a.$(b.Picture,{source:c+d,margin:new b.Margin(18,0,5,0),desiredSize:new b.Size(80,40),imageStretch:b.GraphObject.Uniform}),a.$(b.TextBlock,new b.Binding("text","applicationName").makeTwoWay(),{alignment:b.Spot.BottomCenter,alignmentFocus:b.Spot.BottomCenter,name:"NODE_TEXT",margin:6,font:a.option("sBigFont"),editable:!1}),a.$(b.Panel,b.Panel.Table,{padding:2,minSize:new b.Size(100,10),defaultStretch:b.GraphObject.Horizontal,itemTemplate:f},new b.Binding("itemArray","infoTable"))),a.$(b.Panel,b.Panel.Horizontal,{alignment:b.Spot.TopLeft,alignmentFocus:b.Spot.TopLeft,margin:0},a.$(b.Picture,{source:c+"ERROR.png",desiredSize:new b.Size(20,20),imageStretch:b.GraphObject.Uniform,margin:new b.Margin(1,5,0,1)},new b.Binding("visible","hasAlert")),a.$(b.Picture,{source:c+"FILTER.png",desiredSize:new b.Size(17,17),visible:!1,imageStretch:b.GraphObject.Uniform},new b.Binding("visible","isFiltered"))),a.$(b.Panel,b.Panel.Auto,{alignment:b.Spot.TopRight,alignmentFocus:b.Spot.TopRight,visible:!1},new b.Binding("visible","instanceCount",function(a){return a>1}),a.$(b.Shape,{figure:"RoundedRectangle",fill:"#848484",strokeWidth:1,stroke:"#848484"}),a.$(b.Panel,b.Panel.Auto,{margin:new b.Margin(0,3,0,3)},a.$(b.TextBlock,new b.Binding("text","instanceCount"),{stroke:"#FFFFFF",textAlign:"center",height:16,font:a.option("sSmallFont"),editable:!1})))))},i=a.$(b.Panel,b.Panel.TableRow,a.$(b.Picture,{source:c+"ERROR.png",margin:new b.Margin(1,2),desiredSize:new b.Size(10,10),visible:!1,column:1,imageStretch:b.GraphObject.Uniform},new b.Binding("visible","hasAlert")),a.$(b.TextBlock,{name:"NODE_INDEX",visible:!1,text:"0"},new b.Binding("text","idx")),a.$(b.TextBlock,{name:"NODE_APPLICATION_NAME",margin:new b.Margin(1,2),column:2,font:a.option("sSmallFont"),alignment:b.Spot.Left,click:function(b,c){if(b.bubbles=!1,c.part.data.isCollapse)a._onNodeClicked(b,c,c.part.data.unknownNodeGroup[b.targetObject.row].key);else{var d=c.part.data.subGroup[parseInt(b.targetObject.panel.findObject("NODE_INDEX").text)];a._onNodeSubGroupClicked(b,c,d.groups[b.targetObject.row].key,d.applicationName)}return!1}},new b.Binding("text","applicationName")),a.$(b.TextBlock,{margin:new b.Margin(1,2),column:3,alignment:b.Spot.Right,font:a.option("sSmallFont")},new b.Binding("text","totalCount",function(a){return Number(a,10).toLocaleString()}))),j=a.$(b.Panel,b.Panel.Vertical,a.$(b.TextBlock,{name:"NODE_SUB_APPLICATION_NAME",margin:new b.Margin(2,2),font:"bold 16px avn55,NanumGothic,ng,dotum,AppleGothic,sans-serif"},new b.Binding("text","applicationName")),a.$(b.Panel,b.Panel.Table,{padding:4,minSize:new b.Size(100,10),defaultStretch:b.GraphObject.Horizontal,itemTemplate:i,name:"NODE_SUB_TABLE"},new b.Binding("itemArray","groups")),a.$(b.Shape,{figure:"RoundedRectangle",margin:new b.Margin(6,2,6,2),height:1,width:200,strokeWidth:1,stroke:"#F5A623",fill:"#F5A623",visible:!0},new b.Binding("visible","isLast",function(a){return!a}))),k=function(d){return a.$(b.Node,b.Panel.Auto,{selectionAdorned:!1,cursor:"pointer",name:"NODE",click:function(b,c){b.bubbles&&a._onNodeClicked(b,c)},doubleClick:function(b,c){a._onNodeDoubleClicked(b,c)},contextClick:a._onNodeContextClicked.bind(a)},a.$(b.Shape,{figure:"RoundedRectangle",isPanelMain:!0,minSize:new b.Size(100,100),name:"NODE_SHAPE",portId:"",strokeWidth:a.option("htNodeTheme")["default"].borderWidth,stroke:a.option("htNodeTheme")["default"].borderColor,fill:a.option("htNodeTheme")["default"].backgroundColor},new b.Binding("key","key")),a.$("Button",{alignment:b.Spot.TopLeft,width:20,height:20,margin:2,visible:!1,click:function(b,c){a.analyticsService.send(a.analyticsService.CONST.MAIN,a.analyticsService.CONST.TG_NODE_VIEW),b.bubbles=!1;var d=c.part.data.isCollapse;a._oDiagram.model.setDataProperty(c.part.data,"isCollapse",!d),c.part.findObject("GROUP_BUTTON").text=d?" - ":" + "}},new b.Binding("visible","isMultiGroup"),a.$(b.TextBlock,{name:"GROUP_BUTTON",text:" + ",textAlign:"center",font:"bold 14px serif"})),a.$(b.Panel,b.Panel.Spot,a.$(b.Panel,b.Panel.Vertical,{alignment:b.Spot.TopLeft,alignmentFocus:b.Spot.TopLeft,minSize:new b.Size(130,NaN)},a.$(b.Picture,{source:c+d,margin:new b.Margin(0,0,5,0),desiredSize:new b.Size(100,40),imageStretch:b.GraphObject.Uniform}),a.$(b.Panel,b.Panel.Table,{padding:2,minSize:new b.Size(100,10),defaultStretch:b.GraphObject.Horizontal,itemTemplate:i,name:"NODE_TEXT",visible:!0},new b.Binding("itemArray","unknownNodeGroup"),new b.Binding("visible","isCollapse")),a.$(b.Panel,b.Panel.Vertical,{padding:2,minSize:new b.Size(100,10),defaultStretch:b.GraphObject.Horizontal,itemTemplate:j,name:"NODE_SUB_TEXT",visible:!0},new b.Binding("itemArray","subGroup"),new b.Binding("visible","isCollapse",function(a){return!a})))),a.$(b.Panel,b.Panel.Auto,{alignment:b.Spot.TopRight,alignmentFocus:b.Spot.TopRight,visible:!1},new b.Binding("visible","instanceCount",function(a){return a>1}),a.$(b.Shape,{figure:"RoundedRectangle",fill:"#848484",strokeWidth:1,stroke:"#848484"}),a.$(b.Panel,b.Panel.Auto,{margin:new b.Margin(0,3,0,3)},a.$(b.TextBlock,new b.Binding("text","instanceCount"),{stroke:"#FFFFFF",textAlign:"center",height:16,font:a.option("sSmallFont"),editable:!1}))))};d.each(e,function(a,b){-1!=b.indexOf("_GROUP")?this._oDiagram.nodeTemplateMap.add(b,k(a)):this._oDiagram.nodeTemplateMap.add(b,h(a))},this)},_initLinkTemplates:function(){var a=this,c=(this.option("htLinkType"),{selectionAdorned:!1,contextClick:this._onLinkContextClicked.bind(this),layerName:"Foreground",reshapable:!1,corner:10,cursor:"pointer"}),e=this.option("htLinkTheme"),f=this.option("sImageDir"),g=e["default"],h=e.bad,i=function(d){return a.$(b.Link,c,new b.Binding("routing","routing",function(a){return b.Link[a]}),new b.Binding("curve","curve",function(a){return b.Link[a]}),new b.Binding("curviness","curviness"),a.$(b.Shape,{name:"LINK",isPanelMain:!0,stroke:d.borderColor,strokeWidth:1.5}),a.$(b.Shape,{name:"ARROW",toArrow:"standard",fill:d.borderColor,stroke:null,scale:1.5}),a.$(b.Panel,b.Panel.Auto,a.$(b.Shape,"RoundedRectangle",{name:"LINK2",fill:"#ffffff",stroke:"#ffffff",portId:"",fromLinkable:!0,toLinkable:!0}),a.$(b.Panel,b.Panel.Horizontal,{margin:4},a.$(b.Picture,{source:f+"FILTER.png",width:14,height:14,margin:1,visible:!1,imageStretch:b.GraphObject.Uniform},new b.Binding("visible","isFiltered")),a.$(b.TextBlock,{name:"LINK_TEXT",textAlign:d.fontAlign,font:d.fontFamily,margin:d.margin},new b.Binding("text","totalCount",function(a){return Number(a,10).toLocaleString()}),new b.Binding("stroke","hasAlert",function(a){return a?h.fontColor:g.fontColor})))))};this._oDiagram.linkTemplate=i(g),d.each(e,function(a,b){"default"!==b&&this._oDiagram.linkTemplateMap.add(b,i(a))},this)},_initDiagramEnvironment:function(){var a=this.option("htPadding");this._oDiagram.toolManager.mouseWheelBehavior=b.ToolManager.WheelZoom,this._oDiagram.allowDrop=!1,this._oDiagram.initialAutoScale=b.Diagram.Uniform,this._oDiagram.toolManager.draggingTool.doCancel(),this._oDiagram.toolManager.draggingTool.doDeactivate(),this._oDiagram.toolManager.dragSelectingTool.isEnabled=!1,this._oDiagram.initialContentAlignment=b.Spot.Center,this._oDiagram.padding=new b.Margin(a.top,a.right,a.bottom,a.left),this._oDiagram.layout=this.$(b.LayeredDigraphLayout,{isOngoing:!1,layerSpacing:100,columnSpacing:30,setsPortSpots:!1});var c=this;this._oDiagram.addDiagramListener("ChangedSelection",function(a){var d=c._oDiagram.selection.first();d&&(d instanceof b.Node?c.nodeClickEventOnce||(c._onNodeClicked(a,d),c.nodeClickEventOnce=!0):d instanceof b.Link&&c._onLinkClicked(a,d)),c._updateHightlights()}),this._oDiagram.addDiagramListener("BackgroundSingleClicked",function(a){var b=c.option("fOnBackgroundClicked");angular.isFunction(b)&&b.call(c,a)}),this._oDiagram.addDiagramListener("BackgroundDoubleClicked",function(a){var b=c.option("fOnBackgroundDoubleClicked");angular.isFunction(b)&&b.call(c,a)}),this._oDiagram.addDiagramListener("BackgroundContextClicked",function(a){var b=c.option("fOnBackgroundContextClicked");angular.isFunction(b)&&b.call(c,a)})},_initOverview:function(a){/^\/main/.test(a.path())?(this._oOverview=this.$(b.Overview,this.option("sOverviewId"),{observed:this._oDiagram}),this._oOverview.box.elt(0).figure="RoundedRectangle",this._oOverview.box.elt(0).stroke="#53069B",this._oOverview.box.elt(0).strokeWidth=4):c("#"+this.option("sOverviewId")).hide()},load:function(a){this.nodeClickEventOnce=!1,this._sLastModelData=a,this._oDiagram.model=b.Model.fromJson(a),this._oDiagram.undoManager.isEnabled=!0},clear:function(){this._oDiagram.model=b.Model.fromJson({})},_resetHighlights:function(){for(var a=this._oDiagram.nodes,b=this._oDiagram.links;a.next();)a.value.highlight=!1;for(;b.next();)b.value.highlight=!1},_updateHightlights:function(a){if(a=a||this._oDiagram.selection.first(),null!==a){this._resetHighlights(),a.highlight="self",a instanceof b.Node?(this._linksTo(a,"from"),this._linksFrom(a,"to")):a instanceof b.Link&&(this._nodesTo(a,"from"),this._nodesFrom(a,"to"));for(var c=this._oDiagram.nodes,d=this._oDiagram.links;c.next();)this._highlightNode(c.value.findObject("NODE_SHAPE"),c.value.findObject("NODE_TEXT"),c.value.highlight);for(;d.next();)this._highlightLink(d.value.findObject("LINK"),d.value.highlight),this._highlightLink(d.value.findObject("ARROW"),d.value.highlight,!0),this._highlightLinkText(d.value.findObject("LINK_TEXT"),d.value.highlight)}},highlightNodeByKey:function(a){var b=this._oDiagram.findNodeForKey(a);if(b){var c=this._oDiagram.findPartForKey(a);this._oDiagram.select(c),this._updateHightlights(b)}},highlightLinkByFromTo:function(a,b){var c=this._getLinkObjectByFromTo(a,b);c&&(this._oDiagram.select(this._oDiagram.findPartForData(c)),this._updateHightlights(this._oDiagram.findLinkForData(c)))},_getLinkObjectByFromTo:function(a,b){for(var c=this._oDiagram.model.linkDataArray,d=0,e=c.length;e>d;d+=1){var f=c[d];if(f.from===a&&f.to===b)return f}return!1},_highlightNode:function(a,b,c){if(null!==a&&null!==b){var d=0;if(c){a.stroke=this.option("htHighlightNode").borderColor,a.strokeWidth=2,a.part.isShadowed=!0;var e=new RegExp(this._query,"i"),f=this.option("htHighlightNode").fontColor,g=this.option("htNodeTheme")["default"].fontColor;if(""!==this._query)if(angular.isDefined(b.rowCount)){for(d=0;dd;d++)for(var k=i.elt(d).elt(1),l=0;l=0;e--)c[e]!=a&&b=0;b--)this._aRawData.unshift(a[b]),this._oHash[this.makeID(a[b])]=a[b];var e=this._getAfterDataBoundary(a,d);for(b=e;bd)for(b=d;be;e++){var f=a[e].eventTimestamp;if(!(c>f))break;b=e}return b},c.EventData.prototype._getAfterDataBoundary=function(a,b){var c=Number.MAX_SAFE_INTEGER,d=b+1,e=a.length;if(e>d)for(var f=this._aRawData[this._aRawData.length-1].eventTimestamp,g=d;e>g;g++){var h=a[g].eventTimestamp;if(h>f){c=g;break}}return c}}(window,jQuery),function(a,b){var c={ID_POSTFIX:"+event-circle",ID_SPLITER:"+"},d=a.TimeSlider;d.Events=function(a,b,c){this.timeSlider=a,this.group=b,this._oEventData=a.oEventData,this._init(c),this._addEventElements(),this._addEvents()},d.Events.prototype._init=function(a){this._oEventGroupElementHash={},this.opt={y:4,barLength:4,gapBarNCircle:2,circleRadius:8};for(var b in a)this.opt[b]=a[b];this._filterShadow=this.timeSlider.snap.filter(Snap.filter.shadow(1,1,1,"#000",.3))},d.Events.prototype._addEventElements=function(){for(var a=this._oEventData.count(),b=0;a>b;b++)this._addEventElement(this._oEventData.getDataByIndex(b),!0)},d.Events.prototype._addEventElement=function(a,b){var c=this._makeElement(a);return this.group[b?"append":"prepend"](c),this.timeSlider.oPositionManager.isInSliderTimeSeries(a.eventTimestamp)===!1&&this.hide(c),c},d.Events.prototype._makeID=function(a){return this._oEventData.makeID(a)+c.ID_POSTFIX},d.Events.prototype._makeElement=function(a){var b=this.opt,c=a.eventTimestamp,d=this._makeID(a),e=this.group.g().attr({"data-id":d,"data-time":c,transform:"translate("+this.timeSlider.oPositionManager.getPositionFromTime(c)+",0)"}).add(this.timeSlider.snap.line(0,b.y,0,b.y+b.barLength),this.timeSlider.snap.circle(0,b.y+b.circleRadius+b.gapBarNCircle+b.barLength,b.circleRadius).attr({fill:TimeSlider.EventColor[a.eventTypeCode],"class":"event",filter:this._filterShadow,"data-time":c}));return this._oEventGroupElementHash[d]=e,e},d.Events.prototype._addEvents=function(){var a=this;this.group.mouseover(function(b,c,d){a._fireEvent("inEvent",b,c,d)}),this.group.mouseout(function(b,c,d){a._fireEvent("outEvent",b,c,d)}),this.group.click(function(b,c,d){a._fireEvent("clickEvent",b,c,d)})},d.Events.prototype._fireEvent=function(a,b,d,e){this.timeSlider.fireEvent(a,[d,e,this._oEventData.getDataByKey(b.srcElement.parentNode.getAttribute("data-id").split(c.ID_SPLITER)[0])])},d.Events.prototype.reset=function(){var a=this;for(var b in this._oEventGroupElementHash){var d=this._oEventGroupElementHash[b],e=this._oEventData.getDataByKey(b.split(c.ID_SPLITER)[0]).eventTimestamp;a.timeSlider.oPositionManager.isInSliderTimeSeries(e)?(a.show(d),function(b,c){b.animate({transform:"translate("+c+",0)"},a.opt.duration)}(d,this.timeSlider.oPositionManager.getPositionFromTime(e))):!function(b,c){b.animate({transform:"translate("+c+",0)"},a.opt.duration,function(){a.hide(b)})}(d,a.timeSlider.oPositionManager.isBeforeSliderStartTime(e)?0:a.timeSlider.oPositionManager.getSliderEndPosition())}},d.Events.prototype.changeData=function(){var a=this.group.selectAll("g");if(0===a.length)return void this._addEventElements();var b,c,d,e=0,f=this._oEventData.count(),g=a.length,h=a[g-1];for(b=0;g>b;b++){var i=a[b],j=parseInt(i.attr("data-time"));for(c=e;f>c;c++){if(d=this._oEventData.getDataByIndex(c),!(d.eventTimestampe;e++){d=this._oEventData.getDataByIndex(e);var k=this._makeElement(d);h.after(k),h=k}this.reset()},d.Events.prototype.emptyData=function(){for(var a in this._oEventGroupElementHash)this._oEventGroupElementHash[a].remove();this._oEventGroupElementHash={}},d.Events.prototype.show=function(a){a.attr("display","block")},d.Events.prototype.hide=function(a){a.attr("display","none")}}(window,jQuery),function(a,b){var c={HANDLER_IMAGE_WIDTH:30,HANDLER_IMAGE_HEIGHT:18},d=a.TimeSlider;d.Handler=function(a,b,d,e,f,g){this.timeSlider=a,this.group=b,this.opt=d,this._previousX=d.x,this._handleSrc=d.handleSrc||c.NORMAL_IMG,this._handleDownSrc=this._getHandleDownSrc(),this.callbackStart=e,this.callbackDrag=f,this.callbackEnd=g,this._addElements(),this.setX(d.x),this.addEvent()},d.Handler.prototype._getHandleDownSrc=function(){var a=this._handleSrc.lastIndexOf(".");return this._handleSrc.substring(0,a)+"_down"+this._handleSrc.substring(a)},d.Handler.prototype._addElements=function(){this.handlerGrip=this.timeSlider.snap.image(this._handleSrc,-(c.HANDLER_IMAGE_WIDTH/2),-(c.HANDLER_IMAGE_HEIGHT/2),c.HANDLER_IMAGE_WIDTH,c.HANDLER_IMAGE_HEIGHT),this.handlerGroup=this.group.g(),this.handlerGroup.add(this.timeSlider.snap.line(0,0,0,this.opt.height),this.handlerGrip)},d.Handler.prototype.addEvent=function(a){var b=this,c=-1;this.handlerGrip.mousedown(function(a,b,c){a.stopPropagation()}),this.handlerGrip.click(function(a,b,c){a.stopPropagation()}),this.handlerGrip.drag(function(a,d,e,f,g){var h=e-b.opt.margin;b._isInRestirctionZone(h)!==!1&&(b.handlerGroup.attr({transform:"translate("+h+", 0)"}),c=h,b.callbackDrag(h))},function(a,c,d){d.stopPropagation(),b.handlerGrip.attr("href",b._handleDownSrc),b.callbackStart(a-b.opt.margin)},function(a){a.stopPropagation(),b.handlerGrip.attr("href",b._handleSrc),b._previousX!==c&&-1!==c?(b.callbackEnd(!0,c),b._previousX=c):b.callbackEnd(!1)})},d.Handler.prototype.setX=function(a){this.handlerGroup.animate({transform:"translate("+a+", 0)"},this.opt.duration,mina.easeout)},d.Handler.prototype._isInRestirctionZone=function(a){return!(a<=this.opt.zone[0]||a>=this.opt.zone[1])},d.Handler.prototype.setZone=function(a,b){this.opt.zone=[a,b]},d.Handler.prototype.setPositionAndZone=function(a,b){this.setX(a),this.callbackDrag(a),this.setZone(b[0],b[1])}}(window,jQuery),function(a,b){var c={SIZE:30},d=a.TimeSlider;d.LoadingIndicator=function(a,b,c){this.timeSlider=a,this.opt=c,this.group=b,this._bRunn=!1,this._addElements(),this.show()},d.LoadingIndicator.prototype._addElements=function(){var a=c.SIZE/2,b=this.opt.width/2-a,d=this.opt.height/2-a;this.group.add(this.timeSlider.snap.rect(0,0,this.opt.width,this.opt.height)),this.elClockwiseBox=this.timeSlider.snap.rect(b,d,c.SIZE,c.SIZE).attr({stroke:"rgba(197, 197, 197, .9)"}),this.elAnitclockwiseBox=this.timeSlider.snap.rect(b,d,c.SIZE,c.SIZE).attr({stroke:"rgba(239, 246, 105, .9)"}),this.group.add(this.elClockwiseBox,this.elAnitclockwiseBox)},d.LoadingIndicator.prototype.show=function(){this.group.attr("display","block"),this._bRunn=!0,this._animate(this.elClockwiseBox,0,360,mina.easeout),this._animate(this.elAnitclockwiseBox,45,-315,mina.easein)},d.LoadingIndicator.prototype._animate=function(a,b,c,d){var e=this;Snap.animate(b,c,function(b){a.attr("transform","rotate("+b+"deg)")},e.opt.duration,d,function(){e._bRunn===!0&&e._animate(a,c,b,d)})},d.LoadingIndicator.prototype.hide=function(){this.group.attr("display","none"),this._bRunn=!1}}(window,jQuery),function(a,b){var c={xAxisTicks:5},d=a.TimeSlider;d.PositionManager=function(a){this._width=a.width,this._minSliderTimeSeries=a.minSliderTimeSeries,this._maxSelectionTimeSeries=a.maxSelectionTimeSeries,this._initInnerVar(),this._setSliderTimeSeries(a.sliderTimeSeries[0],a.sliderTimeSeries[1]),this._initSelectionTimeSeries(a.handleTimeSeries||[]),this._resetSelectionByTime(),this._xAxisTicks=a.xAxisTicks||c.xAxisTicks,this.setSelectTime(a.selectTime)},d.PositionManager.prototype._initInnerVar=function(){this._aSelectionTimeSeries=[],this._aSelectionPosition=[]},d.PositionManager.prototype._setSliderTimeSeries=function(a,b){this._startTime=a,this._endTime=b,this._calcuTimePerPoint()},d.PositionManager.prototype._initSelectionTimeSeries=function(a){2!=a.length&&(a=[this._startTime,this._endTime]),a[1]-a[0]>this._maxSelectionTimeSeries&&(a[0]=a[1]-this._maxSelectionTimeSeries),this._setSelectionTimeSeries(a[0],a[1])},d.PositionManager.prototype._resetSelectionByPosition=function(){this._setSelectionTimeSeries(this.getTimeFromPosition(this._aSelectionPosition[0]),this.getTimeFromPosition(this._aSelectionPosition[1]))},d.PositionManager.prototype._setSelectionTimeSeries=function(a,b){this._aSelectionTimeSeries[0]=null===a?this._aSelectionTimeSeries[0]:a,this._aSelectionTimeSeries[1]=null===b?this._aSelectionTimeSeries[1]:b},d.PositionManager.prototype._resetSelectionByTime=function(){this._setSelectionPosition(this.getPositionFromTime(this._aSelectionTimeSeries[0]),this.getPositionFromTime(this._aSelectionTimeSeries[1]))},d.PositionManager.prototype._setSelectionPosition=function(a,b){this._aSelectionPosition[0]=null===a?this._aSelectionPosition[0]:a,this._aSelectionPosition[1]=null===b?this._aSelectionPosition[1]:b},d.PositionManager.prototype.isInMaxSelectionTimeSeries=function(a,b){return b-a<=this._maxSelectionTimeSeries},d.PositionManager.prototype.getNewSelectionTimeSeriesFromStart=function(a){return[a,a+this._maxSelectionTimeSeries]},d.PositionManager.prototype.getNewSelectionTimeSeriesFromEnd=function(a){return[a-this._maxSelectionTimeSeries,a]},d.PositionManager.prototype.isBeforeSliderStartTime=function(a){return athis._endTime},d.PositionManager.prototype.getSliderEndTime=function(){return this._endTime},d.PositionManager.prototype.setWidth=function(a){this._width=a,this._calcuTimePerPoint(),this._reset()},d.PositionManager.prototype.getSliderEndPosition=function(){return this._width},d.PositionManager.prototype.getSliderStartTimeStr=function(){return this._formatDate(new Date(this._startTime))},d.PositionManager.prototype.getSliderEndTimeStr=function(){return this._formatDate(new Date(this._endTime))},d.PositionManager.prototype.getFullTimeStr=function(a){return this._formatDate(new Date(this.getTimeFromPosition(a)))},d.PositionManager.prototype._formatDate=function(a){return a.getFullYear()+"."+this._twoChipers(a.getMonth()+1)+"."+this._twoChipers(a.getDate())+" "+this._twoChipers(a.getHours())+":"+this._twoChipers(a.getMinutes())+":"+this._twoChipers(a.getSeconds())},d.PositionManager.prototype._twoChipers=function(a){return 10>a?"0"+a:a},d.PositionManager.prototype.isInSelectionZone=function(a){return a>=this._aSelectionPosition[0]&&a<=this._aSelectionPosition[1]},d.PositionManager.prototype.isInSliderTimeSeries=function(a){return a>=this._startTime&&a<=this._endTime},d.PositionManager.prototype.getSliderTimeSeries=function(){return[this._startTime,this._endTime]},d.PositionManager.prototype.getSelectionTimeSeries=function(){return[this._aSelectionTimeSeries[0],this._aSelectionTimeSeries[1]]},d.PositionManager.prototype.getSelectionPosition=function(){return[this._aSelectionPosition[0],this._aSelectionPosition[1]]},d.PositionManager.prototype.isInSelectionZoneSelectPoint=function(){return this._selectPosition>=this._aSelectionPosition[0]&&this._selectPosition<=this._aSelectionPosition[1]},d.PositionManager.prototype.getSelectPosition=function(){return this._selectPosition},d.PositionManager.prototype.setSelectTime=function(a){this._selectTime=a,this._selectPosition=this.getPositionFromTime(a)},d.PositionManager.prototype.setSelectPosition=function(a){this._selectPosition=a,this._selectTime=this.getTimeFromPosition(a)},d.PositionManager.prototype.getTimeFromPosition=function(a){return this._startTime+this._timePerPoint*a},d.PositionManager.prototype.getPositionFromTime=function(a){return parseInt((a-this._startTime)/this._timePerPoint)},d.PositionManager.prototype.calcuSelectionZone=function(){var a=parseInt((this._aSelectionPosition[1]-this._aSelectionPosition[0])/2),b=this._selectPosition-a,c=this._selectPosition+a;0>b?(c+=Math.abs(b),b=0):c>this._width&&(b-=c-this._width,c=this._width),this._setSelectionTimeSeries(this.getTimeFromPosition(b),this.getTimeFromPosition(c)),this._setSelectionPosition(b,c)},d.PositionManager.prototype.getXBarPosition=function(){for(var a=this,b=this._xAxisTicks+1,c=parseInt(this._width/b),d=[],e=0;b>e;e++)if(0!==e){var f=e*c;d.push({x:f,time:a.getTimeStr(f)})}return d},d.PositionManager.prototype.getTimeStr=function(a){var b=a*this._timePerPoint+this._startTime,c=new Date(b);return this._twoChipers(c.getMonth()+1)+"."+this._twoChipers(c.getDate())+" "+this._twoChipers(c.getHours())+":"+this._twoChipers(c.getMinutes())},d.PositionManager.prototype.setSelectionStartPosition=function(a){this._setSelectionTimeSeries(this.getTimeFromPosition(a),null),this._setSelectionPosition(a,null)},d.PositionManager.prototype.setSelectionEndPosition=function(a){this._setSelectionTimeSeries(null,this.getTimeFromPosition(a)),this._setSelectionPosition(null,a)},d.PositionManager.prototype.zoomIn=function(){if(this._startTime!==this._aSelectionTimeSeries[0]||this._endTime!==this._aSelectionTimeSeries[1]){var a=parseInt((this._endTime-this._startTime)/4),b=this._selectTime-a,c=this._selectTime+a;if(c-bc?c:this._aSelectionTimeSeries[1]+e;this._setSelectionTimeSeries(b,f)}if(this._aSelectionTimeSeries[1]>c){e=this._aSelectionTimeSeries[1]-c;var g=this._aSelectionTimeSeries[0]-ethis.opt.headerZoneHeight&&cb;b++)this._addEventElement(this._oEventData.getDataByIndex(b))},d.StateLine.prototype._addEventElement=function(a){if("undefined"!=typeof a.durationStartTimestamp){if(this.timeSlider.oPositionManager.isInSliderTimeSeries(a.durationStartTimestamp)===!1&&this.timeSlider.oPositionManager.isInSliderTimeSeries(a.durationEndTimestamp)===!1)return;this._hasDurationData=!0,this._addLine(this.timeSlider.oPositionManager.getPositionFromTime(a.durationStartTimestamp),this._getX2(a),a)}},d.StateLine.prototype._makeID=function(a){return this._oEventData.makeID(a)+c.ID_POSTFIX},d.StateLine.prototype._addLine=function(a,b,c){var d=this._makeID(c),e=this._makeLine(a,b,this.opt.topLineY,c.eventTypeCode,d),f=this._makeLine(a,b,this.opt.bottomLineY,c.eventTypeCode,d);this._oLineElementHash[d]=[e,f],this.group.add(e,f)},d.StateLine.prototype._makeLine=function(a,b,c,d,e){return this.timeSlider.snap.line(a,c,b,c).attr({stroke:TimeSlider.EventColor[d],"data-id":e,strokeWidth:this.opt.thickness})},d.StateLine.prototype._hasEventData=function(a){return"undefined"!=typeof this._oLineElementHash[a]},d.StateLine.prototype._getX2=function(a){return this.timeSlider.oPositionManager.getPositionFromTime(-1==a.durationEndTimestamp?this.timeSlider.oPositionManager.getSliderEndTime():a.durationEndTimestamp);
+/*! pinpoint - v1.5.2 - 2016-03-17*/!function(a,b){"use strict";var c=function(a,c){this.$snap=b("#"+a),this.snap=Snap("#"+a),this._init(c),this._initControlClass(),this._addInnerEventListener()};c.prototype._init=function(a){this.groups={},this._aListener={inEvent:[],outEvent:[],clickEvent:[],selectTime:[],changeSliderTimeSeries:[],changeSelectionZone:[]},this.opt={duration:300,xAxisTicks:5,eventZoneHeight:30,headerZoneHeight:20,stateLineThickness:4,minSliderTimeSeries:6e3,maxSelectionTimeSeries:1728e5,headerTextTopPadding:10,selectionPointRadius:5},this.opt.minSliderTimeSeries=1e3*(this.opt.xAxisTicks+1);var b;for(b in a)this.opt[b]=a[b];this.oEventData=new c.EventData(this.opt.eventData||[]),this._checkOffset()},c.prototype._initControlClass=function(a){this.oPositionManager=new c.PositionManager({width:this.opt.width,selectTime:this.opt.selectTime,xAxisTicks:this.opt.xAxisTicks,handleTimeSeries:this.opt.handleTimeSeries,sliderTimeSeries:this.opt.timeSeries,minSliderTimeSeries:this.opt.minSliderTimeSeries,maxSelectionTimeSeries:this.opt.maxSelectionTimeSeries});var b=this.opt.height-this.opt.headerZoneHeight-this.opt.eventZoneHeight;this.oLoading=new c.LoadingIndicator(this,this.getGroup("loading",c.GROUP_TYPE.TOP_BASE,c.oDrawOrder.loading),{width:this.opt.width,height:this.opt.height,duration:2e3}),this.oBackground=new c.Background(this,this.getGroup("background",c.GROUP_TYPE.CONTENT_BASE,c.oDrawOrder.background),{top:0,left:0,width:this.opt.width,height:b,duration:this.opt.duration}),this.oSelectionManager=new c.SelectionManager(this,{margin:this.opt.left,height:this.opt.height,duration:this.opt.duration,handleSrc:this.opt.handleSrc,eventZoneHeight:this.opt.eventZoneHeight,headerZoneHeight:this.opt.headerZoneHeight,contentZoneHeight:b,selectionPointRadius:this.opt.selectionPointRadius}),this.oXAxis=new c.XAxis(this,this.getGroup("x-axis",c.GROUP_TYPE.TOP_BASE,c.oDrawOrder["x-axis"]),{endY:this.opt.height-this.opt.eventZoneHeight,width:this.opt.width,textY:this.opt.headerTextTopPadding,startY:this.opt.headerZoneHeight,duration:this.opt.duration}),this.oStateLine=new c.StateLine(this,this.getGroup("state-line",c.GROUP_TYPE.TOP_BASE,c.oDrawOrder["state-line"]),{width:this.opt.width,duration:this.opt.duration,topLineY:this.opt.headerZoneHeight,thickness:this.opt.stateLineThickness,timeSeries:this.opt.timeSeries,bottomLineY:this.opt.height-this.opt.eventZoneHeight}),this.oEvents=new c.Events(this,this.getGroup("events",c.GROUP_TYPE.BOTTOM_BASE,c.oDrawOrder.events),{duration:this.opt.duration}),this.oLoading.hide()},c.prototype.getGroup=function(a,b,c){if(this.groups[a])return this.groups[a];var d=this.groups[a]=this.snap.g().attr({"class":a,"data-order":c});return this._setTransform(d,b),this._sortGroup(d,c),this.groups[a]},c.prototype._setTransform=function(a,b){switch(b){case c.GROUP_TYPE.TOP_BASE:break;case c.GROUP_TYPE.CONTENT_BASE:a.attr({transform:"translate(0, "+this.opt.headerZoneHeight+")"});break;case c.GROUP_TYPE.BOTTOM_BASE:a.attr({transform:"translate(0, "+(this.opt.height-this.opt.eventZoneHeight)+")"})}},c.prototype._sortGroup=function(a,b){for(var c=this.snap.selectAll("g"),d=null,e=c.length-1;e>=0;e--)c[e]!=a&&b=0;b--)this._aRawData.unshift(a[b]),this._oHash[this.makeID(a[b])]=a[b];var e=this._getAfterDataBoundary(a,d);for(b=e;bd)for(b=d;be;e++){var f=a[e].eventTimestamp;if(!(c>f))break;b=e}return b},c.EventData.prototype._getAfterDataBoundary=function(a,b){var c=Number.MAX_SAFE_INTEGER,d=b+1,e=a.length;if(e>d)for(var f=this._aRawData[this._aRawData.length-1].eventTimestamp,g=d;e>g;g++){var h=a[g].eventTimestamp;if(h>f){c=g;break}}return c}}(window,jQuery),function(a,b){var c={ID_POSTFIX:"+event-circle",ID_SPLITER:"+"},d=a.TimeSlider;d.Events=function(a,b,c){this.timeSlider=a,this.group=b,this._oEventData=a.oEventData,this._init(c),this._addEventElements(),this._addEvents()},d.Events.prototype._init=function(a){this._oEventGroupElementHash={},this.opt={y:4,barLength:4,gapBarNCircle:2,circleRadius:8};for(var b in a)this.opt[b]=a[b];this._filterShadow=this.timeSlider.snap.filter(Snap.filter.shadow(1,1,1,"#000",.3))},d.Events.prototype._addEventElements=function(){for(var a=this._oEventData.count(),b=0;a>b;b++)this._addEventElement(this._oEventData.getDataByIndex(b),!0)},d.Events.prototype._addEventElement=function(a,b){var c=this._makeElement(a);return this.group[b?"append":"prepend"](c),this.timeSlider.oPositionManager.isInSliderTimeSeries(a.eventTimestamp)===!1&&this.hide(c),c},d.Events.prototype._makeID=function(a){return this._oEventData.makeID(a)+c.ID_POSTFIX},d.Events.prototype._makeElement=function(a){var b=this.opt,c=a.eventTimestamp,d=this._makeID(a),e=this.group.g().attr({"data-id":d,"data-time":c,transform:"translate("+this.timeSlider.oPositionManager.getPositionFromTime(c)+",0)"}).add(this.timeSlider.snap.line(0,b.y,0,b.y+b.barLength),this.timeSlider.snap.circle(0,b.y+b.circleRadius+b.gapBarNCircle+b.barLength,b.circleRadius).attr({fill:TimeSlider.EventColor[a.eventTypeCode],"class":"event",filter:this._filterShadow,"data-time":c}));return this._oEventGroupElementHash[d]=e,e},d.Events.prototype._addEvents=function(){var a=this;this.group.mouseover(function(b,c,d){a._fireEvent("inEvent",b,c,d)}),this.group.mouseout(function(b,c,d){a._fireEvent("outEvent",b,c,d)}),this.group.click(function(b,c,d){a._fireEvent("clickEvent",b,c,d)})},d.Events.prototype._fireEvent=function(a,b,d,e){this.timeSlider.fireEvent(a,[d,e,this._oEventData.getDataByKey(b.srcElement.parentNode.getAttribute("data-id").split(c.ID_SPLITER)[0])])},d.Events.prototype.reset=function(){var a=this;for(var b in this._oEventGroupElementHash){var d=this._oEventGroupElementHash[b],e=this._oEventData.getDataByKey(b.split(c.ID_SPLITER)[0]).eventTimestamp;a.timeSlider.oPositionManager.isInSliderTimeSeries(e)?(a.show(d),function(b,c){b.animate({transform:"translate("+c+",0)"},a.opt.duration)}(d,this.timeSlider.oPositionManager.getPositionFromTime(e))):!function(b,c){b.animate({transform:"translate("+c+",0)"},a.opt.duration,function(){a.hide(b)})}(d,a.timeSlider.oPositionManager.isBeforeSliderStartTime(e)?0:a.timeSlider.oPositionManager.getSliderEndPosition())}},d.Events.prototype.changeData=function(){var a=this.group.selectAll("g");if(0===a.length)return void this._addEventElements();var b,c,d,e=0,f=this._oEventData.count(),g=a.length,h=a[g-1];for(b=0;g>b;b++){var i=a[b],j=parseInt(i.attr("data-time"));for(c=e;f>c;c++){if(d=this._oEventData.getDataByIndex(c),!(d.eventTimestampe;e++){d=this._oEventData.getDataByIndex(e);var k=this._makeElement(d);h.after(k),h=k}this.reset()},d.Events.prototype.emptyData=function(){for(var a in this._oEventGroupElementHash)this._oEventGroupElementHash[a].remove();this._oEventGroupElementHash={}},d.Events.prototype.show=function(a){a.attr("display","block")},d.Events.prototype.hide=function(a){a.attr("display","none")}}(window,jQuery),function(a,b){var c={HANDLER_IMAGE_WIDTH:30,HANDLER_IMAGE_HEIGHT:18},d=a.TimeSlider;d.Handler=function(a,b,d,e,f,g){this.timeSlider=a,this.group=b,this.opt=d,this._previousX=d.x,this._handleSrc=d.handleSrc||c.NORMAL_IMG,this._handleDownSrc=this._getHandleDownSrc(),this.callbackStart=e,this.callbackDrag=f,this.callbackEnd=g,this._addElements(),this.setX(d.x),this.addEvent()},d.Handler.prototype._getHandleDownSrc=function(){var a=this._handleSrc.lastIndexOf(".");return this._handleSrc.substring(0,a)+"_down"+this._handleSrc.substring(a)},d.Handler.prototype._addElements=function(){this.handlerGrip=this.timeSlider.snap.image(this._handleSrc,-(c.HANDLER_IMAGE_WIDTH/2),-(c.HANDLER_IMAGE_HEIGHT/2),c.HANDLER_IMAGE_WIDTH,c.HANDLER_IMAGE_HEIGHT),this.handlerGroup=this.group.g(),this.handlerGroup.add(this.timeSlider.snap.line(0,0,0,this.opt.height),this.handlerGrip)},d.Handler.prototype.addEvent=function(a){var b=this,c=-1;this.handlerGrip.mousedown(function(a,b,c){a.stopPropagation()}),this.handlerGrip.click(function(a,b,c){a.stopPropagation()}),this.handlerGrip.drag(function(a,d,e,f,g){var h=e-b.opt.margin;b._isInRestirctionZone(h)!==!1&&(b.handlerGroup.attr({transform:"translate("+h+", 0)"}),c=h,b.callbackDrag(h))},function(a,c,d){d.stopPropagation(),b.handlerGrip.attr("href",b._handleDownSrc),b.callbackStart(a-b.opt.margin)},function(a){a.stopPropagation(),b.handlerGrip.attr("href",b._handleSrc),b._previousX!==c&&-1!==c?(b.callbackEnd(!0,c),b._previousX=c):b.callbackEnd(!1)})},d.Handler.prototype.setX=function(a){this.handlerGroup.animate({transform:"translate("+a+", 0)"},this.opt.duration,mina.easeout)},d.Handler.prototype._isInRestirctionZone=function(a){return!(a<=this.opt.zone[0]||a>=this.opt.zone[1])},d.Handler.prototype.setZone=function(a,b){this.opt.zone=[a,b]},d.Handler.prototype.setPositionAndZone=function(a,b){this.setX(a),this.callbackDrag(a),this.setZone(b[0],b[1])}}(window,jQuery),function(a,b){var c={SIZE:30},d=a.TimeSlider;d.LoadingIndicator=function(a,b,c){this.timeSlider=a,this.opt=c,this.group=b,this._bRunn=!1,this._addElements(),this.show()},d.LoadingIndicator.prototype._addElements=function(){var a=c.SIZE/2,b=this.opt.width/2-a,d=this.opt.height/2-a;this.group.add(this.timeSlider.snap.rect(0,0,this.opt.width,this.opt.height)),this.elClockwiseBox=this.timeSlider.snap.rect(b,d,c.SIZE,c.SIZE).attr({stroke:"rgba(197, 197, 197, .9)"}),this.elAnitclockwiseBox=this.timeSlider.snap.rect(b,d,c.SIZE,c.SIZE).attr({stroke:"rgba(239, 246, 105, .9)"}),this.group.add(this.elClockwiseBox,this.elAnitclockwiseBox)},d.LoadingIndicator.prototype.show=function(){this.group.attr("display","block"),this._bRunn=!0,this._animate(this.elClockwiseBox,0,360,mina.easeout),this._animate(this.elAnitclockwiseBox,45,-315,mina.easein)},d.LoadingIndicator.prototype._animate=function(a,b,c,d){var e=this;Snap.animate(b,c,function(b){a.attr("transform","rotate("+b+"deg)")},e.opt.duration,d,function(){e._bRunn===!0&&e._animate(a,c,b,d)})},d.LoadingIndicator.prototype.hide=function(){this.group.attr("display","none"),this._bRunn=!1}}(window,jQuery),function(a,b){var c={xAxisTicks:5},d=a.TimeSlider;d.PositionManager=function(a){this._width=a.width,this._minSliderTimeSeries=a.minSliderTimeSeries,this._maxSelectionTimeSeries=a.maxSelectionTimeSeries,this._initInnerVar(),this._setSliderTimeSeries(a.sliderTimeSeries[0],a.sliderTimeSeries[1]),this._initSelectionTimeSeries(a.handleTimeSeries||[]),this._resetSelectionByTime(),this._xAxisTicks=a.xAxisTicks||c.xAxisTicks,this.setSelectTime(a.selectTime)},d.PositionManager.prototype._initInnerVar=function(){this._aSelectionTimeSeries=[],this._aSelectionPosition=[]},d.PositionManager.prototype._setSliderTimeSeries=function(a,b){this._startTime=a,this._endTime=b,this._calcuTimePerPoint()},d.PositionManager.prototype._initSelectionTimeSeries=function(a){2!=a.length&&(a=[this._startTime,this._endTime]),a[1]-a[0]>this._maxSelectionTimeSeries&&(a[0]=a[1]-this._maxSelectionTimeSeries),this._setSelectionTimeSeries(a[0],a[1])},d.PositionManager.prototype._resetSelectionByPosition=function(){this._setSelectionTimeSeries(this.getTimeFromPosition(this._aSelectionPosition[0]),this.getTimeFromPosition(this._aSelectionPosition[1]))},d.PositionManager.prototype._setSelectionTimeSeries=function(a,b){this._aSelectionTimeSeries[0]=null===a?this._aSelectionTimeSeries[0]:a,this._aSelectionTimeSeries[1]=null===b?this._aSelectionTimeSeries[1]:b},d.PositionManager.prototype._resetSelectionByTime=function(){this._setSelectionPosition(this.getPositionFromTime(this._aSelectionTimeSeries[0]),this.getPositionFromTime(this._aSelectionTimeSeries[1]))},d.PositionManager.prototype._setSelectionPosition=function(a,b){this._aSelectionPosition[0]=null===a?this._aSelectionPosition[0]:a,this._aSelectionPosition[1]=null===b?this._aSelectionPosition[1]:b},d.PositionManager.prototype.isInMaxSelectionTimeSeries=function(a,b){return b-a<=this._maxSelectionTimeSeries},d.PositionManager.prototype.getNewSelectionTimeSeriesFromStart=function(a){return[a,a+this._maxSelectionTimeSeries]},d.PositionManager.prototype.getNewSelectionTimeSeriesFromEnd=function(a){return[a-this._maxSelectionTimeSeries,a]},d.PositionManager.prototype.isBeforeSliderStartTime=function(a){return athis._endTime},d.PositionManager.prototype.getSliderEndTime=function(){return this._endTime},d.PositionManager.prototype.setWidth=function(a){this._width=a,this._calcuTimePerPoint(),this._reset()},d.PositionManager.prototype.getSliderEndPosition=function(){return this._width},d.PositionManager.prototype.getSliderStartTimeStr=function(){return this._formatDate(new Date(this._startTime))},d.PositionManager.prototype.getSliderEndTimeStr=function(){return this._formatDate(new Date(this._endTime))},d.PositionManager.prototype.getFullTimeStr=function(a){return this._formatDate(new Date(this.getTimeFromPosition(a)))},d.PositionManager.prototype._formatDate=function(a){return a.getFullYear()+"."+this._twoChipers(a.getMonth()+1)+"."+this._twoChipers(a.getDate())+" "+this._twoChipers(a.getHours())+":"+this._twoChipers(a.getMinutes())+":"+this._twoChipers(a.getSeconds())},d.PositionManager.prototype._twoChipers=function(a){return 10>a?"0"+a:a},d.PositionManager.prototype.isInSelectionZone=function(a){return a>=this._aSelectionPosition[0]&&a<=this._aSelectionPosition[1]},d.PositionManager.prototype.isInSliderTimeSeries=function(a){return a>=this._startTime&&a<=this._endTime},d.PositionManager.prototype.getSliderTimeSeries=function(){return[this._startTime,this._endTime]},d.PositionManager.prototype.getSelectionTimeSeries=function(){return[this._aSelectionTimeSeries[0],this._aSelectionTimeSeries[1]]},d.PositionManager.prototype.getSelectionPosition=function(){return[this._aSelectionPosition[0],this._aSelectionPosition[1]]},d.PositionManager.prototype.isInSelectionZoneSelectPoint=function(){return this._selectPosition>=this._aSelectionPosition[0]&&this._selectPosition<=this._aSelectionPosition[1]},d.PositionManager.prototype.getSelectPosition=function(){return this._selectPosition},d.PositionManager.prototype.setSelectTime=function(a){this._selectTime=a,this._selectPosition=this.getPositionFromTime(a)},d.PositionManager.prototype.setSelectPosition=function(a){this._selectPosition=a,this._selectTime=this.getTimeFromPosition(a)},d.PositionManager.prototype.getTimeFromPosition=function(a){return this._startTime+this._timePerPoint*a},d.PositionManager.prototype.getPositionFromTime=function(a){return parseInt((a-this._startTime)/this._timePerPoint)},d.PositionManager.prototype.calcuSelectionZone=function(){var a=parseInt((this._aSelectionPosition[1]-this._aSelectionPosition[0])/2),b=this._selectPosition-a,c=this._selectPosition+a;0>b?(c+=Math.abs(b),b=0):c>this._width&&(b-=c-this._width,c=this._width),this._setSelectionTimeSeries(this.getTimeFromPosition(b),this.getTimeFromPosition(c)),this._setSelectionPosition(b,c)},d.PositionManager.prototype.getXBarPosition=function(){for(var a=this,b=this._xAxisTicks+1,c=parseInt(this._width/b),d=[],e=0;b>e;e++)if(0!==e){var f=e*c;d.push({x:f,time:a.getTimeStr(f)})}return d},d.PositionManager.prototype.getTimeStr=function(a){var b=a*this._timePerPoint+this._startTime,c=new Date(b);return this._twoChipers(c.getMonth()+1)+"."+this._twoChipers(c.getDate())+" "+this._twoChipers(c.getHours())+":"+this._twoChipers(c.getMinutes())},d.PositionManager.prototype.setSelectionStartPosition=function(a){this._setSelectionTimeSeries(this.getTimeFromPosition(a),null),this._setSelectionPosition(a,null)},d.PositionManager.prototype.setSelectionEndPosition=function(a){this._setSelectionTimeSeries(null,this.getTimeFromPosition(a)),this._setSelectionPosition(null,a)},d.PositionManager.prototype.zoomIn=function(){if(this._startTime!==this._aSelectionTimeSeries[0]||this._endTime!==this._aSelectionTimeSeries[1]){var a=parseInt((this._endTime-this._startTime)/4),b=this._selectTime-a,c=this._selectTime+a;if(c-bc?c:this._aSelectionTimeSeries[1]+e;this._setSelectionTimeSeries(b,f)}if(this._aSelectionTimeSeries[1]>c){e=this._aSelectionTimeSeries[1]-c;var g=this._aSelectionTimeSeries[0]-ethis.opt.headerZoneHeight&&cb;b++)this._addEventElement(this._oEventData.getDataByIndex(b))},d.StateLine.prototype._addEventElement=function(a){if("undefined"!=typeof a.durationStartTimestamp){if(this.timeSlider.oPositionManager.isInSliderTimeSeries(a.durationStartTimestamp)===!1&&this.timeSlider.oPositionManager.isInSliderTimeSeries(a.durationEndTimestamp)===!1)return;this._hasDurationData=!0,this._addLine(this.timeSlider.oPositionManager.getPositionFromTime(a.durationStartTimestamp),this._getX2(a),a)}},d.StateLine.prototype._makeID=function(a){return this._oEventData.makeID(a)+c.ID_POSTFIX},d.StateLine.prototype._addLine=function(a,b,c){var d=this._makeID(c),e=this._makeLine(a,b,this.opt.topLineY,c.eventTypeCode,d),f=this._makeLine(a,b,this.opt.bottomLineY,c.eventTypeCode,d);this._oLineElementHash[d]=[e,f],this.group.add(e,f)},d.StateLine.prototype._makeLine=function(a,b,c,d,e){return this.timeSlider.snap.line(a,c,b,c).attr({stroke:TimeSlider.EventColor[d],"data-id":e,strokeWidth:this.opt.thickness})},d.StateLine.prototype._hasEventData=function(a){return"undefined"!=typeof this._oLineElementHash[a]},d.StateLine.prototype._getX2=function(a){return this.timeSlider.oPositionManager.getPositionFromTime(-1==a.durationEndTimestamp?this.timeSlider.oPositionManager.getSliderEndTime():a.durationEndTimestamp);
},d.StateLine.prototype.changeData=function(){for(var a=this._oEventData.count(),b=0;a>b;b++){var c=this._oEventData.getDataByIndex(b);this._hasEventData(this._makeID(c))===!1&&this._addEventElement(c)}this.reset()},d.StateLine.prototype.emptyData=function(){for(var a in this._oLineElementHash){var b=this._oLineElementHash[a];b[0].remove(),b[1].remove()}this._oLineElementHash={}},d.StateLine.prototype.setDefaultStateLineColor=function(a){this._baseColor=a,this._hasDurationData!==!0&&this._aBaseLine.forEach(function(b){b.attr("stroke",a)})},d.StateLine.prototype._resetBaseLineColor=function(){var a=this;this._aBaseLine.forEach(function(b){b.attr("stroke",a._hasDurationData===!0?TimeSlider.EventColor.base:a._baseColor)})},d.StateLine.prototype.reset=function(){var a=this,b=this.timeSlider.oPositionManager;for(var d in this._oLineElementHash){var e=this._oLineElementHash[d],f=this._oEventData.getDataByKey(d.split(c.ID_SPLITER)[0]);b.isInSliderTimeSeries(f.durationStartTimestamp)||b.isInSliderTimeSeries(f.durationEndTimestamp)?e.forEach(function(c){a.show(c),c.animate({x1:b.getPositionFromTime(f.durationStartTimestamp),x2:a._getX2(f)},a.opt.duration)}):e.forEach(function(b){a.hide(b)})}this._aBaseLine.forEach(function(c){c.animate({x2:b.getSliderEndPosition()},a.opt.duration)}),this._resetBaseLineColor()},d.StateLine.prototype.show=function(a){a.attr("display","block")},d.StateLine.prototype.hide=function(a){a.attr("display","none")}}(window,jQuery),function(a,b){var c=a.TimeSlider;c.TimeSeriesSignboard=function(a,b,c){this.timeSlider=a,this.group=b,this.opt=c,this._init(),this._addElements()},c.TimeSeriesSignboard.prototype._init=function(){this._halfHeight=this.opt.height-12},c.TimeSeriesSignboard.prototype._addElements=function(){this._elStartTime=this.group.text(0,this._halfHeight,this.timeSlider.oPositionManager.getSliderStartTimeStr()).attr({"text-anchor":"start"}),this._elEndTime=this.group.text(this.timeSlider.oPositionManager.getSliderEndPosition(),this._halfHeight,this.timeSlider.oPositionManager.getSliderEndTimeStr()).attr({"text-anchor":"end"}),this.group.add(this._elStartTime,this._elEndTime)},c.TimeSeriesSignboard.prototype.reset=function(){this._elStartTime.attr("text",this.timeSlider.oPositionManager.getSliderStartTimeStr()),this._elEndTime.attr("text",this.timeSlider.oPositionManager.getSliderEndTimeStr())},c.TimeSeriesSignboard.prototype.resize=function(){var a=this;this._elEndTime.animate({x:a.timeSlider.oPositionManager.getSliderEndPosition()},this.opt.duration,function(){a._elEndTime.attr("text",a.timeSlider.oPositionManager.getSliderEndTimeStr())})}}(window,jQuery),function(a,b){var c=a.TimeSlider;c.TimeSignboard=function(a,b,c){this.timeSlider=a,this.group=b,this.opt=c,this._textMaxWidth=100,this._xPadding=2,this._addElements()},c.TimeSignboard.prototype._addElements=function(){var a=this._isIn(this.opt.x),b=this.opt.x+(a?this._xPadding:-this._xPadding);this.timeText=this.group.text(b,26,this.timeSlider.oPositionManager.getFullTimeStr(this.opt.x)).attr({textAnchor:a?"start":"end"}),this.group.add(this.timeText)},c.TimeSignboard.prototype.setX=function(a){var b=this._isIn(a);this.timeText.attr({x:a+(b?this._xPadding:-this._xPadding),text:this.timeSlider.oPositionManager.getFullTimeStr(a),textAnchor:b?"start":"end"})},c.TimeSignboard.prototype._isIn=function(a){return"left"==this.opt.direction?a