Skip to content

Commit

Permalink
Merge pull request #7539 from matthiasblaesing/jakarta_fixes2
Browse files Browse the repository at this point in the history
Further JavaEE -> JakartaEE fixes for Jakarta Faces
  • Loading branch information
matthiasblaesing authored Jul 16, 2024
2 parents 2027c7d + bc70903 commit 0d9ea57
Show file tree
Hide file tree
Showing 6 changed files with 38 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,8 @@ public boolean isCdiEnabled(){
* @return
*/
public static boolean isCdi11OrLater(Project p) {
if(! hasResource(p, "javax/enterprise/inject/spi/AfterTypeDiscovery.class") ) {
if(! (hasResource(p, "javax/enterprise/inject/spi/AfterTypeDiscovery.class")
|| hasResource(p, "jakarta/enterprise/inject/spi/AfterTypeDiscovery.class"))) {
return false;
} else {
FileObject beans = getBeansXmlExists(p);
Expand All @@ -177,7 +178,8 @@ public static boolean isCdi11OrLater(Project p) {
}

public boolean isCdi11OrLater() {
if(! hasResource(getProject(), "javax/enterprise/inject/spi/AfterTypeDiscovery.class") ) {
if (!(hasResource(getProject(), "javax/enterprise/inject/spi/AfterTypeDiscovery.class")
|| hasResource(getProject(), "jakarta/enterprise/inject/spi/AfterTypeDiscovery.class"))) {
return false;
} else {
FileObject beans = getBeansXmlExists();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,17 @@
</#if>
<?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">
<#if nsLocation?starts_with("http://")>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}/jsf/facelets"
xmlns:h="${nsLocation}/jsf/html"
xmlns:f="${nsLocation}/jsf/core">

<#else>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}.facelets"
xmlns:h="${nsLocation}.html"
xmlns:f="${nsLocation}.core">
</#if>
<ui:composition template="/template.xhtml">
<ui:define name="title">
<h:outputText value="${r"#{"}${bundle}.Create${entityName}Title${r"}"}"></h:outputText>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,15 @@
<#setting number_format="0">
<?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">
<#if nsLocation?starts_with("http://")>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}/jsf/facelets"
xmlns:h="${nsLocation}/jsf/html">

<#else>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}.facelets"
xmlns:h="${nsLocation}.html">
</#if>
<h:head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title><ui:insert name="title">Default Title</ui:insert></title>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,17 @@
</#if>
<?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">
<#if nsLocation?starts_with("http://")>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}/jsf/facelets"
xmlns:h="${nsLocation}/jsf/html"
xmlns:f="${nsLocation}/jsf/core">
<#else>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}.facelets"
xmlns:h="${nsLocation}.html"
xmlns:f="${nsLocation}.core">
</#if>

<ui:composition template="/template.xhtml">
<ui:define name="title">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,17 @@
</#if>
<?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">
<#if nsLocation?starts_with("http://")>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}/jsf/facelets"
xmlns:h="${nsLocation}/jsf/html"
xmlns:f="${nsLocation}/jsf/core">
<#else>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}.facelets"
xmlns:h="${nsLocation}.html"
xmlns:f="${nsLocation}.core">
</#if>

<ui:composition template="/template.xhtml">
<ui:define name="title">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,17 @@
</#if>
<?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">
<#if nsLocation?starts_with("http://")>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}/jsf/facelets"
xmlns:h="${nsLocation}/jsf/html"
xmlns:f="${nsLocation}/jsf/core">
<#else>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="${nsLocation}.facelets"
xmlns:h="${nsLocation}.html"
xmlns:f="${nsLocation}.core">
</#if>

<ui:composition template="/template.xhtml">
<ui:define name="title">
Expand Down

0 comments on commit 0d9ea57

Please sign in to comment.