ujiall.tldなどのタグライブラリディスクリプタを使用する場合、Webアプリケーションを配置したディレクトリーにコピーして使用せず、Apcoordinatorインストールフォルダにあるものを直接使用することができます。
この場合、Webアプリケーション環境定義ファイル(web.xml)のtaglib-location要素で、タグライブラリディスクリプタの場所を絶対パスで指定します。絶対パスで指定するには、"file:///"で始まるURLを使用します。Windowsの場合、"file:///ドライブ文字:/"がルートディレクトリーを表します。
<?xml version="1.0" encoding="UTF-8"?> <web-app xmlns=http://java.sun.com/xml/ns/j2ee xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd version="2.4"> <context-param> <param-name>factory</param-name> <param-value>sample2.Sample2Factory</param-value> </context-param> <jsp-config> <taglib>
<taglib-uri>uji-taglib</taglib-uri>
<taglib-location>file:///c:/APC/lib/ujiall.tld</taglib-location>
</taglib> </jsp-config> </web-app>
Solaris, Linuxの場合、"file:///"がルートディレクトリーを表します。
.... <web-app xmlns=http://java.sun.com/xml/ns/j2ee xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd version="2.4"> .... <jsp-config> <taglib>
<taglib-uri>uji-taglib</taglib-uri>
<taglib-location>file:///opt/FJSVwebc/lib/ujiall.tld</taglib-location>
</taglib> </jsp-config> </web-app>
関連項目