WebDev
This commit is contained in:
parent
99634aba7e
commit
a7c5929537
3
.gitignore
vendored
3
.gitignore
vendored
@ -46,3 +46,6 @@
|
||||
/Semester 2/Assignments/MP2_BusinessLogic_CalebFontenot/target/
|
||||
/Semester 2/lab_EL5_CalebFontenot/target/
|
||||
|
||||
/Semester 2/labJuneau_CalebFontenot/target/
|
||||
/Semester 2/Assignments/LabJeaneauMessagesValidation_CalebFontenot/target/
|
||||
/Semester 2/LabJuneauValidateUserInput_CalebFontenot/target/
|
||||
|
@ -0,0 +1,84 @@
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>edu.slcc.asdv.caleb</groupId>
|
||||
<artifactId>LabJeaneauMessagesValidation_CalebFontenot</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
<packaging>war</packaging>
|
||||
<name>LabJeaneauMessagesValidation_CalebFontenot-1.0-SNAPSHOT</name>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>11</maven.compiler.source>
|
||||
<maven.compiler.target>11</maven.compiler.target>
|
||||
<endorsed.dir>${project.build.directory}/endorsed</endorsed.dir>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<failOnMissingWebXml>false</failOnMissingWebXml>
|
||||
<jakartaee>10.0.0</jakartaee>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<!-- https://mvnrepository.com/artifact/org.primefaces/primefaces -->
|
||||
<dependency>
|
||||
<groupId>org.primefaces</groupId>
|
||||
<artifactId>primefaces</artifactId>
|
||||
<version>10.0.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>jakarta.platform</groupId>
|
||||
<artifactId>jakarta.jakartaee-api</artifactId>
|
||||
<version>${jakartaee}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.8.1</version>
|
||||
<configuration>
|
||||
<source>11</source>
|
||||
<target>11</target>
|
||||
<compilerArguments>
|
||||
<endorseddirs>${endorsed.dir}</endorseddirs>
|
||||
</compilerArguments>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-war-plugin</artifactId>
|
||||
<version>2.3</version>
|
||||
<configuration>
|
||||
<failOnMissingWebXml>false</failOnMissingWebXml>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-dependency-plugin</artifactId>
|
||||
<version>2.6</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<phase>validate</phase>
|
||||
<goals>
|
||||
<goal>copy</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<outputDirectory>${endorsed.dir}</outputDirectory>
|
||||
<silent>true</silent>
|
||||
<artifactItems>
|
||||
<artifactItem>
|
||||
<groupId>jakarta.platform</groupId>
|
||||
<artifactId>jakarta.jakartaee-api</artifactId>
|
||||
<version>${jakartaee}</version>
|
||||
<type>jar</type>
|
||||
</artifactItem>
|
||||
</artifactItems>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
@ -0,0 +1,13 @@
|
||||
package edu.slcc.asdv.caleb.labjeaneaumessagesvalidation_calebfontenot;
|
||||
|
||||
import jakarta.ws.rs.ApplicationPath;
|
||||
import jakarta.ws.rs.core.Application;
|
||||
|
||||
/**
|
||||
* Configures Jakarta RESTful Web Services for the application.
|
||||
* @author Juneau
|
||||
*/
|
||||
@ApplicationPath("resources")
|
||||
public class JakartaRestConfiguration extends Application {
|
||||
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package edu.slcc.asdv.caleb.labjeaneaumessagesvalidation_calebfontenot.resources;
|
||||
|
||||
import jakarta.ws.rs.GET;
|
||||
import jakarta.ws.rs.Path;
|
||||
import jakarta.ws.rs.core.Response;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author
|
||||
*/
|
||||
@Path("jakartaee10")
|
||||
public class JakartaEE10Resource {
|
||||
|
||||
@GET
|
||||
public Response ping(){
|
||||
return Response
|
||||
.ok("ping Jakarta EE")
|
||||
.build();
|
||||
}
|
||||
}
|
@ -0,0 +1,26 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html"
|
||||
xmlns:p="http://primefaces.org/ui">
|
||||
<h:body>
|
||||
<h:form id="componentForm">
|
||||
<p:growl id="globalgrowl" showDetail="false"
|
||||
showSummary="true" life="200"/>
|
||||
<h1>JSF Messages</h1>
|
||||
<p>
|
||||
This page contains a JSF message component below. It will display
|
||||
messages from a JSF managed bean once the bean has been initialized.
|
||||
</p>
|
||||
<h:messages errorStyle="color: red" infoStyle="color: green" globalOnly="true"/>
|
||||
<br/>
|
||||
<br/>
|
||||
Enter the word Java here:
|
||||
<h:inputText id="javaText" value="#{messageController.javaText}"/>
|
||||
<h:message for="javaText" errorStyle="color: red" infoStyle="color: green"/>
|
||||
<br/><br/>
|
||||
<h:commandButton id="addMessage" action="#{messageController.newMessage}"
|
||||
value="New Message"/>
|
||||
</h:form>
|
||||
</h:body>
|
||||
</html>
|
Binary file not shown.
@ -0,0 +1,11 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html">
|
||||
<h:head>
|
||||
<title>Facelet Title</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
<h3>Testing Locale Changed<h3>
|
||||
</h:body>
|
||||
</html>
|
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="https://jakarta.ee/xml/ns/jakartaee"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="https://jakarta.ee/xml/ns/jakartaee https://jakarta.ee/xml/ns/jakartaee/beans_4_0.xsd"
|
||||
bean-discovery-mode="all">
|
||||
</beans>
|
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<persistence version="3.0" xmlns="https://jakarta.ee/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://jakarta.ee/xml/ns/persistence https://jakarta.ee/xml/ns/persistence/persistence_3_0.xsd">
|
||||
<!-- Define Persistence Unit -->
|
||||
<persistence-unit name="my_persistence_unit">
|
||||
|
||||
</persistence-unit>
|
||||
</persistence>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,11 @@
|
||||
|
||||
# Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
|
||||
# Click nbfs://nbhost/SystemFileSystem/Templates/Other/properties.properties to edit this template
|
||||
currentLocale=Current Locale: English
|
||||
title=NumberQuiz
|
||||
heading=Have fun with NumberQuiz!
|
||||
currentScore=Your current score is {0}.
|
||||
guessNext=Guess the next number in the sequence!
|
||||
answer=Your answer:
|
||||
next=Next
|
||||
changeLocale=Change Locale
|
@ -0,0 +1,8 @@
|
||||
currentLocale=Aktuelles Gebietsschema: Deutsch
|
||||
title=Zahlenquiz
|
||||
heading=Viel Spa\u00df mit dem Zahlenquiz!
|
||||
currentScore=Sie haben {0,choice,0#0 Punkte|1#einen Punkt|2#{0} Punkte}.
|
||||
guessNext=Raten Sie die n\u00e4chste Zahl in der Folge!
|
||||
answer=Ihre Antwort:
|
||||
next=Weiter
|
||||
changeLocale=Gebietsschema \u00e4ndern
|
@ -0,0 +1,11 @@
|
||||
|
||||
# Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
|
||||
# Click nbfs://nbhost/SystemFileSystem/Templates/Other/properties.properties to edit this template
|
||||
currentLocale=Ubicaci\u00f3n actual: espa\u00f1ol
|
||||
title=Cuestionario de n\u00fameros
|
||||
heading=\u00a1Divi\u00e9rtete con NumberQuiz!
|
||||
currentScore=Su puntuaci\u00f3n actual es {0}.
|
||||
guessNext=\u00a1Adivina el siguiente n\u00famero en la secuencia!
|
||||
answer=Tu respuesta:
|
||||
next=Siguiente
|
||||
changeLocale=Cambiar localidad
|
@ -0,0 +1,18 @@
|
||||
<?xml version="1.0"?>
|
||||
<faces-config xmlns="http://java.sun.com/xml/ns/javaee"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
|
||||
http://java.sun.com/xml/ns/javaee/web-facesconfig_2_0.xsd"
|
||||
version="2.0">
|
||||
<application>
|
||||
<locale-config>
|
||||
<default-locale>en</default-locale>
|
||||
<supported-locale>de</supported-locale>
|
||||
<supported-locale>es</supported-locale>
|
||||
</locale-config>
|
||||
<resource-bundle>
|
||||
<base-name>messages.messages</base-name>
|
||||
<var>msgs</var>
|
||||
</resource-bundle>
|
||||
</application>
|
||||
</faces-config>
|
@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright (c) 1997, 2018 Oracle and/or its affiliates. All rights reserved.
|
||||
|
||||
This program and the accompanying materials are made available under the
|
||||
terms of the Eclipse Public License v. 2.0, which is available at
|
||||
http://www.eclipse.org/legal/epl-2.0.
|
||||
|
||||
This Source Code may also be made available under the following Secondary
|
||||
Licenses when the conditions for such availability set forth in the
|
||||
Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
|
||||
version 2 with the GNU Classpath Exception, which is available at
|
||||
https://www.gnu.org/software/classpath/license.html.
|
||||
|
||||
SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
||||
-->
|
||||
<!DOCTYPE glassfish-web-app PUBLIC "-//GlassFish.org//DTD GlassFish Application Server 3.1 Servlet 3.0//EN" "http://glassfish.org/dtds/glassfish-web-app_3_0-1.dtd">
|
||||
<glassfish-web-app error-url="">
|
||||
<class-loader delegate="true"/>
|
||||
<jsp-config>
|
||||
<property name="keepgenerated" value="true">
|
||||
<description>Keep a copy of the generated servlet class' java code.</description>
|
||||
</property>
|
||||
</jsp-config>
|
||||
</glassfish-web-app>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="http://java.sun.com/xml/ns/javaee"
|
||||
xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
|
||||
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
|
||||
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
|
||||
version="2.5">
|
||||
<servlet>
|
||||
<servlet-name>Faces Servlet</servlet-name>
|
||||
<servlet-class>jakarta.faces.webapp.FacesServlet</servlet-class>
|
||||
</servlet>
|
||||
<servlet-mapping>
|
||||
<servlet-name>Faces Servlet</servlet-name>
|
||||
<url-pattern>/faces/*</url-pattern>
|
||||
</servlet-mapping>
|
||||
<welcome-file-list>
|
||||
<welcome-file>faces/index.xhtml</welcome-file>
|
||||
</welcome-file-list>
|
||||
<context-param>
|
||||
<param-name>jakarta.faces.PROJECT_STAGE</param-name>
|
||||
<param-value>Development</param-value>
|
||||
</context-param>
|
||||
</web-app>
|
@ -0,0 +1,30 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:f="http://java.sun.com/jsf/core"
|
||||
xmlns:h="http://java.sun.com/jsf/html">
|
||||
<h:head>
|
||||
<title>#{msgs.title}</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
<h:form>
|
||||
<h3>#{msgs.heading}</h3>
|
||||
<p>
|
||||
<h:outputFormat value="#{msgs.currentScore}">
|
||||
<f:param value="#{quizBean.score}"/>
|
||||
</h:outputFormat>
|
||||
</p>
|
||||
<p>#{msgs.guessNext}</p>
|
||||
<p>#{quizBean.current.sequence}</p>
|
||||
<p>
|
||||
#{msgs.answer}
|
||||
<h:inputText value="#{quizBean.answer}"/>
|
||||
</p>
|
||||
<p><h:commandButton value="#{msgs.next}"/></p>
|
||||
</h:form>
|
||||
<h:form>
|
||||
<label>#{msgs.currentLocale} </label> <h:commandButton value="#{msgs.changeLocale}" action="#{quizBean.setLanguage}"/>
|
||||
</h:form>
|
||||
</h:body>
|
||||
</html>
|
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<persistence version="3.0" xmlns="https://jakarta.ee/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://jakarta.ee/xml/ns/persistence https://jakarta.ee/xml/ns/persistence/persistence_3_0.xsd">
|
||||
<!-- Define Persistence Unit -->
|
||||
<persistence-unit name="my_persistence_unit">
|
||||
|
||||
</persistence-unit>
|
||||
</persistence>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,11 @@
|
||||
|
||||
# Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
|
||||
# Click nbfs://nbhost/SystemFileSystem/Templates/Other/properties.properties to edit this template
|
||||
currentLocale=Current Locale: English
|
||||
title=NumberQuiz
|
||||
heading=Have fun with NumberQuiz!
|
||||
currentScore=Your current score is {0}.
|
||||
guessNext=Guess the next number in the sequence!
|
||||
answer=Your answer:
|
||||
next=Next
|
||||
changeLocale=Change Locale
|
@ -0,0 +1,8 @@
|
||||
currentLocale=Aktuelles Gebietsschema: Deutsch
|
||||
title=Zahlenquiz
|
||||
heading=Viel Spa\u00df mit dem Zahlenquiz!
|
||||
currentScore=Sie haben {0,choice,0#0 Punkte|1#einen Punkt|2#{0} Punkte}.
|
||||
guessNext=Raten Sie die n\u00e4chste Zahl in der Folge!
|
||||
answer=Ihre Antwort:
|
||||
next=Weiter
|
||||
changeLocale=Gebietsschema \u00e4ndern
|
@ -0,0 +1,11 @@
|
||||
|
||||
# Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
|
||||
# Click nbfs://nbhost/SystemFileSystem/Templates/Other/properties.properties to edit this template
|
||||
currentLocale=Ubicaci\u00f3n actual: espa\u00f1ol
|
||||
title=Cuestionario de n\u00fameros
|
||||
heading=\u00a1Divi\u00e9rtete con NumberQuiz!
|
||||
currentScore=Su puntuaci\u00f3n actual es {0}.
|
||||
guessNext=\u00a1Adivina el siguiente n\u00famero en la secuencia!
|
||||
answer=Tu respuesta:
|
||||
next=Siguiente
|
||||
changeLocale=Cambiar localidad
|
Binary file not shown.
@ -0,0 +1,5 @@
|
||||
#Generated by Maven
|
||||
#Fri Aug 25 11:22:04 CDT 2023
|
||||
groupId=edu.slcc.asdv.caleb
|
||||
artifactId=QuizBusLogic
|
||||
version=1.0-SNAPSHOT
|
@ -0,0 +1,7 @@
|
||||
com/corejsf/QuizBean.class
|
||||
com/corejsf/ProblemInterface.class
|
||||
com/corejsf/Data.class
|
||||
edu/slcc/asdv/caleb/quizbuslogic/resources/JakartaEE10Resource.class
|
||||
com/corejsf/Problem.class
|
||||
com/corejsf/DataInterface.class
|
||||
edu/slcc/asdv/caleb/quizbuslogic/JakartaRestConfiguration.class
|
@ -0,0 +1,7 @@
|
||||
/home/caleb/ASDV-WebDev/Semester 2/QuizBusLogic/src/main/java/com/corejsf/Data.java
|
||||
/home/caleb/ASDV-WebDev/Semester 2/QuizBusLogic/src/main/java/com/corejsf/DataInterface.java
|
||||
/home/caleb/ASDV-WebDev/Semester 2/QuizBusLogic/src/main/java/com/corejsf/QuizBean.java
|
||||
/home/caleb/ASDV-WebDev/Semester 2/QuizBusLogic/src/main/java/com/corejsf/ProblemInterface.java
|
||||
/home/caleb/ASDV-WebDev/Semester 2/QuizBusLogic/src/main/java/edu/slcc/asdv/caleb/quizbuslogic/resources/JakartaEE10Resource.java
|
||||
/home/caleb/ASDV-WebDev/Semester 2/QuizBusLogic/src/main/java/com/corejsf/Problem.java
|
||||
/home/caleb/ASDV-WebDev/Semester 2/QuizBusLogic/src/main/java/edu/slcc/asdv/caleb/quizbuslogic/JakartaRestConfiguration.java
|
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<persistence version="3.0" xmlns="https://jakarta.ee/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://jakarta.ee/xml/ns/persistence https://jakarta.ee/xml/ns/persistence/persistence_3_0.xsd">
|
||||
<!-- Define Persistence Unit -->
|
||||
<persistence-unit name="my_persistence_unit">
|
||||
|
||||
</persistence-unit>
|
||||
</persistence>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="https://jakarta.ee/xml/ns/jakartaee"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="https://jakarta.ee/xml/ns/jakartaee https://jakarta.ee/xml/ns/jakartaee/beans_4_0.xsd"
|
||||
bean-discovery-mode="all">
|
||||
</beans>
|
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<persistence version="3.0" xmlns="https://jakarta.ee/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://jakarta.ee/xml/ns/persistence https://jakarta.ee/xml/ns/persistence/persistence_3_0.xsd">
|
||||
<!-- Define Persistence Unit -->
|
||||
<persistence-unit name="my_persistence_unit">
|
||||
|
||||
</persistence-unit>
|
||||
</persistence>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,57 @@
|
||||
<?xml version='1.0' encoding='UTF-8'?>
|
||||
<!--
|
||||
|
||||
Licensed to the Apache Software Foundation (ASF) under one
|
||||
or more contributor license agreements. See the NOTICE file
|
||||
distributed with this work for additional information
|
||||
regarding copyright ownership. The ASF licenses this file
|
||||
to you under the Apache License, Version 2.0 (the
|
||||
"License"); you may not use this file except in compliance
|
||||
with the License. You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing,
|
||||
software distributed under the License is distributed on an
|
||||
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, either express or implied. See the License for the
|
||||
specific language governing permissions and limitations
|
||||
under the License.
|
||||
|
||||
-->
|
||||
<faces-config version="4.0"
|
||||
xmlns="https://jakarta.ee/xml/ns/jakartaee"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="https://jakarta.ee/xml/ns/jakartaee https://jakarta.ee/xml/ns/jakartaee/web-facesconfig_4_0.xsd">
|
||||
|
||||
|
||||
<navigation-rule>
|
||||
<from-view-id>/start-page-1.xhtml</from-view-id>
|
||||
|
||||
<navigation-case>
|
||||
<from-outcome>too-short</from-outcome>
|
||||
<to-view-id>error-message.xhtml</to-view-id>
|
||||
</navigation-case>
|
||||
|
||||
<navigation-case>
|
||||
<from-outcome>page1</from-outcome>
|
||||
<to-view-id>result-page-1.xhtml</to-view-id>
|
||||
</navigation-case>
|
||||
|
||||
<navigation-case>
|
||||
<from-outcome>page2</from-outcome>
|
||||
<to-view-id>result-page-2.xhtml</to-view-id>
|
||||
</navigation-case>
|
||||
|
||||
<navigation-case>
|
||||
<from-outcome>page3</from-outcome>
|
||||
<to-view-id>result-page-3.xhtml</to-view-id>
|
||||
</navigation-case>
|
||||
|
||||
</navigation-rule>
|
||||
<managed-bean>
|
||||
<managed-bean-name>messageHandler</managed-bean-name>
|
||||
<managed-bean-class>edu.slcc.asdv.beans.SimpleController2</managed-bean-class>
|
||||
<managed-bean-scope>request</managed-bean-scope>
|
||||
</managed-bean>
|
||||
</faces-config>
|
@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright (c) 1997, 2018 Oracle and/or its affiliates. All rights reserved.
|
||||
|
||||
This program and the accompanying materials are made available under the
|
||||
terms of the Eclipse Public License v. 2.0, which is available at
|
||||
http://www.eclipse.org/legal/epl-2.0.
|
||||
|
||||
This Source Code may also be made available under the following Secondary
|
||||
Licenses when the conditions for such availability set forth in the
|
||||
Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
|
||||
version 2 with the GNU Classpath Exception, which is available at
|
||||
https://www.gnu.org/software/classpath/license.html.
|
||||
|
||||
SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
||||
-->
|
||||
<!DOCTYPE glassfish-web-app PUBLIC "-//GlassFish.org//DTD GlassFish Application Server 3.1 Servlet 3.0//EN" "http://glassfish.org/dtds/glassfish-web-app_3_0-1.dtd">
|
||||
<glassfish-web-app error-url="">
|
||||
<class-loader delegate="true"/>
|
||||
<jsp-config>
|
||||
<property name="keepgenerated" value="true">
|
||||
<description>Keep a copy of the generated servlet class' java code.</description>
|
||||
</property>
|
||||
</jsp-config>
|
||||
</glassfish-web-app>
|
@ -0,0 +1,24 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<web-app version="6.0" xmlns="https://jakarta.ee/xml/ns/jakartaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://jakarta.ee/xml/ns/jakartaee https://jakarta.ee/xml/ns/jakartaee/web-app_6_0.xsd">
|
||||
<context-param>
|
||||
<param-name>jakarta.faces.PROJECT_STAGE</param-name>
|
||||
<param-value>Development</param-value>
|
||||
</context-param>
|
||||
<servlet>
|
||||
<servlet-name>Faces Servlet</servlet-name>
|
||||
<servlet-class>jakarta.faces.webapp.FacesServlet</servlet-class>
|
||||
<load-on-startup>1</load-on-startup>
|
||||
</servlet>
|
||||
<servlet-mapping>
|
||||
<servlet-name>Faces Servlet</servlet-name>
|
||||
<url-pattern>/faces/*</url-pattern>
|
||||
</servlet-mapping>
|
||||
<session-config>
|
||||
<session-timeout>
|
||||
30
|
||||
</session-timeout>
|
||||
</session-config>
|
||||
<welcome-file-list>
|
||||
<welcome-file>faces/index.xhtml</welcome-file>
|
||||
</welcome-file-list>
|
||||
</web-app>
|
@ -0,0 +1,13 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html">
|
||||
<h:head>
|
||||
<title>Facelet Title</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
#{simpleController} <br/>
|
||||
<h1>Error Message Page</h1>
|
||||
<h2>Message is too short</h2>
|
||||
</h:body>
|
||||
</html>
|
@ -0,0 +1,14 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html">
|
||||
<h:head>
|
||||
<title>Explicit Navigation</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
<h:form>
|
||||
<h:commandLink value = "Go to start-page-1" action = "start-page-1"></h:commandLink> <br/>
|
||||
<h:commandLink value = "Go to start-page-2" action = "start-page-2"></h:commandLink>
|
||||
</h:form>
|
||||
</h:body>
|
||||
</html>
|
@ -0,0 +1,13 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html">
|
||||
<h:head>
|
||||
<title>Result Page 1</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
#{simpleController} <br/>
|
||||
<h1>Result Page 1</h1>
|
||||
<h2>Your Message: "#{simpleController.getMessage()}"</h2>
|
||||
</h:body>
|
||||
</html>
|
@ -0,0 +1,13 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html">
|
||||
<h:head>
|
||||
<title>Result Page 2</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
#{simpleController} <br/>
|
||||
<h1>Result Page 2</h1>
|
||||
<h2>Your Message: "#{simpleController.getMessage()}"</h2>
|
||||
</h:body>
|
||||
</html>
|
@ -0,0 +1,13 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html">
|
||||
<h:head>
|
||||
<title>Result Page 3</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
#{simpleController} <br/>
|
||||
<h1>Result Page 3</h1>
|
||||
<h2>Your Message: "#{simpleController.getMessage()}"</h2>
|
||||
</h:body>
|
||||
</html>
|
@ -0,0 +1,17 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html">
|
||||
<h:head>
|
||||
<title>Facelet Title</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
<h:form>
|
||||
#{simpleController} <br/>
|
||||
Your Message:
|
||||
<h:inputText value="#{simpleController.message}"></h:inputText>
|
||||
<br/>
|
||||
<h:commandButton value="Show Results" action ="#{simpleController.doNavigation}"></h:commandButton>
|
||||
</h:form>
|
||||
</h:body>
|
||||
</html>
|
@ -0,0 +1,17 @@
|
||||
<?xml version='1.0' encoding='UTF-8' ?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"
|
||||
xmlns:h="http://xmlns.jcp.org/jsf/html">
|
||||
<h:head>
|
||||
<title>Facelet Title</title>
|
||||
</h:head>
|
||||
<h:body>
|
||||
<h:form>
|
||||
#{messageHandler} <br/>
|
||||
Your Message:
|
||||
<h:inputText value="#{messageHandler.message}"></h:inputText>
|
||||
<br/>
|
||||
<h:commandButton value="Show Results" action ="#{messageHandler.doNavigation}"></h:commandButton>
|
||||
</h:form>
|
||||
</h:body>
|
||||
</html>
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user