JSF Composite Component Generation via Node Tree Hashing

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current Java Server Faces (JSF) technologies do not allow for the generation of composite components without pre-designing a tag library, leading to inefficient web application development and maintenance due to the need for extensive cutting and pasting of page parts.

Innovation Solution

A method and system for generating intelligent JSF composite components by identifying facelet files, creating a node tree, computing hashes, and comparing node lists to save matched lists as composite components, allowing users to select and convert repetitive page segments into composite components, thereby creating a new or updating an existing tag library.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Adaptability or versatility

If composite components are generated without pre-designing a tag library, then development flexibility and ease of maintenance are improved, but the current JSF system does not support this capability

Engineering Contradiction:
Improveability to generate composite components without tag libraryVSAvoidsystem complexity for automatic component generation
Core Design Contradiction:
Adaptability or versatilityVSDevice complexity

Solution Approach 1:

The system performs preliminary analysis of facelet files to identify duplicate page segments before component generation. By pre-processing the facelet files to create node trees and compute hashes, the system prepares the data structure needed for automatic composite component creation, enabling flexibility without requiring pre-designed tag libraries.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system enables facelet files to serve themselves by automatically identifying duplicate segments and generating composite components from them. The facelet files contain embedded metadata that allows the system to self-identify reusable patterns without external intervention or pre-defined tag library specifications.

Inventive Principle:
Principle #25Self-service

2Productivity

If users manually create and maintain composite components through cutting and pasting, then component reusability is achieved, but development time and maintenance effort increase significantly

Engineering Contradiction:
Improvedevelopment efficiencyVSAvoidtime for cleanup and maintenance
Core Design Contradiction:
ProductivityVSLoss of time

Solution Approach 1:

The system computes hash values for node trees representing page segments and uses these hashes to identify duplicate segments across facelet files. This feedback mechanism automatically detects reusability patterns, allowing the system to propose composite component candidates without manual intervention, thereby reducing development time and maintenance effort.

Inventive Principle:
Principle #23Feedback

Solution Approach 2:

The system creates composite components by copying identified duplicate page segments into reusable component definitions. By automatically detecting and copying identical node tree structures, the system eliminates manual cutting and pasting operations, significantly improving productivity while reducing the time needed for cleanup and maintenance.

Inventive Principle:
Principle #26Copying

3Ease of repair

If duplicate page parts are removed through manual cleanup, then application maintainability is improved, but the complexity of identifying and removing duplicates increases

Engineering Contradiction:
Improveapplication maintainabilityVSAvoidcomplexity of duplicate identification process
Core Design Contradiction:
Ease of repairVSDevice complexity

Solution Approach 1:

The system replaces manual mechanical processes of identifying and removing duplicates with an automated computational approach. By substituting the manual mechanical system with an automated hash-based comparison system, the complexity of duplicate identification is reduced while maintainability is significantly improved.

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

Solution Approach 2:

The system changes the parameter representation of page segments from raw XML/text to computed hash values. This parameter transformation simplifies the comparison and identification of duplicate segments, making the cleanup process automated and maintainable without increasing system complexity.

Inventive Principle:
Principle #35Parameter changes

Data Source

PatentUS8875094B2System and method for implementing intelligent java server faces (JSF) composite component generation
Publication Date: 2014.10.28 ORACLE INT CORP
  • US8875094B2 patent drawing
  • US8875094B2 patent drawing
  • US8875094B2 patent drawing

AI summary

One embodiment of the invention describes a method of generating intelligent Java server faces (JSF) composite components. The method includes identifying at least one facelet file within a project, creating a node tree from the at least one facelet file, iterating through the node tree to determine which nodes are tags for composite components, and in response to determining that a plurality of nodes are tags for composite components, computing a hash for each of the plurality of nodes. The method further includes generating node lists for each of the plurality of nodes, adding the plurality of nodes and the hashes to corresponding node lists, comparing each node list against every other node list, and in response to determining a match among node lists, saving the matched node lists as composite components.