Interface Generation from Data Models Preserving Type Safety

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current application programming models lack efficient mechanisms for generating strongly-typed interfaces from human-readable data and service definitions, which are essential for seamless integration with development environments and execution in runtime environments, particularly when transitioning between strongly-typed and weakly-typed programming languages.

Innovation Solution

A system that receives human-readable data model definitions, generates machine-readable representations, and produces interfaces in a strongly-typed programming language, which can be transcompiled to a weakly-typed language for server-side execution, enabling design-time implementation and deployment to databases, while providing façade interfaces and namespaces for service entities.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If interfaces are generated from human-readable data model definitions using automated programs, then productivity is improved, but manufacturing precision deteriorates due to loss of type safety information

Engineering Contradiction:
Improveinterface generation efficiencyVSAvoidtype safety preservation
Core Design Contradiction:
ProductivityVSManufacturing precision

Solution Approach 1:

The patent introduces an intermediary program that acts as a mediator between the human-readable data model definition and the target programming language. This intermediary automatically generates interfaces while preserving type safety information, resolving the contradiction by maintaining precision during the automated generation process.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The patent performs preliminary actions by pre-defining data models with explicit type information before code generation. This allows the interface generation process to inherit type safety from the pre-defined models, ensuring precision is maintained even during automated productivity-enhancing operations.

Inventive Principle:
Principle #10Preliminary action

2Manufacturing precision

If strongly-typed programming languages are used for interface definition, then manufacturing precision is improved, but ease of operation deteriorates due to stricter typing requirements

Engineering Contradiction:
Improveinterface type safetyVSAvoiddevelopment flexibility
Core Design Contradiction:
Manufacturing precisionVSEase of operation

Solution Approach 1:

The patent creates copies of type information from the data model definitions into the generated interfaces. This allows strongly-typed interfaces to be automatically generated without requiring developers to manually write complex type definitions, thus maintaining precision while improving ease of operation through automation.

Inventive Principle:
Principle #26Copying

Solution Approach 2:

Type information is preliminarily defined in the human-readable data models, so that when interfaces are generated, the type safety is automatically inherited. This preliminary preparation eliminates the need for developers to manually handle complex typing, improving ease of operation while maintaining manufacturing precision.

Inventive Principle:
Principle #10Preliminary action

3Adaptability or versatility

If transcompilation from strongly-typed to weakly-typed languages is performed, then adaptability is improved, but manufacturing precision deteriorates due to type information loss

Engineering Contradiction:
Improvecross-language compatibilityVSAvoidtype information preservation
Core Design Contradiction:
Adaptability or versatilityVSManufacturing precision

Solution Approach 1:

The patent uses an intermediary transcompilation process that preserves type information when translating from strongly-typed to weakly-typed languages. This intermediary layer ensures that type safety is not lost during cross-language translation, resolving the contradiction between adaptability and precision.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

Type information is copied and embedded in the transcompiled code or preserved through metadata, allowing the weakly-typed target language to maintain the type safety characteristics of the strongly-typed source language, thus preserving manufacturing precision while achieving adaptability.

Inventive Principle:
Principle #26Copying

Data Source

PatentUS11093220B2Generating interfaces from data and service definitions for developing applications
Publication Date: 2021.08.17 SAP SE
  • US11093220B2 patent drawing
  • US11093220B2 patent drawing
  • US11093220B2 patent drawing

AI summary

Some embodiments provide a non-transitory machine-readable medium that stores a program. The program receives a data model definition defined using a human-readable syntax. The program further generates a machine-readable representation of the data model definition. Based on the data model definition, the program also generates a set of interfaces from the machine-readable representation of the data model definition. Each interface in the set of interfaces includes code specified in a programming language. The program further provides the set of interfaces to an integrated development environment (IDE) application for design-time implementation of the set of interfaces.