[shrinkwrap-issues] [JBoss JIRA] Commented: (SHRINKDESC-37) Should set schemaLocation for all Descriptors
Aslak Knutsen (JIRA)
jira-events at lists.jboss.org
Wed Mar 9 08:28:45 EST 2011
[ https://issues.jboss.org/browse/SHRINKDESC-37?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12586840#comment-12586840 ]
Aslak Knutsen commented on SHRINKDESC-37:
-----------------------------------------
since a descriptor needs a version and schemaLocation is effected by the version. version() could handle the setting of schemaLocation. This will prevent schemaLocation being out of sync with the set version.
{code}
public WebAppDescriptorImpl()
{
this(new Node("web-app")
.attribute("xmlns", "http://java.sun.com/xml/ns/javaee")
.attribute("xmlns:xsi", "http://www.w3.org/2001/XMLSchema-instance"));
version("3.0");
}
@Override
public WebAppDescriptor version(String version)
{
model.attribute(
"xsi:schemaLocation",
"http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_" + version.replace(".", "_") + ".xsd");
model.attribute("version", version);
return this;
}
{code}
> Should set schemaLocation for all Descriptors
> ---------------------------------------------
>
> Key: SHRINKDESC-37
> URL: https://issues.jboss.org/browse/SHRINKDESC-37
> Project: ShrinkWrap Descriptors
> Issue Type: Feature Request
> Reporter: Aslak Knutsen
>
> schemaLocation should be added to all Descriptors: BeansXml, Persistence, App
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the shrinkwrap-issues
mailing list