CN102214090A - Method and device for creating session window - Google Patents

Method and device for creating session window Download PDF

Info

Publication number
CN102214090A
CN102214090A CN2010101444980A CN201010144498A CN102214090A CN 102214090 A CN102214090 A CN 102214090A CN 2010101444980 A CN2010101444980 A CN 2010101444980A CN 201010144498 A CN201010144498 A CN 201010144498A CN 102214090 A CN102214090 A CN 102214090A
Authority
CN
China
Prior art keywords
child control
motherboard
child
control
interface portion
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN2010101444980A
Other languages
Chinese (zh)
Other versions
CN102214090B (en
Inventor
王文涛
刘晓宇
李斌
栾涛
陈曦
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201010144498.0A priority Critical patent/CN102214090B/en
Publication of CN102214090A publication Critical patent/CN102214090A/en
Application granted granted Critical
Publication of CN102214090B publication Critical patent/CN102214090B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a method and device for creating a session window, belonging to the field of computers. The method comprises the steps of: receiving a creation request, wherein the creation request carries a session type; creating a mother board and acquiring script description corresponding to the session type, wherein the script description at least comprises session area child controls; filling each child control in the description of the script description into the mother board; and registering each child control in the mother board, interacting each child control with the motor board, pasting the motor board to a window to obtain a session window, and creating a chat channel for the session window. The device comprises a receiving module, a creating module, a filling module and a registering module. The method and the device in the invention can be used for reducing the difficulty in developing a new session window and reducing the development cost.

Description

A kind of method and device of creating session window
Technical field
The present invention relates to computer realm, particularly a kind of method and device of creating session window.
Background technology
Session window is the important component part of instant communication software.In instant communication software, the basic function of session window is the interface that information interchange is provided for the contact person.
Wherein, set up a window and in this window, editing area is set, set up the chat channel for this window again, just obtain having the session window of basic function.In addition, the abundant application of carrying in session window if desired then realizes the plug-in unit of using and is provided with carrying out mutual interaction code between each plug-in unit having to load on the session window of basic function.
In realizing process of the present invention, the inventor finds that there is following problem at least in prior art:
Change layout, the part plug-in unit in the upgrading session window or the session window that makes new advances by the part developing plug of revising former session window of session window if desired, then need to revise the interaction code between each plug-in unit in the former session window, so increased development difficulty and cost.
Summary of the invention
In order to alleviate development difficulty and to reduce cost of development, the invention provides a kind of method and device of creating session window.Described technical scheme is as follows:
A kind of method of creating session window is characterized in that, described method comprises:
Receive request to create, carry conversation type in the described request to create;
The script describing of creating motherboard and obtaining described conversation type correspondence comprises the conversation area child control at least in the described script describing;
Each child control of describing in the described script describing is filled in the described motherboard;
Described each child control of registration makes described each child control and described motherboard mutual in described motherboard, described motherboard is sticked on window obtain session window, and set up chat channels for described session window.
Described each child control of describing in the described script describing is filled in the described motherboard, specifically comprises:
By described script describing is resolved, obtain the sign of described each child control and the layout information of described each child control;
According to the sign of described conversation type and described each child control, obtain the interface portion and the logical gate of described each child control;
According to the layout information of described each child control, the interface portion of described each child control is filled in the described motherboard, and the interface portion and the logical gate of described each child control are bound.
Described sign according to described conversation type and described each child control is obtained the interface portion and the logical gate of described each child control, specifically comprises:
According to the sign of described each child control, the interface portion of from the corresponding relation of sign and interface portion, searching described each child control;
According to the sign of described conversation type and described each child control, from the corresponding relation of sign, conversation type and logical gate, search the logical gate of described each child control.
Described child control comprises interface portion and logical gate, and any two child controls are undertaken by described motherboard alternately.
Described method also comprises:
In described session window, if described motherboard receives incident, inquire about each child control in the described motherboard, if inquire the child control that can handle described incident, the child control that then described incident is met at described inquiry is handled.
A kind of device of creating session window, described device comprises:
Receiver module is used to receive request to create, carries conversation type in the described request to create;
Creation module is used to the script describing creating motherboard and obtain described conversation type correspondence, comprises the conversation area child control in the described script describing at least;
Packing module, each child control that is used for described script describing is described is filled in the described motherboard;
Registering modules is used for making described each child control and described motherboard mutual at described each child control of described motherboard registration, described motherboard is sticked on window obtain session window, and set up chat channels for described session window.
Described packing module specifically comprises:
First acquiring unit is used for obtaining the sign of described each child control and the layout information of described each child control by described script describing is resolved;
Second acquisition unit is used for the sign according to described conversation type and described each child control, obtains the interface portion and the logical gate of described each child control;
Filler cells is used for the layout information according to described each child control, the interface portion of described each child control is filled in the described motherboard, and the interface portion and the logical gate of described each child control are bound.
Described second acquisition unit specifically comprises:
First searches subelement, is used for the sign according to described each child control, the interface portion of searching described each child control from the corresponding relation of sign and interface portion;
Second searches subelement, is used for the sign according to described conversation type and described each child control, searches the logical gate of described each child control from the corresponding relation of sign, conversation type and logical gate.
Described child control comprises interface portion and logical gate, and any two child controls are undertaken by described motherboard alternately.
Described device also comprises:
Enquiry module is used in described session window, if described motherboard receives incident, inquires about each child control in the described motherboard, if inquire the child control that can handle described incident, the child control that then described incident is met at described inquiry is handled.
By creating motherboard, and each child control of describing in the script describing is filled in the motherboard, by each child control is registered in the motherboard, make each child control and motherboard directly hand over mutually, motherboard is placed on again and obtains session window in the window, wherein, each child control in the session window is separate, any two child controls are undertaken alternately by motherboard, can also carry plug-in unit by child control and make session window have abundant application.Owing to do not have interaction code between any two child controls in the session window, when therefore changing the layout of former session window, do not need to revise the interaction code between each child control; If upgrade former session window or in former session window exploitation new session window, then as long as the part of upgrading or the child control at the part place of modification are made amendment, and this child control and other child controls are separate, so other herid former session window partially, so alleviate development difficulty and reduce cost of development.
Description of drawings
Fig. 1 is a kind of method flow diagram of creating session window that the embodiment of the invention 1 provides;
Fig. 2 is a kind of method flow diagram of creating session window that the embodiment of the invention 2 provides;
Fig. 3 is first kind of motherboard synoptic diagram that the embodiment of the invention 2 provides;
Fig. 4 is second kind of motherboard synoptic diagram that the embodiment of the invention 2 provides;
Fig. 5 is a kind of method flow diagram of creating session window that the embodiment of the invention 3 provides;
Fig. 6 is a kind of device synoptic diagram of creating session window that the embodiment of the invention 4 provides.
Embodiment
For making the purpose, technical solutions and advantages of the present invention clearer, embodiment of the present invention is described further in detail below in conjunction with accompanying drawing.
Embodiment 1
As shown in Figure 1, the embodiment of the invention 1 provides a kind of method of creating session window, comprising:
Step 101: receive request to create, wherein, carry conversation type in this request to create;
Step 102: create motherboard and obtain the script describing of this conversation type correspondence, wherein, comprise ChatMsg (conversation area) child control in the script describing at least;
Step 103: each child control of describing in this script describing is filled in the motherboard;
Step 104: make each child control and motherboard mutual by each child control of registration in motherboard, motherboard is sticked on window obtain session window, and set up chat channels for session window.
Wherein, any two child controls in the motherboard are all separate and cannot be directly mutual.ChatMsg has the function that realizes editing interface, fills the ChatMsg child control in motherboard, can make the session window of establishment have editing interface, and the contact person can carry out information interchange in this editing interface.
In embodiments of the present invention, by creating motherboard, and each child control of describing in the script describing is filled in the motherboard, by each child control is registered in the motherboard, make each child control and motherboard directly hand over mutually, motherboard is placed on obtains session window in the window again, wherein, each child control in the session window is separate, and any two child controls are undertaken alternately by motherboard, can also carry plug-in unit by child control and make session window have abundant application.Owing to do not have interaction code between any two child controls in the session window, when therefore changing the layout of former session window, do not need to revise the interaction code between each child control; If upgrade former session window or in former session window exploitation new session window, then as long as the part of upgrading or the child control at the part place of modification are made amendment, and this child control and other child controls are separate, so other herid former session window partially, so alleviate development difficulty and reduce cost of development, and make session window have the characteristic of the low coupling of high cohesion.
Embodiment 2
As shown in Figure 2, the embodiment of the invention provides a kind of method of creating session window, comprising:
Step 201: receive conversation request, wherein, carry conversation type in this conversation request;
Wherein, conversation request is caused that by external event conversation type comprises good friend's type, realm type, discussion group's type or interim conversation type etc.For example, for the instant communication software that is used to chat, in the buddy list of the main panel of this instant communication software, the user utilizes mouse etc. to double-click certain good friend's head portrait, and this main panel generates conversation request and carry conversation type in conversation request is good friend's type.Wherein, external event is double-clicked this good friend's head portrait for the user.
Step 202: create motherboard, obtain the script describing of this conversation type correspondence according to the conversation type of carrying in the conversation request, wherein, motherboard comprises interface portion and logical gate;
Wherein, motherboard is a control, can fill other child control in motherboard.In the present embodiment, with interface portion and logical gate in the form realization motherboard of object, interface portion provides the profile of session window, the interface portion of a kind of motherboard as shown in Figure 3 respectively.
Wherein, the technician sets up and stores the script describing of every kind of conversation type correspondence in advance.In script describing, be given for the control name of each child control of filling motherboard in advance, and in motherboard the layout information of each child control.Therefore, script describing comprises two parts content: a part is given for the control name of all child controls of filling motherboard, and another part comprises position, size, gap or base map etc. for the layout information of each child control.Script describing can be XML (Extensible Markup Language, an extend markup language) code, and exists with the form of XML file.The pairing script describing of good friend's type in the instant communication software as follows, the code of this script describing is:
<Control?name=″MainBorad″>
<DockPanel>
<ProfileCtrl?name=″ProfileCtrl″dock=″Top″/>
<ToolbarCtrl?name=″ToolbarCtrl″dock=″Top″/>
<SidebarCtrl?name=″SidebarCtrl″dock=″Right″/>
<PromptCtrl?name=″PromptCtrl″dock=″Top″/>
<BottomCtrl?name=″BottomCtrl″dock=″Bottom″/>
<ChatMsgCtrl?name=″ChatMsgCtrl″dock=″Fill″/>
</DockPanel>
</Control>
The control name of having described six child controls in the above-mentioned script describing is respectively " Profile ", " Toolbar ", " Sidebar ", " Prompt ", " BottomFrame " and " ChatMsg ", and the position of each child control in motherboard is respectively " Top ", " Top ", " Right ", " Top ", " Bottom " and " Fill ".
Wherein, in the present embodiment, the technician can be according to the requirement of different instant communication software products, is provided for filling the layout of child control and each child control of motherboard in script describing, thereby can satisfy the personalized requirement of instant communication software product.
Step 203: by the script describing that obtains being resolved, obtains the control name of all child controls that are used to fill motherboard, and the layout information of each child control;
Wherein, because the basic function of session window is the interface that information interchange is provided for the contact person, therefore, all there is the ChatMsg child control of realizing basic function in the script describing of every kind of conversation type correspondence.
For example, the control name that obtains each child control that is used to fill motherboard in the script describing of the good friend's type correspondence from step 202 is respectively Profile ", " Toolbar ", " Sidebar ", " Prompt ", " BottomFrame " and " ChatMsg ", and the position of each child control in motherboard is respectively " Top ", " Top ", " Right ", " Top ", " Bottom " and " Fill ".
Step 204: each control name according to obtaining, obtain the interface portion of each child control, and utilize the interface portion of each child control to fill motherboard;
Particularly, according to each control name that obtains, the interface portion of searching each child control from the corresponding relation of control name and interface portion according to the layout information of each child control, is filled in the interface portion of each child control in the motherboard.
Wherein, with reference to the order of each child control of describing in the script describing, the interface portion with each child control is filled in the motherboard successively.In addition, each child control comprises interface portion and logical gate, and the data structure with object realizes interface portion and logical gate in the present embodiment.
Wherein, for same control name can corresponding multiple conversation type child control, but the interface portion of each child control is all identical and logical gate is all different.For example, for " Profile " child control, the interface portion of " Profile " child control of good friend's type and " Profile " child control of realm type is all identical and logical gate is different.The technician develops an interface portion and corresponding one or more logical gates of each child control correspondence in advance; And with interface portion and logical gate separate storage.Wherein, the corresponding relation of prior storage control name of technician and interface portion is as shown in table 1, and three's corresponding relation of control name, conversation type and logical gate is as shown in table 2.
Table 1
Control name Interface portion
?Profile The interface portion of Profile
?Sidebar The interface portion of Sidebar
?…… ……
Table 2
Control name Conversation type Logical gate
?Profile Good friend's type The logical gate of the Profile of good friend's type
?Sidebar Good friend's type The logical gate of the Sidebar of good friend's type
?Profile The realm type The logical gate of the Profile of realm type
?…… …… ?……
Wherein, by the interface portion of each child control is filled whole motherboard, make whole motherboard be divided into a plurality of zones, each child control is a zone.
For example, from control name as shown in table 1 and interface portion, obtain the interface portion of " Profile " child control, " Toolbar " child control, " Sidebar " child control, " Prompt " child control, " BottomFrame " child control and " ChatMsg " child control according to control name " Profile ", " Toolbar ", " Sidebar ", " Prompt ", " BottomFrame " and " ChatMsg " respectively; Then with reference to the order of each child control in the script describing,, the interface portion of " Profile " child control is filled in the top of motherboard as shown in Figure 3 at first according to the position " Top " of " Profile " child control; According to the position " Top " of " Toolbar " child control, the interface portion of " Toolbar " child control is filled in the top of the remaining part of motherboard then; According to the position " Right " of " Sidebar " child control, the interface portion of " Sidebar " child control is filled in the right of the remaining part of motherboard again.The interface portion of each child control that will be left respectively by above-mentioned identical method is filled in as shown in Figure 3 the motherboard, and the motherboard after the filling that obtains as shown in Figure 4.Wherein, in motherboard as shown in Figure 4, Profile is an information data area, and Toolbar is knob district, top, and Sidebar is the expansion area, and Prompt is that highlight and ChatMsgCtrl are conversation area.
Step 205: according to each control name that obtains and the conversation type of carrying, obtain the logical gate of each child control, and the logical gate of each child control is bundled on the interface portion of himself;
Particularly, according to each control name that obtains and the conversation type of carrying, from three's corresponding relation of control name, conversation type and logical gate, search the logical gate of each child control, in motherboard, the logical gate of each child control and the interface portion of himself are bound.
For example, according to the control name that obtains " Profile ", from three's corresponding relation of control name as shown in table 2, conversation type and logical gate, search the logical gate of " Profile " child control, in motherboard as shown in Figure 4, the logical gate and the interface portion of " Profile " child control are bound.By above-mentioned identical method the interface portion and the logical gate of each remaining child control are bound.
Wherein, when realizing certain concrete instant communication software product, in order to make the how abundant application of session window carrying, will realize that the plug-in unit of using is loaded on the child control in the motherboard.Wherein, the interface portion of child control can be carried the icon of plug-in unit etc., and the logical gate of child control provides interface function, can carry out alternately with plug-in unit.The interface portion and the logical gate of child control are bound together, and in the time of just can realizing the icon when the plug-in unit of user click interface portion carrying, logical gate and plug-in unit carry out alternately and move plug-in unit.
Step 206: by each child control of registration in motherboard, make each child control can be directly mutual, set up window, and motherboard is placed in the window of foundation, obtain session window with motherboard;
Wherein, the step of each child control of registration is specially in motherboard: for each child control is provided with a pointer, this pointer is used for motherboard and child control carries out alternately in the logical gate of motherboard.In the present embodiment, each child control in the motherboard all is independently of each other, and any two child controls cannot directly carry out alternately.If two child controls need interactive information, then one of them child control elder generation carries out interactive information with the logical gate of motherboard, the logical gate of motherboard calls another child control by pointer, carries out interactive information with another child control again, so finishes this two child control and carries out interactive information.
Wherein, in the present embodiment, each child control all is self-defined control, each child control is all separate and cannot be directly mutual in motherboard, and by each child control is registered in the motherboard, make each child control can be directly and motherboard mutual, and any two child controls are all undertaken by motherboard alternately.
Wherein because control can not show separately, so the child control of filling in motherboard and the motherboard can not show individually, therefore, motherboard must be placed in the window, could show with the form of session window.In addition, in the present embodiment, also can work as and just set up window after receiving conversation request, so, after having registered each child control, directly motherboard is placed in the session window in this step at motherboard.
Step 207: set up the chat channel for this session window, wherein, this session window can provide the interface of information interchange at least for the contact person.
Wherein, set up a Session (session) earlier, the whole session window is sticked among the Session of foundation, set up the chat channel and safeguard the chat channel by Session.In addition, the information interaction between the main panel of also responsible session window of Session and instant communication software.
Further, for instant communication software, owing to can have a plurality of session window simultaneously, the corresponding Session of each session window, for the ease of managing each Session, therefore the Session manager is set and the new Session that will set up is registered in this Session manager.
Further, when the motherboard of session window received certain incident, motherboard was inquired about each child control according to the pointer that is registered in each child control of self, if inquire the child control that to handle this incident, then this incident is met at the child control that inquires and handle.
Further, make if desired to have abundant application in the session window, then plug-in unit can be loaded in the child control in the session window, make the how abundant application of session window carrying.For example, need in session window, carry this application of virtual image of contact person, then in session window, need only the interface portion that contact person's virtual image is loaded into Sidebar, and carry out alternately with the plug-in unit of realizing virtual image by the logical gate of Sidebar.
Wherein, because each child control in the session window is independent mutually and cannot be directly mutual, so plug-in unit in any one child control in the session window and the plug-in unit in other child controls are separate and cannot be directly mutual, any two child controls are undertaken alternately by motherboard, so when needing to change the layout of session window, as long as change the layout of the child control in the session window, and do not need after the change layout interaction code of each plug-in unit in the session window is made amendment, so reduce cost of development; When the session window of certain instant communication software product is upgraded, only need make amendment to the child control at the part place of upgrading, other herid former session window partially, so alleviate new functional development difficulty and reduce cost of development; When developing another session window on the basis of the session window of producing mouth at certain instant communication software, as long as the child control to the part place of revising is made amendment, and other herid former session window partially, so alleviate the new product development difficulty and reduce cost of development.
Wherein, in instant communication software, can create a plurality of session window simultaneously, the conversation type of each session window can be not identical entirely, in the present embodiment, can create a tree for this instant communication software, in this tree, each leaf node is used to identify the session window of establishment; The leaf node that conversation type is all identical has public father node, and this father node is used to identify the affiliated conversation type of these leaf nodes; Each node that is used to identify conversation type has public father node, and this father node is used to identify this instant communication software.Wherein, the data structure of each node in the tree can be interface.
Wherein, in the present embodiment, can carry out transverse cuts to the motherboard of creating, adopt layer mode that motherboard is resolved into presentation layer, logical layer and data communication layer etc., then, by the interface portion that presentation layer carries each child control, the transmitting-receiving of guild's words message that the data communication layer is responsible for and child control is gone forward side by side alternately, logical layer is responsible for presentation layer and data communication layer are coupled together.
In embodiments of the present invention, in script describing, be provided for filling each child control of motherboard, and each child control is filled in the motherboard, motherboard is placed on obtains session window in the window.Because each child control in the session window is separate, the plug-in unit that carries in any two child controls is also separate, when therefore changing the layout of former session window, do not need to revise the interaction code between each plug-in unit, exploitation new session window in former session window, then as long as the child control at the part place of revising is made amendment, and other herid former session window partially, so alleviate development difficulty and reduce cost of development, and make session window have the characteristic of the low coupling of high cohesion.
Implement 3
As shown in Figure 5, the embodiment of the invention provides a kind of method of creating session window, comprising:
Step 301: receive request to create, wherein, carry conversation type in this request to create;
Wherein, conversation request is caused that by external event conversation type comprises good friend's type, realm type, discussion group's type or interim conversation type etc.For example, for the instant communication software that is used to chat, in the buddy list of the main panel of this instant communication software, the user utilizes mouse etc. to double-click certain good friend's head portrait, and this main panel generates conversation request and carry conversation type in conversation request is good friend's type.Wherein, external event is double-clicked this good friend's head portrait for the user.
Step 302: create corresponding motherboard according to the conversation type of carrying in the request to create, and the script describing that obtains this conversation type correspondence;
Wherein, the technician sets up and stores the script describing of every kind of conversation type correspondence in advance.In script describing, be given for the control ID of each child control of filling motherboard in advance, and the layout information of each child control in motherboard.So in the present embodiment, script describing comprises that two parts content is respectively: a part is the control ID of each child control of being used to fill motherboard, and another part comprises position, size, gap or base map etc. for the layout information of each child control.The pairing script describing of good friend's type in the instant communication software as follows, the code of this script describing is:
<Control?name=″MainBorad″>
<DockPanel>
<ProfileCtrl?ID=″ID1″dock=″Top″/>
<ToolbarCtrl?ID=″ID2″dock=″Top″/>
<SidebarCtrl?ID=″ID3″dock=″Right″/>
<PromptCtrl?ID=″ID4″dock=″Top″/>
<BottomCtrl?ID=″ID5″dock=″Bottom″/>
<ChatMsgCtrl?ID=″ID6″dock=″Fill″/>
</DockPanel>
</Control>
The control ID that has described six child controls in the above-mentioned script describing is respectively " ID1 ", " ID2 ", " ID3 ", " ID4 ", " ID5 " and " ID6 ", and the position of each child control in motherboard is respectively " Top ", " Top ", " Right ", " Top ", " Bottom " and " Fill ".In addition, the child control ChatMsg that in script describing, comprises the basic function that realizes session window at least.
Step 303: by the script describing that obtains being resolved, obtains the ID of each child control that is used to fill motherboard, and the layout information of each child control;
For example, the control ID that obtains each child control that is used to fill motherboard in the script describing of the good friend's type correspondence from step 302 is respectively " ID1 ", " ID2 ", " ID3 ", " ID4 ", " ID5 " and " ID6 ", and the position of each child control in motherboard is respectively " Top ", " Top ", " Right ", " Top ", " Bottom " and " Fill ".
Step 304: according to each control ID, obtain the interface portion of each child control, and utilize the interface portion of each child control to fill motherboard;
Particularly, according to each the control ID that obtains, from the corresponding relation of control ID and interface portion, search the interface portion of each child control,, the interface portion of each child control is filled in the interface portion of motherboard according to the layout information of each child control that obtains.
Wherein, each child control comprises interface portion and logical gate, the child control that same control ID can corresponding a plurality of different sessions types, and the interface portion of each child control is all identical and logical gate is different.The technician develops one or more logical gates of interface portion He its correspondence of each child control in advance.In addition, the corresponding relation of the logical gate of prior storage control ID of technician and control is as shown in table 3, and three's corresponding relation of control ID, conversation type and logical gate is as shown in table 4.
Table 3
Control ID Interface portion
ID1 The interface portion of Profile
ID2 The interface portion of Sidebar
…… ……
Table 4
Control ID Conversation type Logical gate
ID1 Good friend's type The logical gate of the Profile of good friend's type
ID2 Good friend's type The logical gate of the Sidebar of good friend's type
ID1 The realm type The logical gate of the Profile of realm type
…… …… ?……
For example, from control ID and interface portion as shown in table 3, obtain the interface portion of the interface portion of " Profile " child control, " Toolbar " child control, " Sidebar " child control, " Prompt " child control, " BottomFrame " child control and " ChatMsg " child control according to control " ID1 ", " ID2 ", " ID3 ", " ID3 ", " ID4 ", " ID5 " and " ID6 " respectively; Then with reference to the order of each child control in the script describing,, the interface portion of " Profile " child control is filled in the top of motherboard as shown in Figure 3 at first according to the position " Top " of " Profile " child control; According to the position " Top " of " Toolbar " child control, the interface portion of " Toolbar " child control is filled in the top of the remaining part of motherboard then; According to the position " Right " of " Sidebar " child control, the interface portion of " Sidebar " child control is filled in the right of the remaining part of motherboard again.The interface portion of each child control that will be left respectively by above-mentioned identical method is filled in as shown in Figure 3 the motherboard, and the motherboard after the filling that obtains as shown in Figure 4.
Step 305: according to each control ID that obtains and the conversation type of carrying, obtain the logical gate of each child control, and each child control logical gate is bundled on the interface portion of himself;
Particularly, according to each control ID that obtains and the conversation type of carrying, from three's corresponding relation of control ID, conversation type and logical gate, search the logical gate of each child control, and in motherboard, the interface portion and the logical gate of each child control are bound.
For example, according to the control ID that obtains is " ID1 ", from three's corresponding relation of control ID, conversation type and logical gate as shown in table 4, search the logical gate of " Profile " child control, in motherboard as shown in Figure 4, the logical gate and the interface portion of " Profile " child control are bound.By above-mentioned identical method the interface portion and the logical gate of each remaining in motherboard child control are bound.
Step 306: by each child control of the registration in motherboard, make each child control carry out setting up window, and motherboard being carried in the window of foundation alternately, obtain session window with motherboard.
Wherein because control can not show separately, so the child control of filling in motherboard and the motherboard can not show individually, therefore, motherboard must be placed in the window, could show with the form of session window.
Step 307: set up the chat channel for this session window, wherein, this session window can provide the interface of information interchange at least for the contact person.
Wherein, because each child control in the session window is independent mutually and cannot be directly mutual, so plug-in unit in any one child control in the session window and the plug-in unit in other child controls are separate and cannot be directly mutual, any two child controls are undertaken by motherboard alternately.
Further, make if desired to have abundant application in the session window, then plug-in unit can be loaded in the child control in the session window, make the how abundant application of session window carrying.
In embodiments of the present invention, in script describing, be provided for filling each child control of motherboard, and each child control is filled in the motherboard, motherboard is placed on obtains session window in the window.Because each child control in the session window is separate, the plug-in unit that carries in any two child controls is also separate, when therefore changing the layout of former session window, do not need to revise the interaction code between each plug-in unit, exploitation new session window in former session window, then as long as the child control at the part place of revising is made amendment, and other herid former session window partially, so alleviate development difficulty and reduce cost of development, and make session window have the characteristic of the low coupling of high cohesion.
Embodiment 4
As shown in Figure 6, the embodiment of the invention provides a kind of device of creating session window, comprising:
Receiver module 401 is used to receive request to create, carries conversation type in this request to create;
Creation module 402, the script describing that is used to create motherboard and obtains the conversation type correspondence of carrying comprises the conversation area child control at least in this script describing;
Packing module 403, each child control that is used for this script describing is described is filled in the motherboard of establishment;
Registering modules 404 is used for making the motherboard of each child control and establishment mutual at each child control of motherboard registration of creating, the motherboard of establishment is sticked on window obtain session window, and set up chat channels for session window.
Wherein, packing module 403 specifically comprises:
First acquiring unit is used for by this script describing is resolved, and obtains the sign of each child control and the layout information of each child control;
Second acquisition unit is used for the sign according to the conversation type of carrying and each child control, obtains the interface portion and the logical gate of each child control;
Filler cells is used for the layout information according to each child control, the interface portion of each child control is filled in the motherboard of establishment, and the interface portion and the logical gate of each child control are bound;
Wherein, second acquisition unit specifically comprises:
First searches subelement, is used for the sign according to each child control, the interface portion of searching each child control from the corresponding relation of sign and interface portion;
Second searches subelement, is used for the sign according to the conversation type of carrying and each child control, searches the logical gate of each child control from the corresponding relation of sign, conversation type and logical gate;
Wherein, child control comprises interface portion and logical gate, and any two child controls are undertaken alternately by the motherboard of creating;
Further, this device also comprises:
Enquiry module is used in session window, if the motherboard of creating receives incident, and each child control in the motherboard that inquiry is created, if inquire the child control that can handle this incident, the child control that then this incident is met at inquiry is handled.
Wherein, in the present embodiment, the sign of child control comprises control name or control ID.
In embodiments of the present invention, in script describing, be provided for filling each child control of motherboard, and each child control is filled in the motherboard, motherboard is placed on obtains session window in the window.Because each child control in the session window is separate, the plug-in unit that carries in any two child controls is also separate, when therefore changing the layout of former session window, do not need to revise the interaction code between each plug-in unit, exploitation new session window in former session window, then as long as the child control at the part place of revising is made amendment, and other herid former session window partially, so alleviate development difficulty and reduce cost of development, and make session window have the characteristic of the low coupling of high cohesion.
All or part of content in the technical scheme that above embodiment provides can realize that its software program is stored in the storage medium that can read by software programming, storage medium for example: the hard disk in the computing machine, CD or floppy disk.
The above only is preferred embodiment of the present invention, and is in order to restriction the present invention, within the spirit and principles in the present invention not all, any modification of being done, is equal to replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (10)

1. a method of creating session window is characterized in that, described method comprises:
Receive request to create, carry conversation type in the described request to create;
The script describing of creating motherboard and obtaining described conversation type correspondence comprises the conversation area child control at least in the described script describing;
Each child control of describing in the described script describing is filled in the described motherboard;
Described each child control of registration makes described each child control and described motherboard mutual in described motherboard, described motherboard is sticked on window obtain session window, and set up chat channels for described session window.
2. the method for claim 1 is characterized in that, described each child control of describing in the described script describing is filled in the described motherboard, specifically comprises:
By described script describing is resolved, obtain the sign of described each child control and the layout information of described each child control;
According to the sign of described conversation type and described each child control, obtain the interface portion and the logical gate of described each child control;
According to the layout information of described each child control, the interface portion of described each child control is filled in the described motherboard, and the interface portion and the logical gate of described each child control are bound.
3. method as claimed in claim 2 is characterized in that, described sign according to described conversation type and described each child control is obtained the interface portion and the logical gate of described each child control, specifically comprises:
According to the sign of described each child control, the interface portion of from the corresponding relation of sign and interface portion, searching described each child control;
According to the sign of described conversation type and described each child control, from the corresponding relation of sign, conversation type and logical gate, search the logical gate of described each child control.
4. as any described method of claim of claim 1-3, it is characterized in that described child control comprises interface portion and logical gate, and any two child controls are undertaken by described motherboard alternately.
5. as any described method of claim of claim 1-3, it is characterized in that described method also comprises:
In described session window, if described motherboard receives incident, inquire about each child control in the described motherboard, if inquire the child control that can handle described incident, the child control that then described incident is met at described inquiry is handled.
6. a device of creating session window is characterized in that, described device comprises:
Receiver module is used to receive request to create, carries conversation type in the described request to create;
Creation module is used to the script describing creating motherboard and obtain described conversation type correspondence, comprises the conversation area child control in the described script describing at least;
Packing module, each child control that is used for described script describing is described is filled in the described motherboard;
Registering modules is used for making described each child control and described motherboard mutual at described each child control of described motherboard registration, described motherboard is sticked on window obtain session window, and set up chat channels for described session window.
7. device as claimed in claim 6 is characterized in that, described packing module specifically comprises:
First acquiring unit is used for obtaining the sign of described each child control and the layout information of described each child control by described script describing is resolved;
Second acquisition unit is used for the sign according to described conversation type and described each child control, obtains the interface portion and the logical gate of described each child control;
Filler cells is used for the layout information according to described each child control, the interface portion of described each child control is filled in the described motherboard, and the interface portion and the logical gate of described each child control are bound.
8. device as claimed in claim 7 is characterized in that, described second acquisition unit specifically comprises:
First searches subelement, is used for the sign according to described each child control, the interface portion of searching described each child control from the corresponding relation of sign and interface portion;
Second searches subelement, is used for the sign according to described conversation type and described each child control, searches the logical gate of described each child control from the corresponding relation of sign, conversation type and logical gate.
9. as any described device of claim of claim 6-8, it is characterized in that described child control comprises interface portion and logical gate, and any two child controls are undertaken by described motherboard alternately.
10. as any described device of claim of claim 6-8, it is characterized in that described device also comprises:
Enquiry module is used in described session window, if described motherboard receives incident, inquires about each child control in the described motherboard, if inquire the child control that can handle described incident, the child control that then described incident is met at described inquiry is handled.
CN201010144498.0A 2010-04-09 2010-04-09 A kind of method and device creating session window Active CN102214090B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201010144498.0A CN102214090B (en) 2010-04-09 2010-04-09 A kind of method and device creating session window

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201010144498.0A CN102214090B (en) 2010-04-09 2010-04-09 A kind of method and device creating session window

Publications (2)

Publication Number Publication Date
CN102214090A true CN102214090A (en) 2011-10-12
CN102214090B CN102214090B (en) 2015-11-25

Family

ID=44745413

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201010144498.0A Active CN102214090B (en) 2010-04-09 2010-04-09 A kind of method and device creating session window

Country Status (1)

Country Link
CN (1) CN102214090B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103428073A (en) * 2012-05-24 2013-12-04 腾讯科技(深圳)有限公司 User interface-based instant messaging method and apparatus
CN104270427A (en) * 2014-09-18 2015-01-07 用友优普信息技术有限公司 Session control method and device
CN104298495A (en) * 2013-07-19 2015-01-21 桥弘数控科技(上海)有限公司 Program development method and system based on scripting language
CN104699363A (en) * 2013-12-10 2015-06-10 阿里巴巴集团控股有限公司 Window interface display method and system
CN111209000A (en) * 2020-01-08 2020-05-29 网易(杭州)网络有限公司 Processing method and device of user-defined control, electronic equipment and storage medium
CN111277615A (en) * 2018-12-04 2020-06-12 阿里巴巴集团控股有限公司 User behavior tracking method based on browser, terminal device and server
CN111726395A (en) * 2020-05-29 2020-09-29 广州奇芯机器人技术有限公司 Automatic communication mechanism of numerical control system

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101127736A (en) * 2007-09-26 2008-02-20 腾讯科技(深圳)有限公司 An instant communication system and method for processing sub-panel
CN101677298A (en) * 2008-09-17 2010-03-24 多友科技(北京)有限公司 Multiparty session implementation method of enterprise instant communication system

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101127736A (en) * 2007-09-26 2008-02-20 腾讯科技(深圳)有限公司 An instant communication system and method for processing sub-panel
CN101677298A (en) * 2008-09-17 2010-03-24 多友科技(北京)有限公司 Multiparty session implementation method of enterprise instant communication system

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
万凯: "大规模软件架构的MVC统一框架的设计与实现", 《中国优秀硕士学位论文全文数据库》 *
左志斌: "安全即时通信系统的改进性研究、设计与实现", 《中国优秀硕士学位论文全文数据库》 *

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103428073B (en) * 2012-05-24 2015-06-17 腾讯科技(深圳)有限公司 User interface-based instant messaging method and apparatus
CN103428073A (en) * 2012-05-24 2013-12-04 腾讯科技(深圳)有限公司 User interface-based instant messaging method and apparatus
CN104298495B (en) * 2013-07-19 2018-07-20 桥弘数控科技(上海)有限公司 A kind of program developing method and system based on script
CN104298495A (en) * 2013-07-19 2015-01-21 桥弘数控科技(上海)有限公司 Program development method and system based on scripting language
CN104699363A (en) * 2013-12-10 2015-06-10 阿里巴巴集团控股有限公司 Window interface display method and system
CN104270427B (en) * 2014-09-18 2018-01-12 用友优普信息技术有限公司 Conversation controlling method and session control device
CN104270427A (en) * 2014-09-18 2015-01-07 用友优普信息技术有限公司 Session control method and device
CN111277615A (en) * 2018-12-04 2020-06-12 阿里巴巴集团控股有限公司 User behavior tracking method based on browser, terminal device and server
CN111277615B (en) * 2018-12-04 2022-01-11 阿里巴巴集团控股有限公司 User behavior tracking method based on browser, terminal device and server
CN111209000A (en) * 2020-01-08 2020-05-29 网易(杭州)网络有限公司 Processing method and device of user-defined control, electronic equipment and storage medium
CN111209000B (en) * 2020-01-08 2024-01-26 网易(杭州)网络有限公司 Processing method and device of custom control, electronic equipment and storage medium
CN111726395A (en) * 2020-05-29 2020-09-29 广州奇芯机器人技术有限公司 Automatic communication mechanism of numerical control system
CN111726395B (en) * 2020-05-29 2023-01-31 广州奇芯机器人技术有限公司 Automatic communication mechanism of numerical control system

Also Published As

Publication number Publication date
CN102214090B (en) 2015-11-25

Similar Documents

Publication Publication Date Title
CN102214090B (en) A kind of method and device creating session window
US7496890B2 (en) Generation of configuration instructions using an abstraction technique
CN102081662B (en) Method and apparatus for modifying process control data
US7594181B2 (en) Prototyping graphical user interfaces
US7017118B1 (en) Method and apparatus for reordering data items
US10109027B1 (en) Database access and community electronic medical records system
CN101493825B (en) GIS middleware collocation and management method
CN110310088A (en) Workflow configuration method and Related product
CN108462746A (en) A kind of container dispositions method and framework based on openstack
JP2006510133A (en) Modeling system for graphic user interface to cross-reference with related applications
CN101923434B (en) Type setting method and system of application icon and mobile terminal
CN104008441A (en) Task management system and method for automatically submitting files into version library
CN112232047A (en) Method, system, equipment and medium for multi-dimensional data acquisition and automatic summarization
CN106843871B (en) A kind of design system and design method of domain model frame
CN108388623A (en) ER relationships generation method, device, computer equipment and storage medium
EP3196783A1 (en) Open collaboration board with multiple integrated services
CN109445841A (en) Interface document management method, device, server and storage medium
CN103970546A (en) Method and system for expandable modular information management based on user&#39;s customization
CN105243237A (en) Assembly technology structure tree and building method thereof
US10964416B1 (en) Block chain management
CN108388576B (en) Method and system for interactively generating map
CN110889013A (en) Data association method, device, server and storage medium based on XML
CN101685395A (en) Object property processing method of product data management system
CN104462631A (en) Circuit diagram generating device and circuit diagram generating method
CN102868746A (en) Method for realizing mobile informationization

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant