Summary of the invention
Technical problems to be solved in this application are to provide a kind of software development methodology and device, in order to solve the technical matters that in existing software project development process, cost of development is high, the construction cycle is long.
The application provides a kind of software development methodology, is applied to Software Development Platform, and described Software Development Platform is provided with the functional mode masterplate that can set up functional mode, and described method comprises:
Obtain configuration file, described configuration file comprises that title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, the page data source of target developing project are related to configuration information, toolbar configuration information and external resource configuration information;
In described Software Development Platform, set up the functional mode corresponding with described configuration file;
Wherein, described functional mode comprises header entry, page layout's item, service logic item, data manipulation district item, page data source relational term, toolbar item and external resource item;
Move described functional mode, generate the target developing project corresponding with the business scenario of describing in described configuration file.
Said method, preferred, describedly in described Software Development Platform, set up the functional mode corresponding with described configuration file, comprising:
In described Software Development Platform, set up a functional mode object corresponding with the file name of described configuration file;
According to the service logic configuration information item in described configuration file, the service logic that will load and call in described functional mode object is set and realizes class title;
According to page layout's configuration information in described configuration file, page layout's class and the style structure class title that in described functional mode object, will load and call be set, and according to described toolbar configuration information, tool bar and the button structure class title that in described functional mode object, will load and call be set;
Be related to configuration information and external resource configuration information according to data manipulation district configuration information, page data source in described configuration file, set gradually data manipulation district item, page data source relational term and external resource item in described functional mode object.
Said method, preferably, set up the functional mode corresponding with described configuration file in described Software Development Platform after, at the described functional mode of described operation, before generating the target developing project corresponding with the business scenario of describing in described configuration file, described method also comprises:
The Software Development Platform that is stored in default server is loaded on to Application Middleware.
Said method, preferred, described the Software Development Platform that is stored in default server is loaded in Application Middleware, comprising:
Reception project call request, described project call request comprises the functional mode parameter of the target developing project in described Software Development Platform;
According to described functional mode parameter, read the functional mode object of described target developing project, carry out its service logic method by its inner service logic class of described functional mode object reference;
According to the result of calling of described service logic class, start the default masterplate page in Application Middleware;
Call the page constructor corresponding with page layout's item in described functional mode object and realize class, realize class by described page constructor and call the data block structure class corresponding with each block in described data manipulation district;
Move described data block structure class, call attribute control structure class according to the display module of each block in described data manipulation district, generate the displaying contents of described target developing project, described displaying contents is back to the described masterplate page and shows.
Said method, preferred, described configuration file is realized with expandable mark language XML Standard compilation.
The application also provides a kind of software development apparatus, is applied to Software Development Platform, and described Software Development Platform is provided with the functional mode masterplate that can set up functional mode, and described device comprises:
File acquisition unit, be used for obtaining configuration file, described configuration file comprises that title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, the page data source of target developing project are related to configuration information, toolbar configuration information and external resource configuration information;
Model is set up unit, for setting up the functional mode corresponding with described configuration file at described Software Development Platform;
Wherein, described functional mode comprises header entry, page layout's item, service logic item, data manipulation district item, page data source relational term, toolbar item and external resource item;
Project build unit, for moving described functional mode, generates the target developing project corresponding with the business scenario of describing in described configuration file.
Said apparatus, preferred, described model is set up unit and is comprised:
Model initialization subelement, for setting up a functional mode object corresponding with the file name of described configuration file at described Software Development Platform;
Logic configuration subelement, for according to the service logic configuration information item of described configuration file, arranges the service logic that will load and call in described functional mode object and realizes class title;
Page configuration subelement, for according to described configuration file page layout configuration information, arranges page layout's class and the style structure class title that in functional mode object, will load and call; , and according to described toolbar configuration information, tool bar and the button structure class title that in functional mode object, will load and call be set;
Data configuration subelement, for being related to configuration information and external resource configuration information according to described configuration file data manipulation district configuration information, page data source, set gradually data manipulation district item, page data source relational term and external resource item in described functional mode object.
Said apparatus, preferred, also comprise:
Platform loads unit, for setting up at described model after unit sets up described functional mode, before described project build unit generates described target developing project, is loaded on Application Middleware by the Software Development Platform that is stored in default server.
Said apparatus, preferred, described platform loads unit comprises:
Request receiving subelement, for receiving project call request, described project call request comprises the functional mode parameter of the target developing project in described Software Development Platform;
Object loads subelement, for according to described functional mode parameter, reads the functional mode object of described target developing project, carries out its service logic method by its inner service logic class of described functional mode object reference;
Page promoter unit, for the result of calling according to described service logic class, starts the default masterplate page in Application Middleware;
Structure class is called subelement, realizes class for calling the page constructor corresponding with described functional mode object page layout item, realizes class call the data block structure class corresponding with each block in described data manipulation district by described page constructor;
Content displaying subelement, be used for moving described data block structure class, call attribute control structure class according to the display module of each block in described data manipulation district, generate the displaying contents of described target developing project, described displaying contents is back to the described masterplate page and shows.
Said apparatus, preferred, described configuration file is realized with expandable mark language XML Standard compilation.
From such scheme, a kind of software development methodology and device that the application provides, be applied to Software Development Platform, this Software Development Platform is provided with the functional mode masterplate that can set up functional mode, after the application has write configuration file by developer, obtain configuration file, the included every configuration information of this configuration file is described out the business scenario of the target developing project of developer's needs, as title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, page data source is related to configuration information, toolbar configuration information and external resource configuration information, after getting this configuration file, in described Software Development Platform, set up the functional mode corresponding with described configuration file, move this functional mode, generate the target developing project corresponding with the business scenario of describing in described configuration file.The application is in the process that realizes project development, developer only need grasp the work of writing of configuration file, and obviously will be lower than needing developer skillfully to grasp the learning cost of the application and development technical ability of multiple technologies framework in prior art for the learning cost of the work of writing of file, more without specific architect, technological frame is designed, simultaneously, it is the project corresponding with the desired business scenario of user that the application develops the project obtaining, directly be satisfied with user's request, carry out design iterations without the business scenario about project again, therefore, the application has not only reduced the cost of labor of project development, also save to a certain extent the flow process of software project development, shorten the construction cycle of project.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present application, the technical scheme in the embodiment of the present application is clearly and completely described, obviously, described embodiment is only some embodiments of the present application, instead of whole embodiment.Based on the embodiment in the application, those of ordinary skill in the art are not making the every other embodiment obtaining under creative work prerequisite, all belong to the scope of the application's protection.
There is the features such as business function point is many, demand is changeable, the project cycle is short, development task is tight for the development project of customization, in software project development process, project development team is general all realizes the project development with the large task amount of large demand by shortening project development cycle, the modes such as project human cost or application technology framework that increase, wherein:
Shorten the project development cycle for project development team, the mode of generally working overtime by developer realizes, but developer works overtime and conventionally can cause the Efficiency Decreasing of project development, also can affect quality and the effect of project;
Increase project human cost can make the overall cost of project development increase, and has reduced the profit margin of project, can increase the handling cost of project simultaneously;
Above-mentioned shortening project development cycle and increase project human cost cannot improve the efficiency of project development in itself, at present in exploitation during for the software project of customization, general data development teams can adopt the technological frame of some comparative maturities or framework to reduce project implementation cost, for example, adopt struts, spring, the technological frames such as hibernate, by overall technology framework according to MVC(Model View Controller, model view controller) thought carry out technology and realize layering, thereby reach every layer architecture relatively independent of development project, and call by the mode of interface between layers, reach and do not rely on realization, improve the flexible expansion mechanism of each layer.
Adopt the technological frames such as struts, spring, hibernate, no doubt can solve the technical need of customization project, still, their introducing can bring new problem:
Developer in Items in order team study and grasp the application and development technical ability of the technological frames such as struts, spring, hibernate, makes the learning cost of project development higher or project development personnel's technical ability is had relatively high expectations;
Need to need a specific architect, complete the global design to technological frame, provide a set of complete project technology to realize solution;
In the time all reaching for above-mentioned 2, architect or project are opened personnel, except client's functional requirement of concern project self, also need attention location system login authentication, System right management, system security management and also round the content of the links such as installation, issue and deployment;
After project completes, developer also needs the development of considering design item how in the similar scene of sundry item, to be applied.
Therefore,, for how solving above-mentioned various technical matters, the developer of Items in order team finds and both can meet customer need and can also solve the application problem of business scenario.
The application has adopted the thought of " business model is for driving ", the destination object of exploitation using business model as management software, carry out the design, structure of infosystem, integrated, issue, maintenance and management, carry out the establishment of business model by Software Development Platform, rely on page masterplate, the technology of finishing service scene realizes, and wherein, the model in described Software Development Platform comprises:
Data model: from the angle of data, target developing project is described, for all data of storing, safeguard and processing being relevant to target developing project, these data are ties of each functional unit of contact;
Functional mode: whole target developing project is described as visual angle taking functional activity, the relation between each of functional mode in target developing project is showed;
Organize models: for describing organization structure tree, team, ability, Role and privilege etc.
Described Software Development Platform is with numerous dynamic models such as data model, functional mode and organize models, cover project management and related object and the key element of business, business object and the business scenario of dynamic construction target developing project, thereby design and build the target developing project of customization from the mode of model system, as shown in fig. 1, submit an expense account the exemplary plot of each model in software project for invoice.
In this application, developer is without the application and development technical ability of grasping multiple technologies framework, more without specific architect, technological frame is designed, only need the work of writing of the configuration file of grasping functional mode, simultaneously, it is the project corresponding with the desired business scenario of user that the application develops the project obtaining, directly be satisfied with user's request, carry out design iterations without the business scenario about project again, therefore, the application has not only reduced the cost of labor of project development, also save to a certain extent the flow process of software project development, shorten the construction cycle of project.
With reference to figure 2, the process flow diagram of a kind of software development methodology embodiment mono-providing for the application, described method is applied to Software Development Platform, is provided with the functional mode masterplate that can set up functional mode in described Software Development Platform, and described method can comprise the following steps:
Step 201: obtain configuration file;
Wherein, described configuration file comprises that title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, the page data source of target developing project are related to configuration information, toolbar configuration information and external resource configuration information.
In the embodiment of the present application, the business function exploitation of developer in project team is mainly centered around writing in work of described configuration file, be related to configuration information, toolbar configuration information and external resource configuration information by the title configuration information in described configuration file, page layout's configuration information, service logic configuration information, data manipulation district configuration information, page data source, carry out page data, displaying style, page operation and the service logic of the business scenario of establishing target development project.
It should be noted that, in the functional mode masterplate of described Software Development Platform, be preset with the realization of acquiescence, comprise and show style, page operation and service logic, developer can build the functional mode corresponding to project of meeting customer need by calling the realization of these acquiescences, in the time that the realization of acquiescence cannot meet client's demand, the flexible expansion login mechanism that developer can provide by described Software Development Platform, self-definition design functional mode, write configuration file, meet client's individual demand.
As shown in Figure 3, described Software Development Platform is divided on Technical Architecture: display layer, key-course, Business Logic, Data Persistence Layer, model layer and system layer, wherein:
Display layer: for structure and the demonstration of web page, comprise JSP template page, Tag Libray, JS tool storage room etc.;
Key-course: be responsible for the request of the front end page, the instruction of safety check and analysis request, and commission business logic class is processed front end request, the request of response front end;
Business Logic: the core business logic module of platform, is divided into page verification, CURD basic logic, ajaxHttp logic and complementary logic etc.;
Data Persistence Layer: realize management and storage to data, Business Logic is by storage or the access of the complete paired data of Data Persistence Layer;
Model layer: the shoring of foundation of supporting business scene operation, be responsible for definition and parsing to various models in platform;
System layer: Business Logic or key-course are provided to the support of system-level or application layer.
Wherein, described model layer has mainly comprised functional mode, data model, code model:
Data model: for defining the base attribute of all business objects, corresponding entity is exactly tables of data, by data modeling tool configuring maintenance.
Functional mode: for defining information source, the business process rule of business function, be the metadata that realizes basic business event, by Functional Design device configuring maintenance.
Code model: code model indicated object attribute with the relation between object, for example, has individual sex attribute in certain object, represents malely with 1,0 represents female.
Step 202: set up the functional mode corresponding with described configuration file in described Software Development Platform;
Wherein, described functional mode comprises header entry, page layout's item, service logic item, data manipulation district item, page data source relational term, toolbar item and external resource item.
It should be noted that, described step 202 is specifically realized by following mode:
Be related to configuration information, toolbar configuration information and external resource configuration information according to title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, page data source in described configuration file, in described Software Development Platform, set up the functional mode corresponding with described configuration file.
The functional mode masterplate inside arranging in described Software Development Platform, include multiple configuration items, as title configuration item, page layout's style configuration item, service logic configuration item, data manipulation district configuration item, page data source is related to configuration item, toolbar configuration item, external resource configuration item, get the configuration file of described target developing project in described step 201 after, described step 202 is according to described configuration file, in described Software Development Platform, set up the functional mode corresponding with described configuration file, each in the functional mode of setting up is corresponding with corresponding entry in the functional mode masterplate in described Software Development Platform.
The technology of described functional mode masterplate realizes and comprises functional mode XML configuration, functional mode XML configuration is the specific descriptions of the ingredient of the functional mode to setting up according to described functional mode masterplate, is below specific implementation example every in described functional mode masterplate:
1, title configuration item: <Title Style=" CSS pattern " > title </Title>
2, page layout's style configuration item:
<Type> functional mode loads resolves type </Type>
<Display?Style="none(default)|Detail|MultiTab|View"
PageStyle=" page CSS pattern " IncludeStyle=" js file is introduced the registration bean name of structure class "
PromptStyle=" page is reminded the registration bean name of frame structure class " LinkAlign=" TOP|BOTTOM|LEFT "/>
3, service logic configuration item:
<Model Jsp=" redirected JSP page path " > service logic class </Model>
4, data manipulation district configuration item:
<FunctionObject?Name="input,update,summary,view,search">
<Tables>
<Table Name=" data model title " Style=" specifies this function pages show style "
Main=" whether being master meter " FilterSQL=" data model filtercondition "
Description=" description of table model " Main=" whether being master meter " Order=" tagmeme " >
--field information in data model-->
<Field FieldName=" field name in data model "
HtmlCtrl=" text|combo|date etc. " Width=" width "
Height=" highly " Min=" minimum value " Max=" maximal value "
DefaultValue=" default value " DisplayName=" control display Name "
Type=" field type; For example: string "
CodeType=" code model title "
Alignment="left|center|right"
Length=" length " CheckValue=" arranges the check the value of control "
Empty="true|false"/>
</Table></Tables>
</FunctionObject>
5, page data source is related to configuration item:
<Relation>
The title </MasterTable> of <MasterTable> master meter data model
<DetailTable> is from the title </DetailTable> of table data model
<MasterField> major key field </MasterField>
<DetailField> foreign key field </DetailField></ Relation>
6, toolbar configuration item:
<Toolbar Function=" summary|input|update|view " Title=" function pages display Name " Prompt=" " >
<Command Event=" button event, search|summary|add etc. "
Description=" button page display Name " Name=" " Enabled=" true|false "/>
</Toolbar>
7, external resource configuration item
<JS>javascript code block </JS>
<Resource Style=" css pattern " Function=" " ></Resource>
Step 203: move described functional mode, generate the target developing project corresponding with the business scenario of describing in described configuration file.
By finding out in such scheme, a kind of software development methodology embodiment mono-that the application provides, be applied to the Software Development Platform that is provided with functional mode masterplate, after having write configuration file by developer, obtain configuration file, the included every configuration information of this configuration file is described out the business scenario of the target developing project of developer's needs, as title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, page data source is related to configuration information, toolbar configuration information and external resource configuration information, after getting this configuration file, in described Software Development Platform, set up the functional mode corresponding with described configuration file, move this functional mode, generate the target developing project corresponding with the business scenario of describing in described configuration file.The embodiment of the present application is in the process that realizes project development, developer only need grasp the work of writing of configuration file, and obviously will be lower than needing developer skillfully to grasp the learning cost of the application and development technical ability of multiple technologies framework in prior art for the learning cost of the work of writing of file, more without specific architect, technological frame is designed, simultaneously, it is the project corresponding with the desired business scenario of user that the application develops the project obtaining, directly be satisfied with user's request, carry out design iterations without the business scenario about project again, therefore, the embodiment of the present application has not only reduced the cost of labor of project development, also save to a certain extent the flow process of software project development, shorten the construction cycle of project.
With reference to figure 4, the part process flow diagram of a kind of software development methodology embodiment bis-providing for the application, wherein, while setting up the functional mode corresponding with described configuration file in described step 202 in described Software Development Platform, can realize in the following manner:
Step 401: set up a functional mode object corresponding with the file name of described configuration file in described Software Development Platform.
As shown in Figure 5, be the register interface exemplary plot in described Software Development Platform in actual applications.In Fig. 5, the login name of the functional mode of registration is corresponding with described title configuration information.
Step 402: according to the service logic configuration information item in described configuration file, the service logic that will load and call in described functional mode object is set and realizes class title.
Step 403: according to page layout's configuration information in described configuration file, page layout's class and the style structure class title that in functional mode object, will load and call be set, and according to described toolbar configuration information, tool bar and the button structure class title that in functional mode object, will load and call be set.
Step 404: be related to configuration information and external resource configuration information according to data manipulation district configuration information, page data source in described configuration file, set gradually data manipulation district item, page data source relational term and external resource item in described functional mode object.
It should be noted that, after described step 401 is complete, can carry out described step 402 to described step 404 simultaneously, realize the foundation of described functional mode object.
Wherein, described functional mode object is the functional mode in described step 202.
Wherein, described title configuration information is corresponding with the header entry in described functional mode, shows the name information of described target developing project;
Described service logic configuration information is corresponding with the service logic item in described functional mode, in described functional mode, by described service logic configuration item, Action layer is loaded automatically, and calls corresponding service logic specific implementation class;
Described page layout configuration information is corresponding with the page layout's item in described functional mode, in described page layout configuration information, has specified page layout, style to construct the register name of class, realizes page acquiescence or personalized page layout or style;
Described toolbar configuration information is corresponding with the toolbar item in described functional mode, has defined the toolbar information showing in page masterplate, the button definition explanation that comprises tool bar inside;
Described data manipulation district configuration information is corresponding with the data manipulation district item in described functional mode, comprises the definition to page data show area, and for example, conventional list, form etc. shown the definition of element, comprises list, the inner corresponding attribute item of form;
Described page data source is related to that configuration information is corresponding with the page data source relational term in described functional mode, comprises the contextual definition between data model;
Described external resource configuration information is corresponding with the external resource item in described functional mode, comprises the definition to external resource or quotes.
With reference to figure 6, the process flow diagram of a kind of software development methodology embodiment tri-providing for the application, after described step 202, before described step 203, described method can also comprise the following steps:
Step S204: the Software Development Platform that is stored in default server is loaded on to Application Middleware.
Before the described target developing project of meeting customer need generates, conventionally can there is the Software Development Platform of the functional mode of described target developing project to be stored in default server foundation, when client applies described target developing project at needs, first the Software Development Platform of the functional mode with target developing project is loaded in Application Middleware, as web application, in described Application Middleware, move again the functional mode of described target developing project, generate the target developing project corresponding with the business scenario of describing in described configuration file, client is provided to the service of response.
In the specific implementation of the embodiment of the present application, the Software Development Platform of the functional mode with described target developing project need to be loaded in a certain Application Middleware, move this functional mode and build the described target developing project that obtains, therefore, with reference to figure 7, for the part process flow diagram of the embodiment of the present application, described step S204 can realize by following each step:
Step 701: receive project call request, described project call request comprises the functional mode parameter of the target developing project in described Software Development Platform.
Before described step 701 is carried out, client logs in described default server, trigger the calling program of described Software Development Platform, generation project call request, now, the embodiment of the present application receives the project call request of the described functional mode parameter that includes the target developing project in described Software Development Platform.For example, in the time of actual realization, send a HTTP by client and ask server, according to the configuration information in configuration file struts-congfig.xml, receive this HTTP by concrete action class and ask.
Step 702: according to described functional mode parameter, read the functional mode object in described target developing project, carry out its service logic method by its inner service logic class of described functional mode object reference.
Wherein, described functional mode parameter comprises title and the action mark of functional mode.For example, action class is according to the title of functional mode and action mark, value-added tax function model object, calls concrete service logic class by functional mode object according to the service logic register name of internal registration, and carries out its service logic method according to described action mark.Wherein, the business datum that described service logic class obtains the described service logic method of execution leaves in request class according to certain naming rule, and returning to actionerrors object, described business datum and described actionerrors object are as the result of calling of described service logic class.
Step 703: according to the result of calling of described service logic class, start the default masterplate page in Application Middleware.
For example, obtain the result of calling of described service logic class in action class, as described in business datum and as described in after actionerrors object, according to the configuration information in struts-congfig.xml, jump in the Jsp masterplate page in described application centre.
Wherein, above-mentioned steps 701 to described step 703 is that described target developing project was described in the view preparatory stage being loaded in Application Middleware, to the point of penetration example case study of this view preparatory stage as shown in Figure 8, and wherein:
1, user sends parameter to structs controller by the page URL request of access item in browser, as functional mode title, action mark;
2, value-added tax function model object;
3, call service logic by the model management module in described functional mode and realize class;
4, carry out service logic method;
5, return to business datum set pair and resemble the controller to structs;
6, returning to business datum set pair resembles to Application Middleware as the web page starting in web browser.
Step 704: call the page constructor corresponding with page layout's item in described functional mode object and realize class, realize class by described page constructor and call the data block structure class corresponding with each block in described data manipulation district.
In actual applications, after starting the described Jsp masterplate page, the Jsp masterplate page starts to call concrete Tag tag processor, described Tag tag processor calls corresponding page constructor and realizes class, generate display styles and the pattern of full page, be triggered while calling in described page constitution realization class, can call the constitution realization class of block described in each, i.e. described data block structure class.
Step 705: move described data block structure class, call attribute control structure class according to the display module of each block in described data manipulation district, generate the displaying contents of described target developing project, described displaying contents is back to the described masterplate page and shows.
In actual applications, while calling described data block structure class, by the display module of the concrete block of described data block structure class basis, call attribute space structure class, complete the structure of the smallest subset page, and structure class at different levels (constructor) encapsulates the display element of all subset pages, generate the complete HTML content of the page, return to the described Jsp masterplate page, described HTML content is shown in the described Jsp masterplate page.
Described step 704 is that described target developing project was described in the view shows stage being loaded in Application Middleware with described step 705, to the point of penetration example case study in this view shows stage as shown in Figure 9, and wherein:
1, the concrete Tag tag processor of described Jsp page invocation;
2, described Tag tag processor calls corresponding page constitution realization class, i.e. invoking page constructor;
3, in described page constitution realization class, calling data piece structure class, i.e. data block constructor;
4, carry out described data block structure class, call attribute space structure class;
5, the subset page that returns to the output of described attribute space structure class is to described data block structure class;
6, described data block structure class is carried out all subset pages assembled, generates the complete Html content of the page;
7, return to described Html content to Tag tag processor;
8, returning to described web page shows.
In the time of actual realization of each embodiment of above-mentioned the application, described configuration file is realized with expandable mark language XML Standard compilation.
It should be noted that, the entirety definition of business scenario when functional mode in the embodiment of the present application, client being participated in, the definition that has comprised business operation object, running time and different page flows, a part in each page flow corresponding function model is processed description, comprises title, deal with data, bandwagon effect, service logic and quotes and the running time.
Be below from each aspect realization mechanism of the Technical Architecture of described Software Development Platform, the software development methodology that gives functional mode to the application becomes fast the implementation of technology and sets forth, wherein, by the database being arranged in described Software Development Platform, the data processing in project development process is provided support:
As shown in figure 10, presentation layer in described Software Development Platform is responsible for the encapsulation that the page is shown logic, is mainly made up of JSP template, Tag label, UI pattern, JS instrument class libraries, page constructor, page constructor, auxiliary construction device, data field constructor and control constructor.
JSP template: be the JSP page, according to business demand, the HTML fragment that constructors at different levels are generated encapsulates combination, and encloses the public JSP statement of the page, and page style script;
Tag label: be the encapsulation to rear end Java constructor; According to dissimilar constructor, Tag label is classified; It is mainly quoted by JSP template, by the appointment of tag parameter, completes calling of particular configuration device;
UI pattern: be exactly to modify one group of parameter of a certain class paragraph, comprising as font type, font size, font style, alignment thereof etc., specific paragraph format title of called after.Conventionally, this title is called to pattern;
JS instrument class libraries: JS instrument class libraries is mainly responsible for the attribute data verification of the front end page, provides the event handling default function of some controls, and the loading of the data of control and displaying control tool function etc.;
Page constructor: complete the page except before JSP template, the structure of top level page layout, pattern and introducing; And responsible calling data field constructor, auxiliary construction device;
Auxiliary construction device; Mainly complete some public page elements structures, for example: the page structure of system exception, operation are reminded, and the structure of other external resources etc.;
Data field constructor: complete the page elements structure of data field, the such as structure of the page elements such as list, form; And responsible calling control constructor;
Control constructor: be the structure of page elements minimal set, for example: control.
As shown in figure 11, key-course in described Software Development Platform is responsible for catching of front end request, and request is processed, final feedback request result, has mainly comprised the modules such as request access, protocol conversion, business invoking upon mapping, request response, safety certification, log recording, Authority Verification and localization process:
Request access: handling procedure receives from the HTTP Post of Web server or Get request, and retrieves correlation parameter from request;
Protocol conversion: according to different request types, and required parameter, convert required parameter or request object that Business Logic can be identified to;
Business invoking upon mapping: mapping request realizes class, complete call to the service logic of specifying;
Request response: obtain the result of service logic class, and the protocol conversion of agreement returns to the front end page or page request;
Safety certification: comprised system user certification, IP Address access control etc.;
Log recording: mainly comprise system user login daily record, and the record of the error message of system exception or business verification etc.;
Authority Verification: comprised functional mode authority checking, data recording level Authority Verification and the control of authority of data field level etc.;
Localization process: by the mode of local description document, realize localization process.
As shown in figure 12, the Business Logic in described Software Development Platform is responsible for providing all kinds of services to key-course, completes practical operation or response to page request, and forms operating result, returns to key-course.It has mainly comprised service logic, auxiliary logic, code logic and check logic four parts:
Service logic: mainly for a certain class modes of traffic operation, and realized general logical method;
Auxiliary logic: the various requests mainly for XmlHttp have realized general logical method;
Code logic: mainly for the code model of various array configurations, and the general logical method realizing;
Check logic: mainly for page data legitimacy, and the aspect such as model authority legitimacy has realized logical method.
As shown in figure 13, the system layer of described Software Development Platform, for Business Logic or key-course provide the help of system-level or application layer, has mainly comprised the modules such as application initializes, model buffer memory, model management and empowerment management:
Application initializes: be responsible for when system loads the reading and buffer memory of system environment variable;
Model buffer memory: be responsible for the loading to all configuration files and buffer memory under non-debugging mode, and provide uniform services and call for service logic;
Model management: for all kinds of model files, provide acquiescence to load or operation-interface;
Empowerment management: the Valuation Standard interface of the subscriber authorisation that definition frame is required or model mandate, and provide acquiescence to realize.
With reference to Figure 14, it shows the structural representation of a kind of software development apparatus embodiment tetra-that the application provides, described application of installation is in Software Development Platform, described Software Development Platform is provided with the functional mode masterplate that can set up functional mode, and described device comprises:
File acquisition unit 1401, for obtaining configuration file;
Wherein, described configuration file comprises that title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, the page data source of target developing project are related to configuration information, toolbar configuration information and external resource configuration information.
In the embodiment of the present application, the business function exploitation of developer in project team is mainly centered around writing in work of described configuration file, be related to configuration information, toolbar configuration information and external resource configuration information by the title configuration information in described configuration file, page layout's configuration information, service logic configuration information, data manipulation district configuration information, page data source, carry out page data, displaying style, page operation and the service logic of the business scenario of establishing target development project.
It should be noted that, the Technical Architecture of described Software Development Platform by presentation layer, key-course, Business Logic, Data Persistence Layer and, model layer and system layer, the explanation of above-mentioned each aspect realization mechanism be please refer to the application's embodiment of the method, be again not described in detail.
Model is set up unit 1402, for setting up the functional mode corresponding with described configuration file at described Software Development Platform;
Wherein, described functional mode comprises header entry, page layout's item, service logic item, data manipulation district item, page data source relational term, toolbar item and external resource item.
It should be noted that, described model is set up unit 1402 and specifically can be realized by following mode:
Be related to configuration information, toolbar configuration information and external resource configuration information according to title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, page data source in described configuration file, in described Software Development Platform, set up the functional mode corresponding with described configuration file.
It should be noted that, described model is set up unit 1402 and is connected with described file acquisition unit 1401.
Project build unit 1403, for moving described functional mode, generates the target developing project corresponding with the business scenario of describing in described configuration file.
It should be noted that, described project build unit 1403 is set up unit 1402 with described model and is connected.
By finding out in such scheme, a kind of software development apparatus embodiment tetra-that the application provides, be applied to the Software Development Platform that is provided with functional mode masterplate, after having write configuration file by developer, obtain configuration file, the included every configuration information of this configuration file is described out the business scenario of the target developing project of developer's needs, as title configuration information, page layout's configuration information, service logic configuration information, data manipulation district configuration information, page data source is related to configuration information, toolbar configuration information and external resource configuration information, after getting this configuration file, in described Software Development Platform, set up the functional mode corresponding with described configuration file, move this functional mode, generate the target developing project corresponding with the business scenario of describing in described configuration file.The embodiment of the present application is in the process that realizes project development, developer only need grasp the work of writing of configuration file, and obviously will be lower than needing developer skillfully to grasp the learning cost of the application and development technical ability of multiple technologies framework in prior art for the learning cost of the work of writing of file, more without specific architect, technological frame is designed, simultaneously, it is the project corresponding with the desired business scenario of user that the application develops the project obtaining, directly be satisfied with user's request, carry out design iterations without the business scenario about project again, therefore, the embodiment of the present application has not only reduced the cost of labor of project development, also save to a certain extent the flow process of software project development, shorten the construction cycle of project.
With reference to Figure 15, it shows the part-structure schematic diagram of a kind of software development apparatus embodiment five that the application provides, and wherein, described model is set up unit 1402 and comprised:
Model initialization subelement 1421, for setting up a functional mode object corresponding with the file name of described configuration file at described Software Development Platform.
As shown in Figure 5, be the register interface exemplary plot in described Software Development Platform in actual applications.In Fig. 5, the login name of the functional mode of registration is corresponding with described title configuration information.
Logic configuration subelement 1422, for according to the service logic configuration information item of described configuration file, arranges the service logic that will load and call in described functional mode object and realizes class title.
It should be noted that, described logic configuration subelement 1422 is connected with described model initialization subelement 1421.
Page configuration subelement 1423, for according to described configuration file page layout configuration information, arranges page layout's class and the style structure class title that in functional mode object, will load and call; , and according to described toolbar configuration information, tool bar and the button structure class title that in functional mode object, will load and call be set.
It should be noted that, described page configuration subelement 1423 is connected with described model initialization subelement 1421.
Data configuration subelement 1424, for being related to configuration information and external resource configuration information according to described configuration file data manipulation district configuration information, page data source, set gradually data manipulation district item, page data source relational term and external resource item in described functional mode object.
It should be noted that, described data configuration subelement 1424 is connected with described model initialization subelement 1421.
It should be noted that, after described model initialization subelement 1421 has moved, described logic configuration subelement 1422, described page configuration subelement 1423 and described data configuration subelement 1424 can move simultaneously, can also, with a certain default order operation, finally obtain described functional mode.
With reference to Figure 16, the structural representation of a kind of software development apparatus embodiment six providing for the application, wherein, described device also comprises:
Platform loads unit 1404, for setting up at described model after unit 1402 sets up described functional mode, before described project build unit 1403 generates described target developing project, the Software Development Platform that is stored in default server is loaded on to Application Middleware.
It should be noted that, described platform loads unit 1404 is set up unit 1402 with described model respectively and is connected with described project build unit 1403.
Before the described target developing project of meeting customer need generates, conventionally can there is the Software Development Platform of the functional mode of described target developing project to be stored in default server foundation, when client applies described target developing project at needs, first the Software Development Platform of the functional mode with target developing project is loaded in Application Middleware, as web application, in described Application Middleware, move again the functional mode of described target developing project, generate the target developing project corresponding with the business scenario of describing in described configuration file, client is provided to the service of response.
With reference to Figure 17, be the part-structure schematic diagram of the embodiment of the present application six, described platform loads unit 1404 comprises:
Request receiving subelement 1441, for receiving project call request, described project call request comprises the functional mode parameter of the target developing project in described Software Development Platform.
Before described request receives subelement 1441 operations, client logs in described default server, trigger the calling program of described Software Development Platform, generation project call request, now, the embodiment of the present application receives the project call request of the described functional mode parameter that includes the target developing project in described Software Development Platform.For example, in the time of actual realization, send a HTTP by client and ask server, according to the configuration information in configuration file struts-congfig.xml, receive this HTTP by concrete action class and ask.
Object loads subelement 1442, for according to described functional mode parameter, reads the functional mode object in described target developing project, carries out its service logic method by its inner service logic class of described functional mode object reference.
It should be noted that, described object loads subelement 1442 and is connected with described request reception subelement 1441.
Wherein, described functional mode parameter comprises title and the action mark of functional mode.For example, action class is according to the title of functional mode and action mark, value-added tax function model object, calls concrete service logic class by functional mode object according to the service logic register name of internal registration, and carries out its service logic method according to described action mark.Wherein, the business datum that described service logic class obtains the described service logic method of execution leaves in request class according to certain naming rule, and returning to actionerrors object, described business datum and described actionerrors object are as the result of calling of described service logic class.
Page promoter unit 1443, for the result of calling according to described service logic class, starts the default masterplate page in Application Middleware.
It should be noted that, described page promoter unit 1443 loads subelement 1442 with described object and is connected.
For example, obtain the result of calling of described service logic class in action class, as described in business datum and as described in after actionerrors object, according to the configuration information in struts-congfig.xml, jump in the Jsp masterplate page in described application centre.
Wherein, above-mentioned request receiving subelement 1441 to described page promoter unit 1443 is that described target developing project was described in the view preparatory stage being loaded in Application Middleware, to the point of penetration example case study of this view preparatory stage as shown in Figure 8.
Structure class is called subelement 1444, realize class for calling the page constructor corresponding with described functional mode object page layout item, realize class by described page constructor and call the data block structure class corresponding with each block in described data manipulation district.
It should be noted that, described structure class is called subelement 1444 and is connected with described page promoter unit 1443.
In actual applications, after starting the described Jsp masterplate page, the Jsp masterplate page starts to call concrete Tag tag processor, described Tag tag processor calls corresponding page constructor and realizes class, generate display styles and the pattern of full page, be triggered while calling in described page constitution realization class, can call the constitution realization class of block described in each, i.e. described data block structure class.
Content displaying subelement 1445, be used for moving described data block structure class, call attribute control structure class according to the display module of each block in described data manipulation district, generate the displaying contents of described target developing project, described displaying contents is back to the described masterplate page and shows.
It should be noted that, described content displaying subelement 1445 calls subelement 1444 with described structure class and is connected.
In actual applications, while calling described data block structure class, by the display module of the concrete block of described data block structure class basis, call attribute space structure class, complete the structure of the smallest subset page, and structure class at different levels (constructor) encapsulates the display element of all subset pages, generate the complete HTML content of the page, return to the described Jsp masterplate page, described HTML content is shown in the described Jsp masterplate page.
Wherein, it is that described target developing project was described in the view shows stage being loaded in Application Middleware with described content displaying subelement 1445 that described structure class is called subelement 1444, to the point of penetration example case study in this view shows stage as shown in Figure 9.
In the time of actual realization of each embodiment of above-mentioned the application, described configuration file is realized with expandable mark language XML Standard compilation.
It should be noted that, the entirety definition of business scenario when functional mode in the embodiment of the present application, client being participated in, the definition that has comprised business operation object, running time and different page flows, a part in each page flow corresponding function model is processed description, comprises title, deal with data, bandwagon effect, service logic and quotes and the running time.
Described Software Development Platform adopts XTHML standard to realize technology as the basis of described functional mode, thereby the flexible configuration of business scenario function is provided.By multiple items in described functional mode, as header entry, service logic item, page layout's item, data manipulation district item, page data source relational term, toolbar and external resource item, be mainly divided into service logic definition, page operation definition, page data definition, show style definition and page flow definition.Wherein, above-mentioned various definition please refer to the application's embodiment of the method content, again no longer elaborate.
It should be noted that, each embodiment in this instructions all adopts the mode of going forward one by one to describe, and what each embodiment stressed is and the difference of other embodiment, between each embodiment identical similar part mutually referring to.
Finally, also it should be noted that, in this article, relational terms such as the first and second grades is only used for an entity or operation to separate with another entity or operational zone, and not necessarily requires or imply and between these entities or operation, have the relation of any this reality or sequentially.And, term " comprises ", " comprising " or its any other variant are intended to contain comprising of nonexcludability, thereby the process, method, article or the equipment that make to comprise a series of key elements not only comprise those key elements, but also comprise other key elements of clearly not listing, or be also included as the intrinsic key element of this process, method, article or equipment.The in the situation that of more restrictions not, the key element being limited by statement " comprising ... ", and be not precluded within process, method, article or the equipment that comprises described key element and also have other identical element.
Above a kind of software development methodology provided by the present invention and device are described in detail, applied specific case herein principle of the present invention and embodiment are set forth, the explanation of above embodiment is just for helping to understand method of the present invention and core concept thereof; , for one of ordinary skill in the art, according to thought of the present invention, all will change in specific embodiments and applications, in sum, this description should not be construed as the restriction to the application meanwhile.