Method and system for realizing mapping from YANG model to internal model
A technology of internal model and mapping relationship, applied in the field of communication, can solve problems such as high cost of mapping development work, complex functions, complex models, etc., and achieve the effect of reducing the workload of mapping development and maintenance
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0059] See Figure 4 As shown, the embodiment of the present invention provides a method for realizing the mapping of a YANG model to an internal model, including the following steps:
[0060] S10: Use the extended private mapping statement in the YANG model text file to support the mapping from the YANG model to the internal model (internal model) during the development phase;
[0061] S20, when the internal model engine is started, the internal model is loaded, and internal model classes and internal model elements are established in the memory;
[0062] S30, when Netconf is started, load the YANG model, and build the YANG model tree in the memory; analyze the private mapping information to establish the mapping relationship between the YANG model and internal model classes and internal model elements;
[0063] The method provided by the embodiment of the present invention further includes the following steps:
[0064] S40: After Netconf receives the YANG configuration of the network ...
Embodiment 2
[0067] On the basis of Embodiment 1, S10 specifically includes the following steps:
[0068] Step S101, use the extension statement in the YANG model to define the extended private mapping statement fosv4-ext-map; an example is as follows:
[0069]
[0070] Step S102, use the extended private mapping statement in the YANG list or container to map a list or container to an internal model class; an example is as follows:
[0071] list instance{
[0072] fosv4-ext-map "ISIS";
[0073] }
[0074] Step S103, the leaf node under the YANG list or container uses an extended private mapping statement to map a leaf node under the list or container to an internal model element. Examples are as follows:
[0075] leaf instance-name{
[0076] fosv4-ext-map "ISIS:instance_id";
[0077] }
[0078] The following is the content of the ISIS model after using extension. Note: To simplify the description, there are a lot of cuts:
[0079]
[0080]
[0081]
Embodiment 3
[0083] On the basis of Embodiment 1, S30 specifically includes the following steps:
[0084] Step S301, load the YANG model when Netconf is started, and construct the YANG model tree;
[0085] Step S302: Parse the extended private mapping statement mapped to the internal model class under the list or container, search for the corresponding internal model class according to the internal model class name, and store the found internal model class in the list or container in the YANG model tree;
[0086] Step S303, parse the extended private mapping statement mapped to the internal model element under the leaf node, first search for the corresponding internal model class according to the internal model class name, then find the corresponding internal model element according to the internal model element name, and store the found internal model element Under the leaf node in the YANG model tree;
[0087] Step S304: Iterate the YANG model tree so that each child internal model class inherit...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com