Вверх ↑
Разработчик
Ответов: 26163
Рейтинг: 2127
#1: 2012-12-01 16:12:03 ЛС | профиль | цитата
Ради интереса, более сложная задача -- создание динамических серверов различного функционала на основе полиморфного контейнера



Add(MainForm,2953706,161,98)
{
link(onCreate,8906787:doEnum,[])
}
Add(Button,13603362,238,189)
{
Left=135
Top=230
TabOrder=-1
Caption="to12345"
link(onClick,13642407:doOpen,[])
}
Add(Button,2083648,238,231)
{
Left=200
Top=230
TabOrder=-1
Caption="to54321"
link(onClick,15933531:doOpen,[])
}
Add(ListBox,13533703,532,105)
{
Left=20
Top=15
Width=345
Height=200
}
Add(TCP_Client,13642407,294,189)
{
Port=12345
IP="127.0.0.1"
}
Add(TCP_Client,15933531,294,231)
{
Port=54321
IP="127.0.0.1"
}
Add(Hub,12843787,434,98)
{
link(onEvent1,9611637:doData,[(460,104)(460,79)(346,79)(346,167)])
link(onEvent2,8186454:doString,[])
}
Add(DoData,9611637,371,161)
{
link(onEventData,5628658:##select,[(415,167)(415,89)(357,89)(357,111)])
link(Data,5628658:##eventIndex,[])
}
Add(FormatStr,8186454,469,105)
{
Mask="%1:%2"
link(onFString,13533703:doAdd,[])
link(Str2,5628658:Port,[(482,93)(433,93)(433,142)(384,142)])
}
Add(PolymorphMulti,5628658,371,98)
{
Childrens=#1:1|1:2|
Selected="2"
link(onConnect,12843787:doEvent1,[])
}
BEGIN_SDK
Add(EditPolyMulti,3710742,21,21)
{
WorkCount=#5:##add|8:##select|
EventCount=#9:onConnect|
VarCount=#12:##eventIndex|4:Port|
Point(##add)
Point(##eventIndex)
Point(##select)
}
END_SDK
BEGIN_SDK
Add(EditPolyMulti,13200575,21,21)
{
WorkCount=#5:##add|8:##select|
EventCount=#9:onConnect|
VarCount=#12:##eventIndex|4:Port|
Point(##add)
Point(##eventIndex)
Point(##select)
link(##add,11516806:doSeparateMT,[(31,27)(31,69)])
link(Port,6358031:Value,[(34,161)(97,161)])
}
Add(TCP_ServerEx,11479796,147,70)
{
ServerPort=0
link(onConnect,5525090:doString,[])
}
BEGIN_SDK
Add(EditMultiEx,6433093,21,21)
{
WorkCount=#6:##open|
EventCount=#9:onConnect|
}
Add(TCP_Connection,43502,63,63)
{
link(onConnect,6433093:onConnect,[(208,76)(208,27)])
}
END_SDK
Add(Memory,6358031,91,70)
{
link(onData,11479796:##open,[])
}
Add(MT_MultiData,11516806,42,63)
{
link(onData1,6218638:doData,[(92,69)(92,34)])
link(onData2,6358031:doValue,[])
}
Add(FormatStr,5525090,210,70)
{
Mask="%1 -- %2"
link(onFString,13200575:onConnect,[(282,76)(282,27)])
link(Str1,5171267:Value,[])
}
Add(Memory,5171267,210,28)
{
}
Add(DoData,6218638,147,28)
{
Data=String(F1)
link(onEventData,5171267:doValue,[])
}
END_SDK
BEGIN_SDK
Add(EditPolyMulti,11353687,21,21)
{
WorkCount=#5:##add|8:##select|
EventCount=#9:onConnect|
VarCount=#12:##eventIndex|4:Port|
Point(##add)
Point(##eventIndex)
Point(##select)
link(##add,11516806:doSeparateMT,[(31,27)(31,69)])
link(Port,6358031:Value,[(34,161)(97,161)])
}
Add(TCP_ServerEx,11479796,147,70)
{
ServerPort=0
link(onConnect,5525090:doString,[])
}
BEGIN_SDK
Add(EditMultiEx,6433093,21,21)
{
WorkCount=#6:##open|
EventCount=#9:onConnect|
}
Add(TCP_Connection,43502,63,63)
{
link(onConnect,6433093:onConnect,[(208,76)(208,27)])
}
END_SDK
Add(Memory,6358031,91,70)
{
link(onData,11479796:##open,[])
}
Add(MT_MultiData,11516806,42,63)
{
link(onData1,6218638:doData,[(92,69)(92,34)])
link(onData2,6358031:doValue,[])
}
Add(FormatStr,5525090,210,70)
{
Mask="%1 -- %2"
link(onFString,11353687:onConnect,[(282,76)(282,27)])
link(Str1,5171267:Value,[])
}
Add(Memory,5171267,210,28)
{
}
Add(DoData,6218638,147,28)
{
Data=String(F2)
link(onEventData,5171267:doValue,[])
}
END_SDK
Add(StrList,4596394,224,49)
{
Strings=#7:1;12345|7:2;54321|
}
Add(MT_String,13756461,294,98)
{
link(onResult,5628658:##add,[])
}
Add(ArrayEnum,8906787,238,112)
{
link(onItem,13756461:doMTString,[])
link(Array,4596394:Array,[])
}

карма: 22

0