An interface parameter verification method and component

A technology of interface parameters and verification methods, applied in the field of interface verification, can solve problems such as low-efficiency interfaces cannot be applied, third-party components cannot be satisfied, and verification performance is not good.

Active Publication Date: 2017-07-28
SHENZHEN BINCENT TECH
View PDF2 Cites 22 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] For many scenarios, these third-party components cannot meet our needs, such as parameter dependencies, etc.
They all simply provide the format of the verification parameter field, and these verifiers 2020 are stateful, r

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • An interface parameter verification method and component
  • An interface parameter verification method and component

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0036] see Figure 1 to Figure 2 ,

[0037] figure 1 It is an execution flowchart of an interface parameter verification method of the present invention;

[0038] figure 2 It is a schematic diagram of an overall model of an interface parameter verification method of the present invention.

[0039] The present invention discloses a method for verifying interface parameters, which provides a client 10, a verifier 20 and a server 30. The verifier 20 includes an annotation analysis module 21, an annotation verification module 22, and a verification rule generation module 23. The interface parameter verification method comprises the following steps: the client 10 requests an interface of the server, the client customizes the parameters through the client 10, and the annotation analysis module 21 analyzes the parameters and parses the result data Send to the verification rule generation module 23, the verification rule generation module 23 generates a comparison rule of a self-...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention provides an interface parameter verification method and component. The method comprises the steps that a client defines parameters via a client end; an annotation analyzing module analyzes the parameters and sends analysis result data to a verification rule generating module; the verification rule generating module generates self-defined reference data type comparison rules according to the analysis result data; an annotation verification module searches for an attribute corresponding to each attribute of the comparison rules generated by the verification rule generating module in parameter objects and compares attribute values via the self-defined comparison rules; if no corresponding attribute is found or the corresponding attribute values are different, verification fails; otherwise, verification is successful. The interface parameter verification method can perform diversified implementation on frameworks based on multiple formats such as annotation, json, and xml, better support great dependency of parameters and support complex parameter types.

Description

technical field [0001] The invention relates to the technical field of interface inspection, in particular to an interface parameter inspection method and components. Background technique [0002] As we all know, as long as there is an interface, there will be parameters, but there will be parameter verification. For the business interface, the business code should be clear at a glance, with only business-related logical ideas, and there should not be a large number of if-ifs to verify parameters or data itself or some other processing, in order to enhance the readability of the code , Maintainability, the verification processing of interface parameters is very important. [0003] At present, many popular open source frameworks have their own parameter verification mechanism, such as struts2, spring mvc Validator mechanism, hibernate-validator, commons-validator, etc.; [0004] For many scenarios, these third-party components cannot meet our needs, such as parameter depend...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G06F11/22H04B17/00
CPCG06F11/221G06F11/2215H04B17/00
Inventor 龚杰王国彬张华杰李辉
Owner SHENZHEN BINCENT TECH
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products