<O T="Export">
<O N="Internal_Parameters" T="Group">
<P N="KerbRoute" V="iif( SlabList .NE. NULL , SlabList[0].SlabRoute , SlabJointList[0].JointRoute ) " />
<P N="e" V="0.01" D="Eğim" />
<P N="Chamfer" V="50" />
<P N="SlabList" V="filter( Slabs , x. ObjectType .EQ. 1 )" />
<P N="SlabJointList" V="filter( Slabs , x. ObjectType .EQ. 2 )" />
<O N="KerbLocation_R" T="Group">
<O N="R_Ref_Coordinates" T="Group">
<P N="Slab_R" V="map( SlabList , x.SlabRefline_R) " />
<P N="SlabJoint_R1" V="map( SlabJointList , x. ddr1)" />
<P N="SlabJoint_R2" V="map( SlabJointList , x. ddr2)" />
<P N="Kerb_R_Ref" V="sort(concat(Slab_R,SlabJoint_R1,SlabJoint_R2),x[0][0])" />
<P N="point_R" V="length(Kerb_R_Ref)" />
<O N="OnlineFuncR" T="Repeat" S="0" E="point_R-1" I="1" CTRL="i" i="0">
<O N="on2_R" T="Repeat" S="0" E="1" I="1" CTRL="j" j="0">
<P N="KerbSkew_R" V="online([Kerb_R_Ref[i][j],Kerb_M_Ref[i][j]],Off_y+KerbW)" />
<P N="KerbOff_R" V="online([Kerb_R_Ref[i][j],Kerb_M_Ref[i][j]],Off_y)" />
</O>
<P N="TEST1" V="map( on2_R , x. KerbSkew_R)" />
<P N="TEST2" V="map( on2_R , x. KerbOff_R)" />
</O>
<P N="Kerb_R_Ref1" V="map( OnlineFuncR , x. TEST1)" />
<P N="Kerb_R_Ref2" V="map( OnlineFuncR , x. TEST2)" />
</O>
</O>
<O N="KerbLocation_L" T="Group">
<O N="L_Ref_Coordinates" T="Group">
<P N="Slab_L" V="map( SlabList , x.SlabRefline_L) " />
<P N="SlabJoint_L1" V="map( SlabJointList , x. ddl1)" />
<P N="SlabJoint_L2" V="map( SlabJointList , x. ddl2)" />
<P N="Kerb_L_Ref" V="sort(concat(Slab_L,SlabJoint_L1,SlabJoint_L2),x[0][0])" />
<P N="point_L" V="length(Kerb_L_Ref)" />
<O N="OnlineFuncL" T="Repeat" S="0" E="point_L-1" I="1" CTRL="i" i="0">
<O N="on2_L" T="Repeat" S="0" E="1" I="1" CTRL="j" j="0">
<P N="KerbSkew_L" V="online([Kerb_L_Ref[i][j],Kerb_M_Ref[i][j]],Off_y+KerbW)" />
<P N="KerbOff_L" V="online([Kerb_L_Ref[i][j],Kerb_M_Ref[i][j]],Off_y)" />
</O>
<P N="TEST3" V="map( on2_L , x. KerbSkew_L)" />
<P N="TEST4" V="map( on2_L , x. KerbOff_L)" />
</O>
<P N="Kerb_L_Ref1" V="map( OnlineFuncL , x. TEST3)" />
<P N="Kerb_L_Ref2" V="map( OnlineFuncL , x. TEST4)" />
</O>
</O>
<O N="KerbLocation_M" T="Group">
<O N="M_Ref_Coordinates" T="Group">
<P N="Slab_M" V="map( SlabList , x.SlabRefline_M) " />
<P N="SlabJoint_M1" V="map( SlabJointList , x. ddm1)" />
<P N="SlabJoint_M2" V="map( SlabJointList , x. ddm2)" />
<P N="Kerb_M_Ref" V="sort(concat(Slab_M,SlabJoint_M1,SlabJoint_M2),x[0][0])" />
<P N="point_M" V="length(Kerb_M_Ref)" />
<O N="OnlineFuncM" T="Repeat" S="0" E="point_M-1" I="1" CTRL="i" i="0">
<O N="on2_M" T="Repeat" S="0" E="1" I="1" CTRL="j" j="0">
<P N="KerbSkew_M" V="online([Kerb_M_Ref[i][j],Kerb_R_Ref[i][j]],iif(EdgeType.EQ.1,-Off_y-KerbW,Off_y+KerbW))" />
<P N="KerbOff_M" V="online([Kerb_M_Ref[i][j],Kerb_R_Ref[i][j]],iif(EdgeType.EQ.1,-Off_y,Off_y))" />
</O>
<P N="TEST5" V="map( on2_M , x. KerbSkew_M)" />
<P N="TEST6" V="map( on2_M , x. KerbOff_M)" />
</O>
<P N="Kerb_M_Ref1" V="map( OnlineFuncM , x. TEST5)" />
<P N="Kerb_M_Ref2" V="map( OnlineFuncM , x. TEST6)" />
</O>
</O>
<O N="General" T="Group">
<P N="GeneralList1" V="iif( Location .EQ. 1 ,iif(EdgeType.EQ.1,Kerb_R_Ref2,Kerb_R_Ref1) , iif( Location .EQ. 2 ,iif(EdgeType.EQ.1,Kerb_L_Ref1,Kerb_L_Ref2) ,iif(EdgeType.EQ.1, Kerb_M_Ref2,Kerb_M_Ref2))) " />
<P N="GeneralList2" V="iif( Location .EQ. 1 ,iif(EdgeType.EQ.1,Kerb_R_Ref1,Kerb_R_Ref2) , iif( Location .EQ. 2 ,iif(EdgeType.EQ.1,Kerb_L_Ref2,Kerb_L_Ref1) ,iif(EdgeType.EQ.1, Kerb_M_Ref1,Kerb_M_Ref1))) " />
<P N="mappointlist" V="map( Elimination , x. Testing) " />
<P N="Pointlist" V="filter( mappointlist , x .NE. -999 )" />
<P N="RefLine_Points" V="iif(length(SlabJointList) .NE. 0 , Pointlist , GeneralList2) " />
</O>
<O N="Elimination" T="Repeat" S="0" E="Count-2" I="1" CTRL="i" i="0">
<P N="Testing" V="iif(GeneralList2[i][1][0] .EQ. GeneralList2[i+1][0][0],[GeneralList2[i][0],GeneralList2[i+1][1]],-999)" />
</O>
<P N="Count" V="length(GeneralList1)" />
<P N="TDelzR1" V="alignT(KerbRoute,GeneralList2 [0][0][0],GeneralList2[0][0][1])" />
<P N="TDelzR2" V="alignT(KerbRoute,GeneralList1[0][0][0],GeneralList1[0][0][1])" />
<P N="TDelzR" V="-TDelzR1+TDelzR2" />
</O>
<O N="Trial2" T="Repeat" S="0" E="Count-1" I="1" CTRL="i" i="0">
<O N="GuardRail_Ref" T="Volume" Alignment="KerbRoute" AlignH="Warp" AlignV="Warp" AlignT="Warp">
<O N="PT1" T="Point" X="GeneralList1[i][0][0]" Y="GeneralList1[i][0][1]" Z="GeneralList1[i][0][2]+KerbH+iif(TDelzR.LT.0,-TDelzR,0)" />
<O N="PT2" T="Point" X="GeneralList1[i][1][0]" Y="GeneralList1[i][1][1]" Z="GeneralList1[i][1][2]+KerbH+iif(TDelzR.LT.0,-TDelzR,0)" />
</O>
<O N="CarRail_Ref" T="Volume" Alignment="KerbRoute" AlignH="Warp" AlignV="Warp" AlignT="Warp">
<O N="PT1" T="Point" X="GeneralList2[i][0][0]" Y="GeneralList2[i][0][1]+iif(EdgeType .EQ.1,-Chamfer,Chamfer)" Z="GeneralList2[i][0][2]+KerbH-(KerbW-Chamfer)*e+iif(TDelzR.GT.0,TDelzR,0)" />
<O N="PT2" T="Point" X="GeneralList2[i][1][0]" Y="GeneralList2[i][1][1]+iif(EdgeType .EQ.1,-Chamfer,Chamfer)" Z="GeneralList2[i][1][2]+KerbH-(KerbW-Chamfer)*e+iif(TDelzR.GT.0,TDelzR,0)" />
</O>
<O N="Pavem_Ref" T="Volume" Alignment="KerbRoute" AlignH="Warp" AlignV="Warp" AlignT="Warp">
<O N="PT1" T="Point" X="GeneralList2[i][0][0]" Y="GeneralList2[i][0][1]" Z="GeneralList2[i][0][2]" />
<O N="PT2" T="Point" X="GeneralList2[i][1][0]" Y="GeneralList2[i][1][1]" Z="GeneralList2[i][1][2]" />
</O>
<O N="Ref_Lines_Controls" T="Group">
<P N="Guard_RailingRef" V="toglobal(GuardRail_Ref)" />
<P N="Car_RailingRef" V="toglobal(CarRail_Ref)" />
<P N="Pavement_Ref" V="toglobal(Pavem_Ref)" />
</O>
</O>
<O N="Ref_Coordinates" T="Group">
<P N="GuardCoordinates" V="map(Trial2, x.Guard_RailingRef)" />
<P N="CRCoordinates" V="map(Trial2, x.Car_RailingRef)" />
<P N="PavementCoordinates" V="map(Trial2 ,x.Pavement_Ref)" />
</O>
<O N="Design_Parameters" T="Group">
<P N="Pavement" V="refs('KBYS_Asfalt')" />
<P N="Pavement_thickness" V="iif(Pavement .EQ. NULL , 0 , Pavement[0].asf_h )" />
</O>
</O>