Unlock instant, AI-driven research and patent intelligence for your innovation.

Container traversing method and device

A container and traversal technology, applied in the computer field, can solve the problems of lack of flexibility of containers, heavy code writing workload, etc.

Active Publication Date: 2019-05-17
NETEASE (HANGZHOU) NETWORK CO LTD
View PDF2 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] However, for containers of different nesting types, different codes must be written to achieve traversal. Not only the code writing workload is heavy, but the traversal of containers lacks flexibility

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
  • Container traversing method and device
  • Container traversing method and device
  • Container traversing method and device

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0052] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments It is a part of embodiments of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.

[0053] figure 1 The flow of the method for traversing the container provided by the embodiment of the present invention Figure 1 . Such as figure 1 As shown, the method includes:

[0054] S101. Unnesting the nested containers to be traversed to obtain types of multiple containers; wherein, the nested container is a container obtained by nesti...

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 embodiment of the invention provides a container traversing method and device, and the method comprises the steps: carrying out the de-nesting of a to-be-traversed nesting container, and obtainingthe types of a plurality of containers; Wherein the nesting container is a container obtained by nesting a plurality of containers. Traversing the content of the nested container according to the traversing template corresponding to the type of each container; Wherein the traversal template is a code used for traversing the content of the container of the corresponding type. According to the embodiment, the code writing workload can be reduced, and the container traversal flexibility can be improved.

Description

technical field [0001] Embodiments of the present invention relate to computer technology, and in particular to a method and device for traversing containers. Background technique [0002] A container is a commonly used tool in C++. In the process of operating a program containing a container, it is often necessary to traverse the contents of the container to achieve the corresponding operation. [0003] When traversing the content of the container in the prior art, it is usually necessary to first determine the type of the container and the type of the sub-elements contained in the container, and then write the corresponding code according to the type of the container and the type of the sub-elements contained in the container, for the nested type Containers need to use multi-layer loops to traverse the containers. [0004] However, for containers of different nesting types, different codes must be written to achieve traversal. Not only the code writing workload is heavy, ...

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): G06F8/20
Inventor 郭昂
Owner NETEASE (HANGZHOU) NETWORK CO LTD