| <?xml version="1.0"?> |
| <!-- |
| 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 |
| |
| https://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. |
| --> |
| <project name="test" xmlns:other="this is the other uri" |
| other:attr="this should be ignored by ant"> |
| |
| <path id="testclasses"> |
| <pathelement path="${java.class.path}"/> |
| </path> |
| |
| <target name="xmlns" xmlns:test="this.is.another.test.uri"> |
| <typedef classname="org.apache.tools.ant.taskdefs.XmlnsTest$MyTask" |
| classpathref="testclasses" |
| name="mytask" |
| uri="this.is.another.test.uri"/> |
| <test:mytask/> |
| </target> |
| |
| <target name="other" other:a="this is another attribute"> |
| <echo other:g="abc" message="a message"/> |
| </target> |
| |
| <target name="ns.attributes"> |
| <taskdef name="my.echo" classname="org.apache.tools.ant.taskdefs.Echo" |
| uri="x-uri"/> |
| <x:my.echo x:message="hello world" xmlns:x="x-uri"/> |
| </target> |
| |
| <target name="xmlns.file" xmlns:test="this.is.a.test.uri"> |
| <typedef file="test.antlib.xml" |
| classpathref="testclasses" |
| uri="this.is.a.test.uri"/> |
| <test:mytask/> |
| </target> |
| |
| <target name="core"> |
| <typedef file="test.antlib.xml" |
| classpathref="testclasses" |
| uri="antlib:org.apache.tools.ant"/> |
| <mytask/> |
| </target> |
| |
| <target name="excluded"> |
| <typedef file="test.antlib.xml" |
| classpathref="testclasses" |
| uri="ant:notallowed"/> |
| </target> |
| </project> |