How mkkz7/web-lab3 works
This appears to be a JSF web app for plotting coordinate points and checking whether they fall within a selectable area, with results displayed in a table. The visible browser workflow draws the region, converts a canvas click to coordinates, and submits them; the Java tree indicates corresponding controller, checking, and persistence layers, though their call relationships are not shown in the supplied excerpts. The app also includes a clock and syntax-highlighting components. Backend links are omitted where source evidence is unavailable.
Main entry points: main.js Graph interaction · index.js Clock updater · utils.js Clock utility
Components 22
Web interface
- Point page
src/main/webApp/main.xhtml - Graph interaction
src/main/webApp/resources/scripts/main.js - Coordinate submission
Point checking
- Page controller
src/main/java/org/example/mbeans/ControllerBean.java - Area check
src/main/java/org/example/mbeans/AreaCheckBean.java - Area checker
src/main/java/org/example/utils/AreaChecker.java - Y validation
src/main/java/org/example/utils/ValidatorY.java - Coordinate data
src/main/java/org/example/entities/CoordinateBean.java
Result persistence
- Result entity
src/main/java/org/example/entities/Results.java - Result DAO
src/main/java/org/example/db/ResultDAO.java - Database
Additional features
- Landing page
src/main/webApp/index.xhtml - Clock updater
src/main/webApp/resources/scripts/index.js - Clock utility
src/main/webApp/resources/scripts/utils.js - Highlight view
src/main/webApp/resources/highlight/highlight.xhtml - Highlight component
src/main/java/org/example/tags/HighlightTagComponent.java - Syntax parser
src/main/java/org/example/tags/JavaSyntaxHighlighterParser.java - Parser interface
src/main/java/org/example/tags/SyntaxHighlighterParser.java - Code input bean
src/main/java/org/example/tags/StringCodeToHighlightBean.java - Clock bean
src/main/java/org/example/mbeans/ClockBean.java - Service bean
src/main/java/org/example/mbeans/ServiceBean.java
Other components
- User
Connections 3
- User → Graph interaction: clicks canvas
src/main/webApp/resources/scripts/main.js - Graph interaction → Coordinate submission: sends coordinates
src/main/webApp/resources/scripts/main.js - Clock updater → Clock utility: imports updater
src/main/webApp/resources/scripts/index.js