WO2020168751A1 - 基于HashMap的数据获取方法、装置、计算机设备和存储介质 - Google Patents

基于HashMap的数据获取方法、装置、计算机设备和存储介质 Download PDF

Info

Publication number
WO2020168751A1
WO2020168751A1 PCT/CN2019/117488 CN2019117488W WO2020168751A1 WO 2020168751 A1 WO2020168751 A1 WO 2020168751A1 CN 2019117488 W CN2019117488 W CN 2019117488W WO 2020168751 A1 WO2020168751 A1 WO 2020168751A1
Authority
WO
WIPO (PCT)
Prior art keywords
content
public
acquisition method
acquired
acquisition
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.)
Ceased
Application number
PCT/CN2019/117488
Other languages
English (en)
French (fr)
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.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An 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 Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Publication of WO2020168751A1 publication Critical patent/WO2020168751A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/22Indexing; Data structures therefor; Storage structures
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Definitions

  • This application relates to the field of testing, and in particular to HashMap-based data acquisition methods, devices, computer equipment and storage media.
  • HashMap is a collection used to store Key-Value key-value pairs. Each key-value pair is also called Entry. Key-value pairs (Entry) are scattered and stored in an array. Array is the backbone of HashMap.
  • HashMap For HashMap, we most often use two methods, Get or Put.
  • the Get method is to find Value based on Key.
  • the input Key will be Hash mapped first. Due to hash conflicts, multiple results may be matched at the same position. Therefore, it is necessary to find the next node along the head node of the corresponding linked list. Therefore, because the traditional collection is stored in the HashMap collection in a key-value relationship, there will be complex nesting.
  • each layer needs to obtain the key, it is necessary to make a non-empty judgment for each layer. Otherwise, there may be errors.
  • the inventor found that the above-mentioned problems increase the development logic and reduce the operating efficiency.
  • a data acquisition method based on a HashMap collection includes: determining a public acquisition method, the public acquisition method being a static class of a public method; determining the name of the content to be acquired and the content The tag of the content is used to uniquely correspond to the content that needs to be acquired; the name of the content that needs to be acquired and the tag of the content are added to the determined public acquisition method; the acquisition instruction is sent to the database, the The acquisition instruction includes a public acquisition method that adds the name of the content to be acquired and a mark of the content to acquire the value of the corresponding content through the public acquisition method; and acquires the data fed back by the database according to the public acquisition method , The data is data corresponding to the content to be obtained.
  • a data acquisition device comprising: a determining unit for determining a public acquisition method, the public acquisition method being a static class of a public method; the determining unit further uses To determine the name of the content to be obtained and the mark of the content, the mark of the content is used to uniquely correspond to the content that needs to be obtained; the processing unit is used to add the name of the content to be obtained and the mark of the content To the determined public acquisition method; a sending unit, configured to send an acquisition instruction to the database, the acquisition instruction including the public acquisition method that adds the name of the content to be acquired and the content mark to pass the public The value of the corresponding content is acquired by the acquisition method; the acquisition unit is configured to acquire the data fed back by the database according to the public acquisition method, and the data is data corresponding to the content to be acquired.
  • a computer device including a memory and a processor
  • the memory stores computer-readable instructions
  • the processor executes The following steps:
  • the public acquisition method is the static class of the public method; determine the content and mark that needs to be acquired, and the mark that needs to be acquired is the identification of the content that needs to be acquired, and the identification is used to uniquely correspond to the content that needs to be acquired Add the content and mark that need to be acquired to the determined public acquisition method; send an acquisition instruction to the database, the acquisition instruction including the public acquisition method that adds the content that needs to be called and the mark, to pass the Get the value of the corresponding content in the public access method.
  • a non-volatile readable storage medium storing computer readable instructions, which when executed by one or more processors, cause one or more processors to execute Steps of the data acquisition method based on HashMap collection.
  • This application provides a data acquisition method, device, computer equipment and storage medium based on a HashMap set.
  • the public acquisition method is sent to the database .
  • Figure 1 is an implementation environment diagram of a data acquisition method based on HashMap set provided in an embodiment
  • Figure 2 is a schematic diagram of the internal structure of a computer device in an embodiment
  • Figure 3 is a data acquisition method based on HashMap implemented in this application.
  • Figure 4 is a data acquisition device in an embodiment of the application.
  • first, second, etc. used in this application can be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from another element.
  • first gesture test script can be referred to as the second gesture test script
  • second gesture test script can be referred to as the second gesture test. script.
  • FIG. 1 is an implementation environment diagram of a data acquisition method based on HashMap set provided in an embodiment.
  • the implementation environment includes a computer device 110 and a database device 120.
  • the computer device 110 is a user device, such as a computer device used by a person, and the corresponding code processing software is installed on the computer device 110.
  • the database device 120 includes a corresponding database, and the database includes storing corresponding data.
  • the tester can issue a corresponding acquisition request on the computer device 110, and the request carries the content and indication of the data to be acquired.
  • the computer device 110 receives the request, it obtains the data corresponding to the content and the label stored in the database device 120 according to the content and the label.
  • the database device also feeds back corresponding data according to the instruction of the data acquisition request.
  • the computer device 110 and the user equipment 120 may be connected through Bluetooth, USB (Universal Serial Bus, Universal Serial Bus) or other communication connection methods, which is not limited in this application.
  • Figure 2 is a schematic diagram of the internal structure of a computer device in an embodiment.
  • the computer device includes a processor, a non-volatile storage medium, a memory, and a network interface connected through a system bus.
  • the non-volatile storage medium of the computer device stores an operating system, a database, and computer-readable instructions.
  • the database may store control information sequences.
  • the processor can realize a A data acquisition method based on HashMap.
  • the processor of the computer equipment is used to provide calculation and control capabilities, and supports the operation of the entire computer equipment.
  • a computer readable instruction may be stored in the memory of the computer device, and when the computer readable instruction is executed by the processor, the processor may execute a data acquisition method based on HashMap.
  • a data acquisition method based on HashMap can be specifically shown in Figure 3 below.
  • the network interface of the computer device is used to connect and communicate with the terminal.
  • FIG. 2 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied.
  • the specific computer device may Including more or fewer parts than shown in the figure, or combining some parts, or having a different arrangement of parts.
  • Figure 3 is a data acquisition method based on HashMap implemented in this application. As shown in FIG. 3, in one embodiment, a data acquisition method based on HashMap is proposed.
  • the data acquisition method can be applied to the above-mentioned computer device 110, and specifically may include the following steps:
  • Step 302 Determine a public acquisition method, which is a static class of a public method; in this embodiment, the static class (static method) is a prior art, which is not limited in this application.
  • Step 304 Determine the content to be acquired and the mark, where the mark to be acquired is an identifier of the content to be acquired, and the identifier is used to uniquely correspond to the content to be acquired;
  • each key-value pair further includes a corresponding tag.
  • determining the content to be called in the embodiment of the present application includes determining the format of the content to be acquired.
  • the user sends a fetch instruction to the database before fetching the data in the HashMap collection.
  • the obtaining instruction is used to instruct the database to obtain the structure of the data included in the HashMap set.
  • the database returns the data structure in the HashMap set included in the database according to the acquisition instruction.
  • sending the acquisition instruction to the database is only a specific implementation of this application. Used to know the format of the data that needs to be obtained for many reasons. For example, when the structure of the data to be acquired has been determined, the user can also directly add the determined content and identifier to the public acquisition method. For example, the structure of the MAP to be called is manually spliced by the user.
  • the value of the key-value object (a collection) may also contain another child key-value object. For example, the value of the first key-value object k1, k1 is the first set, and a second key-value object K2 is nested in the first set.
  • K2 is the second set, and the second set is also embedded Set a third key value object K3, and the value of K3 is the third set.
  • K3 is the third set.
  • the HashMap collection of the database includes the key-value pair K1, the value of K1 includes K2 nested in K1, and the value of K2 includes K3 nested in K2.
  • the format of the content that needs to be obtained is K1; when the format of the content that needs to be obtained is the value of K2, the format of the content that needs to be obtained is K1.K2; when the value of K3 needs to be obtained
  • the format of the content to be obtained is K1.K2.K3.
  • the content that needs to be obtained above is only an example of this application and cannot be used to limit this application.
  • the format of the content to be obtained is K1, K2, K3.
  • Step 306 Add the content and mark that need to be acquired to the determined public acquisition method
  • the public acquisition method includes adding content to be acquired and marked locations. In this way, the public acquisition method searches for the corresponding data through the added content and tags that need to be acquired. The public acquisition method reaches the corresponding content by adding the content and tags that need to be acquired, and determines whether the arrived content is the content that needs to be acquired.
  • Step 308 Send an acquisition instruction to the database.
  • the acquisition instruction includes a public acquisition method that adds the content to be called and a mark to acquire the value of the corresponding content through the public acquisition method; the user is determining the public acquisition method, After you need to find the content and mark, it will send the fetch instruction to the database.
  • Step 310 Obtain data fed back by the database according to the public acquisition method, where the data is data corresponding to the content to be acquired.
  • the database will determine the corresponding content to be searched according to the acquisition instruction. After determining the content to be searched, the database will also judge the content to be obtained through the mark included in the obtaining instruction to determine whether the content needs to be obtained. When the content is what needs to be obtained, the database will return the value of the content.
  • the database before the database returns the value of the content, it also includes converting a character string corresponding to the value of the content from an object format to a string format.
  • converting a character string corresponding to the value of the content from an object format to a string format By converting the format of the acquired data from the object format to the string format, it is avoided that when the acquired data in the object format is directly returned and the feedback data is empty, the problem of an abnormal error report is forced to occur.
  • the conversion of the string corresponding to the value of the key from the object format to the string format can be implemented on the database side or on the calculator side.
  • the application does not limit the data conversion method.
  • it also includes a method of converting the value of the key (content) into the corresponding string from the object format to the string format.
  • the method of converting the value of the key to the corresponding string from the object format to the string format is the prior art, and the content of this method is not limited in this application.
  • Method 2 is a standard type conversion, which converts the object into a String type value.
  • the data type that needs to be converted must be convertible to the String type. Therefore, before the conversion, the method can also include instanceof type checking to determine whether the conversion is possible, otherwise it is prone to Class Cast Exception. In addition, the syntax check will not report an error when the object defined as Object type is converted into String, which may lead to potential errors.
  • null value can be cast to any java class type, (String)null is also legal.
  • the format conversion method of this application can adopt method 3.
  • object is null
  • value of String.value Of(object) is the string "null” instead of null.
  • the database when the database does not find the corresponding value according to the content and the mark, or the database passes the mark verification on the value determined according to the content, it will also determine whether the current value includes a nested value. If the value includes nested content, the database continues to execute the public acquisition method in the nested content, and judges whether the tag of the value of the nested content corresponds to the tag of the content to be acquired.
  • the content that needs to be acquired is value3, and the content acquired in the public acquisition method is K1.k2.
  • the public acquisition method enters K2
  • the public acquisition method determines whether the value of K2 is nested with lower level content. If the value of K2 is nested with a lower level of content (K3), it is determined whether K3 is the content to be searched. To determine whether K3 is the content that needs to be searched can be determined based on the above content, which is not repeated here in this application.
  • K3 is the content to be found, it is determined whether the tag of the content to be obtained corresponds to the tag of K3 value.
  • the tag of the content to be obtained corresponds to the tag of the value of K3
  • the content to be obtained is determined when determining the value of K3. If the content to be obtained is not K3, or the mark of the content to be obtained does not match the mark of K3, the database continues to determine whether there is nesting in the value of K3. Continue to execute the above content until you find value3 or traverse the nested values under K2.
  • the object object with no value is directly returned.
  • This application returns an empty string to avoid errors when using objects with empty content without logical judgment or verification. It is guaranteed to return an empty string for processing whether it is a wrong key or no value. So that the main logic of the business code will become simpler.
  • the HashMap collection of the database includes the key-value pair K1, the value of K1 includes K2 nested in K1, and the value of K2 includes K3 nested in K2.
  • the format of the content that needs to be obtained is K1; when the format of the content that needs to be obtained is the value of K2, the format of the content that needs to be obtained is K1.K2; when the value of K3 needs to be obtained
  • the format of the content to be obtained is K1.K2.K3.
  • K1 Need to get the value of K1 in the above example. Give the content and mark of K1 to the public calling method. This public calling method finds the corresponding collection based on the content and the mark. And get the data included in the collection. Among them, the data included in the set includes sets K2 and K3.
  • the found value is returned.
  • the found value also includes converting the corresponding string found from the object format to the string format.
  • the data acquisition device includes: a determining unit, a processing unit, and a sending unit.
  • the determining unit is used to determine a public acquisition method, and the public acquisition method is a static class of a public method.
  • the determining unit is also used to determine the name of the content to be acquired and the tag of the content, and the tag of the content is used to uniquely correspond to the content to be acquired.
  • the processing unit is configured to add the name of the content to be acquired and the mark of the content to the determined public acquisition mode.
  • the sending unit is configured to send an acquisition instruction to the database, the acquisition instruction including a public acquisition method in which the name of the content to be acquired and a mark of the content are added, so as to acquire the value of the corresponding content through the public acquisition method.
  • the obtaining unit is configured to obtain data fed back by the database according to the public obtaining method, and the data is data corresponding to the content to be obtained.
  • the processing unit is further configured to convert the obtained character string into a string format.
  • the data acquisition device of the present application further includes a conversion unit through which the obtained character string is converted into a string format.
  • the public acquisition method is also used to instruct the database to return an empty string when the value corresponding to the name of the content and the tag of the content is not acquired according to the public acquisition method,
  • the type of the hole character string is string format.
  • the determining unit determining the public acquisition method includes: determining the type of content that needs to be acquired; and determining the public acquisition method according to the type of content that needs to be acquired.
  • the determining unit before determining the name of the content to be acquired and the content tag, the determining unit further includes sending a content acquisition instruction to an interface terminal to acquire the structure of the content included in the database.
  • the data acquisition device can perform any step in the method shown in FIG. 3.
  • each unit of the above data acquisition device is only a division of logical functions, and may be fully or partially integrated into one physical entity in actual implementation, or may be physically separated.
  • these units can all be implemented in the form of software invocation through processing elements; they can also be implemented in the form of hardware; part of the units can also be implemented in the form of software invocation through processing elements, and some of the units can be implemented in the form of hardware.
  • the determining unit may be a separately established processing element, or it may be integrated in a certain chip of the base station for implementation.
  • it may also be stored in the memory of the base station in the form of a program, which is called and executed by a certain processing element of the base station. The function of a control unit.
  • the receiving unit can communicate with the terminal through a radio frequency device and an antenna.
  • the base station can receive information sent by the terminal through the antenna, and the received information is processed by the radio frequency device and sent to the receiving unit.
  • the units of the communication device can be fully or partially integrated together, or can be implemented independently.
  • the processing element described here may be an integrated circuit with signal processing capability. In the implementation process, each step of the above method or each of the above units can be completed by an integrated logic circuit of hardware in the processor element or instructions in the form of software.
  • the above units may be one or more integrated circuits configured to implement the above methods, such as: one or more application specific integrated circuits (ASIC), or one or more microprocessors (digital singnalprocessor, DSP), or, one or more Field Programmable Gate Array (Field Programmable Gate Array, FPGA), etc.
  • ASIC application specific integrated circuits
  • DSP digital singnalprocessor
  • FPGA Field Programmable Gate Array
  • the processing element may be a general-purpose processor, such as a central processing unit (CPU) or other processors that can call programs.
  • CPU central processing unit
  • these units can be integrated together and implemented in the form of a system-on-a-chip (SOC).
  • SOC system-on-a-chip
  • a computer device in one embodiment, includes a memory, a processor, and computer-readable instructions stored on the memory and executable on the processor.
  • the memory is used to store a program that implements the method executed by the method embodiment shown in FIG. 3.
  • the processor invokes the computer-readable instructions to execute the operations of the above method embodiments.
  • the function performed by the processor of the above-mentioned computer device is only an example in this embodiment and cannot be used to limit the computer device in this application.
  • the computer device of the present application can execute any step in the method shown in FIG. 3.
  • a non-volatile readable storage medium storing computer readable instructions.
  • the computer readable instructions are executed by one or more processors, one or more processors execute the graph. 3 shows the method.
  • the steps executed by the computer-readable instructions stored in the storage medium are only an example in this embodiment, and cannot be used to limit the computer-readable instructions stored in the storage medium in this application.
  • the computer-readable instructions stored in the storage medium can be used to execute any step in the method shown in FIG. 3.
  • the computer program can be stored in a computer readable storage medium. When executed, it may include the processes of the above-mentioned method embodiments.
  • the aforementioned storage medium may be a non-volatile storage medium such as a magnetic disk, an optical disc, a read-only memory (Read-Only Memory, ROM), or a random access memory (Random Access Memory, RAM), etc.
  • the steps of the method or algorithm described in combination with the embodiments disclosed in this document can be implemented by hardware, a software module executed by a processor, or a combination of the two.
  • the software module can be placed in random access memory (RAM), internal memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disks, removable disks, CD-ROMs, or all areas in the technical field. Any other known storage medium.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

本申请涉及一种基于HashMap的数据获取方法、装置、计算机设备和存储介质。包括确定公共获取方式,所述公共获取方式为公共方法的静态类;确定需要获取的内容的名称和内容的标记,所述内容的标记用于唯一对应需要获取的内容;将所述需要获取的内容的名称和内容的标记添加到所述确定的公共获取方式;向数据库发送获取指令,所述获取指令包括添加了所述需要获取的内容的名称和内容的标记的公共获取方式,以通过所述公共获取方式获取相应内容的值;获取数据库根据公共获取方式反馈的数据,数据为与需要获取的内容相对应的数据。上述方法可以避免现有技术在获取HashMap的集合中的值时需要每一层获取他的键key并且每一层都要进行非空判断,否则就会报错的问题。

Description

基于HashMap的数据获取方法、装置、计算机设备和存储介质
本申请要求与2019年2月20日提交中国专利局、申请号为201910127570X、申请名称为“基于HashMap的数据获取方法、装置、计算机设备和存储介质”的中国专利申请的优先权,其全部内容通过引用结合在申请中。
技术领域
本申请涉及测试领域,特别是涉及基于HashMap的数据获取方法、装置、计算机设备和存储介质。
背景技术
HashMap是一个用于存储Key-Value键值对的集合。每一个键值对也叫做Entry。键值对(Entry)分散存储在一个数组当中。数组是HashMap的主干。
对于HashMap,我们最常使用的是使用Get或Put两种方法。Get方法是根据Key来查找Value。使用Get方法时,首先会把输入的Key做一次Hash映射。由于Hash冲突,同一个位置有可能匹配到多个结果。因此,需要顺着对应链表的头节点向下一个节点查找。因此,由于传统集合放入HashMap集合中以键值关系存储时会有复杂的嵌套,需要每一层获取键key时,需要对每一层进行非空判断。否则可能存在报错的现象。发明人发现上述问题增加了开发的逻辑,降低了运行效率。
发明内容
基于此,有必要针对在HashMap集合中获取数据时,采用一种基于HashMap集合的数据获取方法、装置、计算机设备和存储介质。以解决现有技术在获取HashMap的集合中的值时需要对每一层获取的键key进行非空判断。减少了开发逻辑,提高了运行效率。
依据本申请一个方面,提供一种基于HashMap集合的数据获取方法,所述方法包括:确定公共获取方式,所述公共获取方式为公共方法的静态类;确定需要获取的内容的名称和所述内容的标记,所述内容的标记用于唯一对应需要获取的内容;将所述需要获取的内容的名称和所述内容的标记添加到所述确定的公共获取方式;向数据库发送获取指令,所述获取指令包括添加了所述需要获取的内容的名称和所述内容的标记的公共获取方式,以通过所述公共获取方式获取相应内容的值;获取所述数据库根据所述公共获取方式反馈的数据,所述数据为与需要获取的内容相对应的数据。
依据本申请另一个方面,提供一种数据获取装置,所述数据获取装置包括:确定单元,用于确定公共获取方式,所述公共获取方式为公共方法的静态类;所述确定单元,还用于确定需要获取的内容的名称和所述内容的标记,所述内容的标记用于唯一对应需要获取的内容;处理单元,用于将所述需要获取的内容的名称和所述内容的标记添加到所述确定的公共获取方式;发送单元,用于向数据库发送获取指令,所述获取指令包括添加了所述需要获取的内容的名称和所述内容标记的公共获取方式,以通过所述公共获取方式获取相应内容的值;获取单元,用于获取所述数据库根据所述公共获取方式反馈的数据,所述数据为与需要获取的内容相对应的数据。
依据本申请又一个方面,提供一种计算机设备,包括存储器和处理器,所述存储器中存储有计算机可读指令,所述计算机可读指令被所述处理器执行时,使得所述处理器执行以下步骤:
确定公共获取方式,所述公共获取方式为公共方法的静态类;确定需要获取的内容和标记,所述需要获取的标记为需要获取的内容的标识,所述标识用于唯一对应需要获取的内容;将所述需要获取的内容和标记添加到所述确定的公共获取方式;向数据库发送获取指令,所述获取指令包括添加了所述需要调用的内容和标记的公共获取方式,以通过所述公共获取方式获取相应内容的值。
依据本申请再一个方面,提供一种存储有计算机可读指令的非易失性可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得一个或多个处理器执行基于HashMap集合的数据获取方法的步骤。
本申请提供的一种基于HashMap集合的数据获取方法、装置、计算机设备和存储介质,通过在获取基于HashMap集合的数据时,在确定需要获取的内容和标记后,将该公共获取方式向数据库发送。以通过该数据库获取相应的内容。从而避免现有技术在获取HashMap的集合中的值时需要每一层获取他的键key并且每一层都要进行非空判断,否则就会报错的问题。
附图说明
图1为一个实施例中提供的基于HashMap集合的数据获取方法的实施环境图;
图2为一个实施例中计算机设备的内部结构示意图;
图3为本申请具体实施了的一种基于HashMap的数据获取方法;
图4为本申请实施例中的一种数据获取装置。
具体实施方式
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。
可以理解,本申请所使用的术语“第一”、“第二”等可在本文中用于描述各种元件,但这些元件不受这些术语限制。这些术语仅用于将第一个元件与另一个元件区分。举例来说,在不脱离本申请的范围的情况下,可以将第一手势测试脚本称为第二手势测试脚本,且类似地,可将第二手势测试脚本称为第二手势测试脚本。
图1为一个实施例中提供的基于HashMap集合的数据获取方法的实施环境图,如图1所示,在该实施环境中,包括计算机设备110和数据库设备120。计算机设备110为用户设备,例如为人员使用的电脑等计算机设备,计算机设备110上安装有相应的代码处理软件。数据库设备120中包括有相应的数据库,数据库包括存储相应的数据。当需要从数据库中获取相应的数据时,测试人员可以在计算机设备110发出相应的获取请求,该请求中携带有需要获取的数据的内容和标示。计算机设备110接收该请求时,根据内容和标识获取数据库设备120中存储的与该内容和标示对应的数据。该数据库设备还根据该数据获取请求的指令,将相应的数据反馈至。计算机设备110和用户设备120可以通过蓝牙、USB(Universal Serial Bus,通用串行总线)或者其他通讯连接方式进行连接,本申请在此不做限制。
图2为一个实施例中计算机设备的内部结构示意图。如图2所示,该计算机设备包括通过系统总线连接的处理器、非易失性存储介质、存储器和网络接口。其中,该计算机设备的非易失性存储介质存储有操作系统、数据库和计算机可读指令,数据库中可存储有控件信息序列,该计算机可读指令被处理器执行时,可使得处理器实现一种基于HashMap的数据获取方法。该计算机设备的处理器用于提供计算和控制能力,支撑整个计算机设备的运行。该计算机设备的存储器中可存储有计算机可读指令,该计算机可读指令被处理器执行时,可使得处理器执行一种基于HashMap的数据获取方法。一种基于HashMap的数据获取方法具体可以如下图3所示。该计算机设备的网络接口用于与终端连接通信。本领域技术人员可以理解,图2中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。
下面,通过具体实施例对本申请的数据获取方法进行具体说明。
图3为本申请具体实施了的一种基于HashMap的数据获取方法。如图3所示,在一个实施例中,提出了一种基于HashMap的数据获取方法,该数据获取方法可以应用于上述的计算机设备110中,具体可以包括以下步骤:
步骤302,确定公共获取方式,该公共获取方式为公共方法的静态类;在本实施例中,该静态类(静态方法)为现有技术,本申请对此不进行限定。
在一些实施例中,本申请中包括的公共获取方式可以为一个或者为多个。当本申请中包括的公共获取方式为一个时,直接确定使用该公共获取方式获取相应的参数。当本申请中包括的公共获取方式为多个时,还需要根据需要获取的参数或类型确定采用哪个公共获取方式。上述从多个公共获取方式中确定公共获取方式仅为本申请的举例。在本申请中,可以基于多种原因确定从公共获取方式中确定一个公共获取方式。
步骤304,确定需要获取的内容和标记,所述需要获取的标记为需要获取的内容的标识,所述标识用于唯一对应需要获取的内容;
通过需要获取的标记判断查找到的值是否为需要调用的内容。在本申请的实施例中,每个键值对还包括对应的标记。
可选的,本申请实施例中确定需要调用的内容前,包括确定需要获取的内容的格式。确定需要获取的内容的格式可以有多重方式。在一个例子中,用户在获取HashMap集合中的数据前,向数据库发送一个获取指令。获取指令用于指示数据库获取HashMap集合中包括的数据的结构。数据库根据该获取指令返回该 数据库中包括的HashMap集合中的数据结构。
当然,向数据库发送获取指令仅为本申请的一种具体实现方式。用于可以基于多种原因知道需要获取的数据的格式。例如,当已经确定需要获取的数据的结构时,用户也可以直接根据该确定的内容、标识添加至公共获取方式。例如,该需要调用的MAP的结构为用户手动拼接。键值对象的值(一个集合)当中可能还嵌套了另一个子的键值对象。例如,第一个键值对象k1,k1的值为第一集合,第一集合中还嵌套了一个第二键值对象K2,K2的值为第二个集合,第二个集合中还嵌套一个第三键值对象K3,K3的值为第三个集合。对于多层嵌套的键值对象的值的获取,在一个例子中,只需要自定义一个规则,比如key.key.key……。
在一个例子中,数据库的HashMap集合中包括键值对K1,K1的值下包括嵌套在K1中的K2,K2的值下包括嵌套在K2中的K3。当需要获取K1的value时,则需要获取的内容的格式为K1;当需要获取的内容的格式为K2的value时,则需要获取的内容的格式为K1.K2;当需要获取K3的value值时,则需要获取的内容的格式为K1.K2.K3。
当然,上述需要获取的内容仅为本申请的一种举例,不能用于对本申请的限定。例如,当需要获取K3的value值时,则需要获取的内容的格式为K1,K2,K3。
步骤306,将所述需要获取的内容和标记添加到所述确定的公共获取方式;
在本申请的实施例中,该公共获取方式包括添加需要获取的内容和标记的位置。从而使该公共获取方式通过添加的需要获取的内容和标记查找相应的数据。该公共获取方式通过添加需要获取的内容和标记到达相应的内容,以及判断到达的内容是否为需要获取的内容。
步骤308,向数据库发送获取指令,所述获取指令包括添加了所述需要调用的内容和标记的公共获取方式,以通过所述公共获取方式获取相应内容的值;用户在在确定公共获取方式、需要查找的内容和标记后,将向数据库发送获取指令。
步骤310,获取所述数据库根据所述公共获取方式反馈的数据,所述数据为与需要获取的内容相对应的数据。数据库将根据该获取指令确定相应的需要查找的内容。数据库在确定需要查找的内容后,还将对该需要获取的内容通过获取指令中包括的标记进行判断,以确定该内容是不是需要获取的内容。当该内容是需要获取的内容时,数据库将把该内容的值返回。
在一个例子中,在本申请的实施例中,所述数据库将该内容的值返回前还包括将内容的值相对应的字符串由object格式转换为string格式。通过将获取的数据的格式由object格式转换为string格式避免了直接将获取的object格式的数据返回且反馈的数据为空时,强转而出现异常报错的问题。
需要说明的时,将key的value相对应的字符串由object格式转换为string格式可以在数据库端实现也可以在计算器端实现,本申请对该数据转换的方式不限定。
在本申请的实施例中,还包括将key(内容)的value(值)为相应的字符串由object格式转换为string格式的方法。本申请中将key的value为相应的字符串由object格式转换为string格式的方法为现有技术,本申请对此方法的内容不进行限定。
下面,通过具体实例对key的value为相应的字符串由object格式转换为string格式的方法进行举例说明。
字符串由object格式转换为string格式常用的方法有Object.to String(),(String)要转换的对象,String.value Of(Object)等。下面对这些方法一一进行分析。
方法1:采用Object.to String()方法
在一个例子中:
Object object=get Object();
System.out.println(object.toString());
因为java.lang.Object类里已有public方法.to String(),所以对任何严格意义上的java对象都可以调用此方法。object不是null值,否则将抛出Null Pointer Exception异常。所述方法通常派生类会覆盖Object里的to String()方法。
方法2:采用类型转换(String)object方法
方法2是标准的类型转换,将object转成String类型的值。其中,需要转换的数据类型必须能转成String 类型。因此在转换前,该方法还可以包括instanceof类型检查,以判断是否可以转换,否则容易出现Class Cast Exception异常。此外,因定义为Object类型的对象在转成String时语法检查并不会报错,这将可能导致潜在的错误存在。
如:
Object obj=new Integer(100);
String strVal=(String)obj;
在运行时将会出错,因为将Integer类型强制转换为String类型,无法通过。但是,
Integer obj=new Integer(100);
String strVal=(String)obj;
此外,因null值可以强制转换为任何java类类型,(String)null也是合法的。
方法3:采用String.value Of(Object)
String.value Of(Object)的基础是Object.to String()。但它与Object.to String()又有所不同。在前面方法1中,需保证不为null。但采用第三种方法时,将不用担心object是否为null值这一问题。
为了便于说明问题,我们来分析一下相关的源代码。Jdk里String.value Of(Object)源码如下:
/**
*Returns the string representation ofthe Object argument.
*
*@param obj an Object.
*@return ifthe argument is null,then a string equal to
*"null";otherwise,the value of
*obj.to String()is returned.
*@seejava.lang.Object.to String()
*/
public static Stringvalue Of(Object obj){
return(obj==null)?"null":obj.to String();
}
从上面的源码可以很清晰的看出null值不用担心的理由。
本申请的格式转换方法可以采用方法3,当object为null时,String.value Of(object)的值是字符串"null",而不是null。
在本申请的实施例中,数据库在根据内容和标记没有查到相对应value,或数据库对根据内容确定的value通过标记验证时,还将确定当前的value值中是否包括嵌套的值。如果value中包括嵌套的内容,则该数据库还继续在该嵌套的内容中执行该公共获取方式,并判断该嵌套的内容的值的标记是否与该需要获取的内容的标记相对应。
例如,需要获取的内容为value3,而写入公共获取方式中获取的内容为K1.k2。该公共获取方式进入到K2后,确定K2值的标记与需要获取的内容的标记不相匹配时,则该公共获取方式还确定该K2的值中是否嵌套了更下层的内容。若K2的值中嵌套了更下层的内容(K3),则确定K3是否为需要查找的内容。确定K3是否为需要查找的内容可以根据上述内容确定,本申请在此不再赘述。当K3为需要查找的内容,则确定该需要获取的内容的标记是否与K3的value的标记相对应。如果需要获取的内容的标记与K3的value的标记相对应,则确定K3的值时需要获取的内容。如果需要获取的内容不是K3,或,需要获取的内容的标记与K3的标记不相匹配时,该数据库还继续确定K3的值中是否有嵌套。继续执行上述内容,直到找到value3或将K2下嵌套值遍历完。
作为本申请进一步的改进,该公共获取方式最终没有获取到需要获取的值时,将返回空字符串。
相对于现有技术中直接返回没有值的object对象。本申请通过返回空字符串,从而避免在不进行逻辑判断、校验直接去使用开内容为空的对象时出现报错。保证不管是传错的键还是没有值的情况,都返回空字符串处理。从而使业务代码主逻辑也会变得简易。
下面通过具体的例子对本申请所述的公共调用方式的调用规则进行说明
在第一个例子中,数据库的HashMap集合中包括键值对K1,K1的值下包括嵌套在K1中的K2,K2的值下包括嵌套在K2中的K3。当需要获取K1的value时,则需要获取的内容的格式为K1;当需要获取的内容的格式为K2的value时,则需要获取的内容的格式为K1.K2;当需要获取K3的value值时,则需要获取的内容的格式为K1.K2.K3。
需要获取上面例子中的K1的值。将K1的内容和标记交给该公共调用方式。该公共调用方式根据内容和标记查找到相应的集合。并将该集合中包括的数据获取出来。其中,该集合中包括的数据时包括集合K2和K3.
在第二个例子中,需要获取上面例子中的K3的值。将K3的内容和标记交给该公共调用方式。该公共调用方式根据内容和标记查找到K1,从K1的value下查找到K2,再从K2的value下查找到K3,获取K3的value值。将K3的值与内容的标识进行对比,在确定相同时,获取K3的value。
在根据内容和标示查找到相对应的值,将查找到的值返回。当然,在查找到的值返回前或返回后,还包括将查找到的相应的字符串由object格式转换为string格式。
如图4所示,为本申请实施例中的一种数据获取装置。所述数据获取装置包括:确定单元、处理单元和发送单元。
确定单元,用于确定公共获取方式,所述公共获取方式为公共方法的静态类。确定单元,还用于确定需要获取的内容的名称和所述内容的标记,所述内容的标记用于唯一对应需要获取的内容。
处理单元,用于将所述需要获取的内容的名称和所述内容的标记添加到所述确定的公共获取方式。
发送单元,用于向数据库发送获取指令,所述获取指令包括添加了所述需要获取的内容的名称和所述内容的标记的公共获取方式,以通过所述公共获取方式获取相应内容的值。
获取单元,用于获取所述数据库根据所述公共获取方式反馈的数据,所述数据为与需要获取的内容相对应的数据。
可选的,所述处理单元还用于将获取的字符串转换为string格式。或者,本申请的数据获取装置还包括一个转换单元,通过所述转换单元将获取的字符串转换为string格式。
可选的,所述公共获取方式还用于指示所述数据库在没有根据所述公共获取方式获取到与所述内容的名称和所述内容的标记相对应的值时,将返回空字符串,所述孔字符串的类型为string格式。
可选的,所述确定单元确定公共获取方式包括:确定需要获取的内容的类型;根据需要获取的内容的类型确定公共获取方式。
可选的,所述确定单元在确定需要获取的内容的名称和所述内容标记前,还包括向一个接口端发送一个内容获取指令,以获取数据库中包括的内容的结构。
当然,数据获取装置中的上述模块及模块所执行的功能仅为本实施例中的一种举例,不能用于对本申请中数据获取装置的限定。数据获取装置可以执行图3所示方法中的任意步骤。
应理解以上数据获取装置的各个单元的划分仅仅是一种逻辑功能的划分,实际实现时可以全部或部分集成到一个物理实体上,也可以物理上分开。且这些单元可以全部以软件通过处理元件调用的形式实现;也可以全部以硬件的形式实现;还可以部分单元通过软件通过处理元件调用的形式实现,部分单元通过硬件的形式实现。例如,确定单元可以为单独设立的处理元件,也可以集成在基站的某一个芯片中实现,此外,也可以以程序的形式存储于基站的存储器中,由基站的某一个处理元件调用并执行第一控制单元的功能。其它单元的实现与之类似。需要说明的是,接收单元可以通过射频装置和天线与终端通信,例如基站可以通过天线接收终端发送的信息,接收的信息通过射频装置处理后发送给接收单元。此外通信装置的单元可以全部或部分集成在一起,也可以独立实现。这里所述的处理元件可以是一种集成电路,具有信号的处理能力。在实现过程中,上述方法的各步骤或以上各个单元可以通过处理器元件中的硬件的集成逻辑电路或者软件形式的指令完成。
例如,以上这些单元可以是被配置成实施以上方法的一个或多个集成电路,例如:一个或多个特定集成电路(Application Specific Integrated Circuit,ASIC),或,一个或多个微处理器(digital singnalprocessor,DSP),或,一个或者多个现场可编程门阵列(Field Programmable GateArray,FPGA)等。再如,当以上某个单元通过处理元件调度程序的形式实现时,该处理元件可以是通用处理器,例如中央处理器(Central Processing Unit,CPU)或其它可以调用程序的处理器。再如,这些单元可以集成在一起,以片上系统 (system-on-a-chip,SOC)的形式实现。
在一个实施例中,提出了一种计算机设备,所述计算机设备包括存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机可读指令。存储器用于存储实现图3所示方法实施例所执行的方法的程序。处理器调用该计算机可读指令,执行以上方法实施例的操作。
所述处理器执行所述计算机可读指令时实现图3所述的方法。
当然,上述计算机设备的处理器所执行的功能仅为本实施例中的一种举例,不能用于对本申请中的计算机设备的限定。本申请的计算机设备可以执行图3所示方法中的任意步骤。
在一个实施例中,提出了一种存储有计算机可读指令的非易失性可读存储介质,该计算机可读指令被一个或多个处理器执行时,使得一个或多个处理器执行图3所示的方法。
当然,上述存储介质中存储的计算机可读指令所执行的步骤仅为本实施例中的一种举例,不能用于对本申请中存储介质中所存储的计算机可读指令的限定。存储介质中存储的计算机可读指令可以被用于执行图3所示方法中的任意步骤。
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,该计算机程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,前述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)等非易失性存储介质,或随机存储记忆体(Random Access Memory,RAM)等。
结合本文中所公开的实施例描述的方法或算法的步骤可以用硬件、处理器执行的软件模块,或者二者的结合来实施。软件模块可以置于随机存储器(RAM)、内存、只读存储器(ROM)、电可编程ROM、电可擦除可编程ROM、寄存器、硬盘、可移动磁盘、CD-ROM、或技术领域内所公知的任意其它形式的存储介质中。
以上所述实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对本申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。

Claims (20)

  1. 一种基于HashMap的数据获取方法,所述方法包括:
    确定公共获取方式,所述公共获取方式为公共方法的静态类;
    确定需要获取的内容的名称和所述内容的标记,所述内容的标记用于唯一对应需要获取的内容;
    将所述需要获取的内容的名称和所述内容的标记添加到所述确定的公共获取方式;
    向数据库发送获取指令,所述获取指令包括添加了所述需要获取的内容的名称和所述内容的标记的公共获取方式,以通过所述公共获取方式获取相应内容的值;
    获取所述数据库根据所述公共获取方式反馈的数据,所述数据为与需要获取的内容相对应的数据。
  2. 根据权利要求1所述的基于HashMap的数据获取方法,获取所述数据库根据所述公共获取方式反馈的数据后,所述方法还包括:
    将获取的字符串转换为string格式。
  3. 根据权利要求1所述的基于HashMap的数据获取方法,所述确定需要获取的内容的名称和所述内容的标记前,所述方法还包括向一个接口端发送一个内容获取指令,以获取数据库中包括的内容的结构。
  4. 根据权利要求1所述的基于HashMap的数据获取方法,所述公共获取方式还用于指示所述数据库在没有根据所述公共获取方式获取到与所述内容的名称和所述内容的标记相对应的值时,将返回空字符串,所述孔字符串的类型为string格式。
  5. 根据权利要求1所述的基于HashMap的数据获取方法,所述确定公共获取方式,包括:
    确定需要获取的内容的类型;
    根据需要获取的内容的类型确定公共获取方式。
  6. 一种数据获取装置,所述数据获取装置包括:
    确定单元,用于确定公共获取方式,所述公共获取方式为公共方法的静态类;
    所述确定单元,还用于确定需要获取的内容的名称和所述内容的标记,所述内容的标记用于唯一对应需要获取的内容;
    处理单元,用于将所述需要获取的内容的名称和所述内容的标记添加到所述确定的公共获取方式;
    发送单元,用于向数据库发送获取指令,所述获取指令包括添加了所述需要获取的内容的名称和所述内容的标记的公共获取方式,以通过所述公共获取方式获取相应内容的值;
    获取单元,用于获取所述数据库根据所述公共获取方式反馈的数据,所述数据为与需要获取的内容相对应的数据。
  7. 根据权利要求6所述的数据获取装置,所述处理单元还用于:
    将获取的字符串转换为string格式。
  8. 根据权利要求6所述的数据获取装置,所述公共获取方式还用于指示所述数据库在没有根据所述公共获取方式获取到与所述内容和标示相对应的值时,将返回空字符串,所述空字符串的类型为string格式。
  9. 根据权利要求6所述的数据获取装置,所述公共获取方式还用于指示所述数据库在没有根据所述公共获取方式获取到与所述内容的名称和所述内容的标记相对应的值时,将返回空字符串,所述孔字符串的类型为string格式。
  10. 根据权利要求6所述的数据获取装置,所述确定单元,具体用于确定需要获取的内容的类型;根据需要获取的内容的类型确定公共获取方式。
  11. 一种计算机设备,包括存储器和处理器,所述存储器中存储有计算机可读指令,所述计算机可读指令被所述处理器执行时,使得所述处理器执行基于HashMap的数据获取方法,包括:确定公共获取方式,所述公共获取方式为公共方法的静态类;确定需要获取的内容的名称和所述内容的标记,所述内容的标记用于唯一对应需要获取的内容;将所述需要获取的内容的名称和所述内容的标记添加到所述确定的公共获取方式;向数据库发送获取指令,所述获取指令包括添加了所述需要获取的内容的名称和所述内容的标记的公共获取方式,以通过所述公共获取方式获取相应内容的值;获取所述数据库根据所述公共获取方式反馈的数据,所述数据为与需要获取的内容相对应的数据。
  12. 根据权利要求11所述的计算机设备,所述计算机可读指令被所述处理器执行时,使得所述处理器执行获取所述数据库根据所述公共获取方式反馈的数据后,所述方法还包括:将获取的字符串转换为string格式。
  13. 根据权利要求11所述的计算机设备,所述计算机可读指令被所述处理器执行时,使得所述处理器执行所述确定需要获取的内容的名称和所述内容的标记前,所述方法还包括向一个接口端发送一个内容获取指令,以获取数据库中包括的内容的结构。
  14. 根据权利要求11所述的计算机设备,所述计算机可读指令被所述处理器执行时,使得所述处理器执行所述公共获取方式还用于指示所述数据库在没有根据所述公共获取方式获取到与所述内容的名称和所述内容的标记相对应的值时,将返回空字符串,所述孔字符串的类型为string格式。
  15. 根据权利要求11所述的计算机设备,所述计算机可读指令被所述处理器执行时,使得所述处理器执行所述确定公共获取方式,包括:确定需要获取的内容的类型;根据需要获取的内容的类型确定公共获取方式。
  16. 一种存储有计算机可读指令的非易失性可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得一个或多个处理器执行基于HashMap的数据获取方法,包括:确定公共获取方式,所述公共获取方式为公共方法的静态类;确定需要获取的内容的名称和所述内容的标记,所述内容的标记用于唯一对应需要获取的内容;将所述需要获取的内容的名称和所述内容的标记添加到所述确定的公共获取方式;向数据库发送获取指令,所述获取指令包括添加了所述需要获取的内容的名称和所述内容的标记的公共获取方式,以通过所述公共获取方式获取相应内容的值;获取所述数据库根据所述公共获取方式反馈的数据,所述数据为与需要获取的内容相对应的数据。
  17. 根据权利要求16所述的存储介质,所述计算机可读指令被所述处理器执行时,使得所述处理器执行获取所述数据库根据所述公共获取方式反馈的数据后,所述方法还包括:将获取的字符串转换为string格式。
  18. 根据权利要求16所述的存储介质,所述计算机可读指令被所述处理器执行时,使得所述处理器执行所述确定需要获取的内容的名称和所述内容的标记前,所述方法还包括向一个接口端发送一个内容获取指令,以获取数据库中包括的内容的结构。
  19. 根据权利要求16所述的存储介质,所述计算机可读指令被所述处理器执行时,使得所述处理器执行所述公共获取方式还用于指示所述数据库在没有根据所述公共获取方式获取到与所述内容的名称和所述内容的标记相对应的值时,将返回空字符串,所述孔字符串的类型为string格式。
  20. 根据权利要求16所述的存储介质,所述计算机可读指令被所述处理器执行时,使得所述处理器执行所述确定公共获取方式,包括:确定需要获取的内容的类型;根据需要获取的内容的类型确定公共获取方式。
PCT/CN2019/117488 2019-02-20 2019-11-12 基于HashMap的数据获取方法、装置、计算机设备和存储介质 Ceased WO2020168751A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910127570.XA CN109992581B (zh) 2019-02-20 2019-02-20 基于HashMap的数据获取方法、装置、计算机设备和存储介质
CN201910127570.X 2019-02-20

Publications (1)

Publication Number Publication Date
WO2020168751A1 true WO2020168751A1 (zh) 2020-08-27

Family

ID=67130197

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/117488 Ceased WO2020168751A1 (zh) 2019-02-20 2019-11-12 基于HashMap的数据获取方法、装置、计算机设备和存储介质

Country Status (2)

Country Link
CN (1) CN109992581B (zh)
WO (1) WO2020168751A1 (zh)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109992581B (zh) * 2019-02-20 2023-05-26 平安科技(深圳)有限公司 基于HashMap的数据获取方法、装置、计算机设备和存储介质
CN112612530B (zh) * 2019-09-18 2022-05-17 华为技术有限公司 类查询方法及装置
CN112579623B (zh) * 2019-09-29 2024-08-02 北京国双科技有限公司 存储数据的方法、装置、存储介质及设备

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150363174A1 (en) * 2014-06-12 2015-12-17 Oracle International Corporation Complex constants
CN107766039A (zh) * 2017-10-30 2018-03-06 中国平安财产保险股份有限公司 从Java对象中存取属性值的方法、服务器及存储介质
CN109343968A (zh) * 2018-08-02 2019-02-15 武汉斗鱼网络科技有限公司 一种获取数据的方法和相关装置
CN109992581A (zh) * 2019-02-20 2019-07-09 平安科技(深圳)有限公司 基于HashMap的数据获取方法、装置、计算机设备和存储介质

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107704554A (zh) * 2017-09-27 2018-02-16 广东亿迅科技有限公司 基于mpp数据库的数据高速导入的方法及其系统

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150363174A1 (en) * 2014-06-12 2015-12-17 Oracle International Corporation Complex constants
CN107766039A (zh) * 2017-10-30 2018-03-06 中国平安财产保险股份有限公司 从Java对象中存取属性值的方法、服务器及存储介质
CN109343968A (zh) * 2018-08-02 2019-02-15 武汉斗鱼网络科技有限公司 一种获取数据的方法和相关装置
CN109992581A (zh) * 2019-02-20 2019-07-09 平安科技(深圳)有限公司 基于HashMap的数据获取方法、装置、计算机设备和存储介质

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
WAN, CHANGLIN ET AL.: "Computer and Modernization", 6 November 2014, CHINA STATISTICS PRESS, CN, ISBN: 7-5037-2244-4, article WAN, CHANGLIN ET AL.: "System of Semantics-base d Keyword Search over Relational Database", pages: 39 - 40, XP009522919 *

Also Published As

Publication number Publication date
CN109992581A (zh) 2019-07-09
CN109992581B (zh) 2023-05-26

Similar Documents

Publication Publication Date Title
NL2029881B1 (en) Methods and apparatus for automatic detection of software bugs
US10565097B2 (en) Orchestrating and providing a regression test
US10198250B1 (en) Partitioning based migration of systems to container and microservice based platforms
CN108984388B (zh) 一种生成自动化测试用例的方法及终端设备
CN107729227B (zh) 应用程序测试范围确定方法、系统、服务器和存储介质
US7469362B2 (en) Using a call stack hash to record the state of a process
WO2020000706A1 (zh) 基于数据库比对的接口测试方法、系统、设备和存储介质
WO2019085079A1 (zh) 接口测试方法、装置、计算机设备和存储介质
WO2019200701A1 (zh) 一种配置管理方法、装置、终端设备及存储介质
US8631280B2 (en) Method of measuring and diagnosing misbehaviors of software components and resources
US20220066896A1 (en) Method, system, and apparatus for monitoring blockchain smart contract
WO2020168751A1 (zh) 基于HashMap的数据获取方法、装置、计算机设备和存储介质
KR20080050331A (ko) 디버그 정보 수집 방법 및 디버그 정보 수집 시스템
CN113050953A (zh) 基于注释生成代码的方法、装置及存储介质
CN107798617A (zh) 保险业务处理方法和装置
US20170048008A1 (en) Method and apparatus for verification of network service in network function virtualization environment
WO2023103640A1 (zh) 测试用例的生成方法、装置、电子设备和存储介质
CN114510408B (zh) 一种信息反馈方法、装置、系统、设备及存储介质
CN111240953A (zh) 一种日志处理的方法及装置、可读存储介质
CN114756363A (zh) 一种资源配置检测方法及装置
CN111046393B (zh) 漏洞信息上传方法、装置、终端设备及存储介质
CN113032100B (zh) 一种异常处理方法、装置、设备及存储介质
US20250028514A1 (en) Automatic self-adapting application deployment for cloud applications
CN116483888B (zh) 程序评估方法及装置、电子设备和计算机可读存储介质
CA2947893C (en) Orchestrating and providing a regression test

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19916487

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19916487

Country of ref document: EP

Kind code of ref document: A1