Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

The method, storage medium, equipment and system for calling the code of the main project by the component project

An engineering code and engineering technology, which is applied in the field of component engineering calling main engineering code, can solve problems such as conflicts, high coupling, and codes that cannot call codes

Active Publication Date: 2019-11-15
WUHAN DOUYU NETWORK TECH CO LTD
View PDF2 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] The code of the main project can access or call the external methods provided in all component projects, and at the same time, the component project can also depend on other component projects, that is, a component project can access or call the external methods provided by other component projects. There is a restriction that the main project depends on each component project. The code in the main project can call the code in the component project, but the component project cannot depend on the main project, that is, the code in the component project cannot call the code in the main project. the code
As a result, in the process of promoting iOS componentization, if the coupling between some codes in the main project is too high, it cannot be split into a component project separately, and can only be placed in the main project, and some component projects need to access The codes in this part conflict with each other and affect the process of iOS component development

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
  • The method, storage medium, equipment and system for calling the code of the main project by the component project
  • The method, storage medium, equipment and system for calling the code of the main project by the component project

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0026] The present invention will be described in further detail below in conjunction with the accompanying drawings and embodiments.

[0027] see figure 1 As shown, the embodiment of the present invention provides a method for a component project to call the main project code, which is suitable for calling the main project code by the component project in the iOS development CocoaPods componentization solution, that is, the component project calls the method in the main project. The method for the component project in the embodiment of the present invention to call the main project code specifically includes:

[0028] S1: Create a message forwarding component in the component project, and expose the Target class in the component project that can be accessed by other component projects and the main project as the external interface of the component project, and the message forwarding component is used to receive messages. The component project has the directory structure of C...

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 present invention relates to the field of software development. Disclosed are a method, device and system for calling a main project code by a component-based software project and a storage medium. The method comprises: establishing a message forwarding component in a component-based software project, and exposing a Target class capable of being accessed by other component-based software projects and a main project in component-based software project to serve as an external interface of the component-based software project (S1), wherein the message forwarding component is used for receiving messages; establishing a Category class extension file of the Target class in main project, and adding to the established extension file a declaration and an implementation of a main project method to be called (S2); sending the extension file to the message forwarding component of the component-based software project in a message forwarding mode through the external interface of the component-based software project, and calling, by the component-based software project, the main project method to be called located in the extension file (S3). The above method can effectively improve the efficiency of iOS development.

Description

technical field [0001] The invention relates to the field of software development, in particular to a method, a storage medium, a device and a system for calling a main project code by a component project. Background technique [0002] With the gradual iteration of mobile application functional requirements, the code size of the application is also increasing. Therefore, in order to better manage the application project, iOS componentization is a method often used in the current iOS system development. With the help of CocoaPods dependency package management tool Split the original application project (main project), create a separate project for the split part, and package it into a component project that can be managed by CocoaPods according to the format specified by CocoaPods. After the split is completed, write in the main project The component information of all split component projects can be downloaded by calling the relevant commands of CocoaPods and integrated into...

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
Patent Type & Authority Patents(China)
IPC IPC(8): G06F9/448
CPCG06F9/44G06F9/54
Inventor 黄露洋陈少杰张文明
Owner WUHAN DOUYU NETWORK TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products