Embodiment
When the download link downloaded resources that download address or user according to user's input click, in order to generate the download address that other are associated according to the download address of input or the download link corresponding download address of click, and then be that user's download is to more resources according to these download address, the embodiment of the invention provides a kind of multiaddress generation method, in this method, determine the variable part in the initial download address and obtain the attribute information of this variable part, attribute information according to initial download address and variable part generates one or more other download address, thereby can utilize other download address downloaded resources of initial download address and generation.
Referring to Fig. 1, the multiaddress generation method that the embodiment of the invention provides specifically may further comprise the steps:
Step 10: obtain first download address, i.e. the initial download address;
In this step, obtain first download address method can for: when the user carried out resource downloading, in client input download address, client received the download address of user's input, and with this download address as first download address.
Obtain first download address method can also for: when the user carries out resource downloading, click certain download link, client responds, with the pairing download address of this download link as first download address.
Step 11: determine the variable part in first download address, obtain the attribute information of this variable part correspondence;
In this step, variable part in first download address can be set by the user, setting the concrete grammar of determining the variable part in first download address according to the user is: the user is selected by mouse in client, directly mode such as input is set the variable part in first download address, client responds, and the part that the user is selected is as the variable part in first download address; Perhaps, client receives the variable information of user's input, searches described variable in first download address, with the variable that finds as the variable part in first download address.For example, first download address is:
Ftp: //dygod1:dygod1@data226.dygod.com:9911/ escape from prison the 3rd the season/[film paradise www.dygod.com] the 3rd season EP (the *) _ S-Files.rmvb that escapes from prison;
" * " in can mouse selected this address of user, then client according to user selected with the part in this address bracket as variable part; Perhaps, the user directly at client input " * ", finds " * " in the bracket of client in this address, then with the part in the bracket as variable part.
Variable part in first download address can also be determined according to certain rule by client, client determines that according to certain rule the concrete grammar of the variable part in first download address is: client is according to default characteristics of variables, discern one or more variablees in first download address according to predetermined recognition rule, with the variable that identifies as the variable part in first download address.Characteristics of variables can be numeral, additional character (for example bracket) etc.Illustrate, pre-defined rule is: discern last interval variable in first download address, characteristics of variables is continuous numeral, according to this pre-defined rule and characteristics of variables, the continuous numeral of identification in client last interval in first download address, with the numerical portion that the recognizes variable part as first download address, for example, first download address is:
Http: // 61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE01.wmv, in the end the continuous numeral that identifies among interval/AVSE01.wmv is 01, then with the variable part of " 01 " in last interval of address part as this address.Illustrate again, pre-defined rule is: discern last interval and third from the bottom interval variable in first download address, characteristics of variables is continuous numeral, according to this pre-defined rule and characteristics of variables, client is discerned continuous numeral in interval and third from the bottom the interval of last in first download address respectively, with the numerical portion that the recognizes variable part as first download address, for example, first download address is:
Http: // 61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE01.wmvIn the end the continuous numeral that identifies among interval/AVSE01.wmv is 01, the continuous numeral that identifies at third from the bottom interval/disk01/ is 01, then with last of address " 01 " in interval and third from the bottom interval partly as the variable part of this address.
Preferable, after client is discerned variable in first download address,, can also point out the user that the variable that identifies is confirmed or select, and the variable that the user is selected is as the variable part in first download address in order to better meet user's request.
Behind the variable part in determining first download address, need obtain the attribute information of this variable part correspondence, concrete acquisition methods can be by the user attribute information of variable part to be provided with, with the information of user's input of the receiving attribute information as the variable part correspondence.The attribute information of variable part correspondence can comprise: one or combination in any in the initial value of long, the variable part in position of variable part, the stop value of variable part.Can determine the span of this variable part according to the attribute information of variable part correspondence, such as, the position of variable part is long to be 2, and the initial value of variable part is 01, and the span of variable part is [01,99] so; For another example, the position of variable part is long to be 2, and the stop value of variable part is 25, and the span of variable part is [01,25] so.The attribute information of variable part correspondence can also be all values of variable part, such as, the attribute information of variable part is: 01,02,03,04,05, can determine directly that so the span of variable part is value in 01,02,03,04,05.
Obtain the variable part correspondence attribute information concrete grammar can also for: the attribute that will comprise first download address request of obtaining sends to server end, server end receives after this attribute obtains request, according to the download address of preserving in advance and the corresponding relation of variable's attribute information, determine that attribute obtains the variable's attribute information of the first download address correspondence that comprises in the request, and this variable's attribute information is sent to client.Server end can send to client with whole variable's attribute information of the first download address correspondence, also the Partial Variable attribute information can be sent to client, server end determine to send whole variable's attribute information or the method for Partial Variable attribute information can for: server end judges the attribute that receives obtains whether comprise variable levels information in the request, if comprise, then judge it is to send whole variable's attribute information or Partial Variable attribute information according to variable levels information; If do not comprise, that then can give tacit consent to sends to client with whole variable's attribute information.Obtain when comprising variable levels information in the request at attribute, server end is chosen the variable's attribute information of corresponding level according to this variable levels information from the variable's attribute information of the first download address correspondence, and the variable's attribute information of choosing is sent to client.For example, first download address is:
Http: // 61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE01.wmvThe attribute that client sends obtains and comprises this address and variable levels information in the request: first rank, server end receives after attribute obtains request, determine that according to the corresponding relation of preserving the variable's attribute information of this address correspondence comprises: the variable's attribute information of other variable's attribute information: 01-30 of the first order and second level: 1-3, because the variable levels information that comprises in the variable's attribute request is first rank, then server end sends to client with other variable's attribute information of first order 01-30.
Step 12: the attribute information according to first download address and the variable part correspondence that gets access to generates at least one other download address.
The concrete grammar of this step is: at first, determine the span of this variable part according to the attribute information of variable part correspondence; Then, the variable part in first download address is substituted with the value in the span, will substitute the download address of back generation as other download address.For example, first download address is:
Http: // 61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE01.wmvVariable part is last interval " 01 " and third from the bottom interval " 01 ", the attribute information of " 01 " part in last interval that gets access to comprises: initial value is 01, stop value is 02, the attribute information of third from the bottom interval " 01 " part comprises: initial value is 01, and stop value is 02; Can determine that according to these attribute informations " 01 " span partly is [01 in last interval and third from the bottom interval, 02], " 01 " in last interval and third from the bottom interval in this address is partly substituted with the value in the span, generates following 4 other download address:
http://61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE01.wmv,
http://61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE02.wmv,
http://61.152.221.166/tbcwmv/A13/disk02/mpegav/AVSE01.wmv,
http://61.152.221.166/tbcwmv/A13/disk02/mpegav/AVSE02.wmv。
After generating at least one other download address, client is set up downloading task for each other download address that generates, each downloading task according to self corresponding download address from the server end downloaded resources.
Referring to Fig. 2, the embodiment of the invention also provides a kind of multiaddress generation system, and this system comprises:
Client 20, be used to obtain first download address, determine the variable part in described first download address, obtain the attribute information of described variable part correspondence from server, according to described first download address and attribute information, generate at least one other download address;
Server 21 is used to preserve the attribute information of the variable part correspondence of described first download address, and this attribute information is offered described client.
As shown in Figure 3, client 20 comprises address acquisition unit 30, variable determining unit 31, attribute acquiring unit 32 and scalar/vector 33, wherein:
Address acquisition unit 30 is used to obtain first download address;
Variable determining unit 31 is used for determining the variable part of described first download address;
Attribute acquiring unit 32 is used for obtaining from server the attribute information of described variable part correspondence;
Scalar/vector 33 is used for generating at least one other download address according to described first download address and attribute information.
Concrete, address acquisition unit 30 comprises first acquiring unit and second acquisition unit, wherein:
First acquiring unit is used to receive the download address of user's input, with described download address as described first download address;
Second acquisition unit is used to obtain the pairing download address of download link that the user clicks, with this download address as described first download address.
Variable determining unit 31 comprises first determining unit and second determining unit, wherein:
First determining unit is used to receive the variable information of user's input, searches described variable in described first download address, with the variable that finds as the variable part in described first download address;
Second determining unit is used for discerning the variable in described first download address according to default characteristics of variables, with the variable that identifies as the variable part in described first download address.
Variable determining unit 31 also comprises Tip element, is used for after described second determining unit is discerned the variable of described first download address, and the prompting user selects the variable that identifies; Described second determining unit is used for: the variable that user that will identify and described selects is as the variable part of described first download address.
Attribute acquiring unit 32 comprises the 3rd acquiring unit and the 4th acquiring unit, wherein:
The 3rd acquiring unit is used for sending the attribute that comprises described first download address to server end and obtains request; Receive the variable's attribute information that described server end returns, from described variable's attribute information, choose the attribute information of described variable part correspondence;
The 4th acquiring unit is used to point out the user that the attribute information of described variable part correspondence is provided with, and the information that receives user's input is also with the attribute information of this information as described variable part correspondence.
Scalar/vector 33 comprises scope determining unit and variable substituting unit, wherein:
The scope determining unit is used for determining according to the attribute information of described variable part correspondence the span of described variable part;
The variable substituting unit is used for the variable part of described first download address is substituted with the value in the described span, will substitute the download address of back generation as described other download address.
Client 20 further comprises:
Resource downloading unit 34 is used for carrying out resource downloading according to other download address of first download address and scalar/vector generation.
As shown in Figure 4, server 21 specifically comprises:
Information memory cell 40 is used to preserve the corresponding relation of download address and variable's attribute information;
Attribute determining unit 41 is used to receive the attribute that comprises download address that client sends and obtains request, according to described corresponding relation, determines the variable's attribute information of described download address correspondence;
Attribute transmitting element 42 is used for all or part of content of described variable's attribute information is sent to client.
Below in conjunction with said system method embodiment of the present invention is described:
Embodiment one:
In the present embodiment, imported the initial download address and the variable part of this address is set and the attribute information of this variable part correspondence by the user, client generates a plurality of other addresses according to the attribute information of initial download address and variable part correspondence.Be implemented as follows:
Step S01: the user imports following initial download address and variable information " * " in client:
Ftp: //dygod1:dygod1@data226.dygod.com:9911/ escape from prison the 3rd the season/[film paradise www.dygod.com] the 3rd season EP (the *) _ S-Files.rmvb that escapes from prison;
The address acquisition unit of client receives the initial download address of user's input, and the variable determining unit receives variable information;
Step S02: the attribute information of the attribute acquiring unit prompting user inputted variable correspondence of client, and the reception user imports position long 1 and initial value 5;
Step S03: the scalar/vector of client is according to the attribute information of variable part " * ": the position is long be 1 and initial value be 5, the span of determining " * " part in the initial download address is [5,9], with " * " in the initial download address part with [5,9] numeral in substitutes, and generates 5 " * " part and is respectively 5,6,7,8,9 new download address;
Step S04: downloading task is set up for each download address in the resource downloading unit of client, and carries out resource downloading according to these download address.
Embodiment two:
In the present embodiment, determine variable part in the chained address that the user clicks by client according to the recognition rule of setting and characteristics of variables, obtain the attribute information of variable part correspondence from server end, and generate a plurality of other addresses according to chained address and attribute information.Be implemented as follows:
Step S11: the user clicks following chained address in client:
http://61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE01.wmv;
Step S12: the variable determining unit of client is according to recognition rule of setting (last interval and third from the bottom interval variable in the identification download address) and characteristics of variables (continuous numeral), and discerning " 01 " among last interval/AVSE01.wmv and " 01 " among third from the bottom interval/disk01/ is variable part;
Step S13: the attribute acquiring unit of client sends the attribute that comprises above-mentioned chained address to server and obtains request;
Step S14: the attribute determining unit of server receives above-mentioned attribute and obtains request, according to the download address of information memory cell preservation and the corresponding relation of variable's attribute information, the variable's attribute information of determining above-mentioned chained address correspondence comprises: the variable's attribute information (01-03) of other variable's attribute information (01-03) of the first order and second level, and whole variable's attribute information that the transmitting element of server will be determined send to client;
Step S15: the variable's attribute information that the attribute acquiring unit reception server of client is sent, the prompting user selects the variable's attribute information of other variable's attribute information of the first order and second level, suppose that the user has selected other variable's attribute information of the first order, then the attribute acquiring unit is with the attribute information of other variable's attribute information (01-03) of the first order as " 01 " part correspondence among last interval/AVSE01.wmv in the chained address;
Step S16: the scalar/vector of client determines in the chained address that span of " 01 " part among last interval/AVSE01.wmv is [01,03], " 01 " described in chained address part is substituted with 02 and 03 respectively, generates 2 new " 01 " and partly be respectively 02 and 03 download address:
http://61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE02.wmv,
http://61.152.221.166/tbcwmv/A13/disk01/mpegav/AVSE03.wmv;
Step S17: downloading task is set up for each download address in the resource downloading unit of client, and carries out resource downloading according to these download address.