Upload
others
View
3
Download
0
Embed Size (px)
Citation preview
Programmer’s GuideiPlanet Portal Server: Mobile Access Pack
3.0
November 2001
Copyright © 2001 Sun Microsystems, Inc. Some preexisting portions Copyright © 2001 Netscape Communications Corporation. All
rights reserved.
Sun, Sun Microsystems, and the Sun logo are trademarks or registered trademarks of Sun Microsystems, Inc. in the United States and
other countries. Netscape and the Netscape N logo are registered trademarks of Netscape Communications Corporation in the U.S.
and other countries. Other Netscape logos, product names, and service names are also trademarks of Netscape Communications
Corporation, which may be registered in other countries.
This product includes software developed by the Apache Software Foundation (http://www.apache.org/). Copyright © 1999 The
Apache Software Foundation. All right reserved.
Copyright © 2001 Worldwide Wide Web Consortium, (Massachusetts Institute of Technology, Institut National de Recherche en
Informatique et en Automatique, Keio University). All Rights reserved. http://www.w3.org/Consortium/Legal/
Copyright © 2000 World Wide Web Consortium, (Massachusetts Institute of Technology, Institut National de Recherche en
Informatique et en Automatique, Keio University). All Rights Reserved.
The DOM bindings are published under the W3C Software Copyright Notice and License. The software license requires "Notice of
any changes or modifications to the W3C files, including the date changes were made." Consequently, modified versions of the DOM
bindings must document that they do not conform to the W3C standard; in the case of the IDL binding, the pragma prefix can no
longer be ’w3c.org’; in the case of the Java binding, the package names can no longer be in the ’org.w3c’ package.
Note: The original version of the W3C Software Copyright Notice and License could be found at
http://www.w3.org/Consortium/Legal/copyright-software-19980720
Copyright © 1994-2000 World Wide Web Consortium, (Massachusetts Institute of Technology, Institut National de Recherche en
Informatique et en Automatique, Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
THIS SOFTWARE AND DOCUMENTATION IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE NO
REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF
MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE OR
DOCUMENTATION WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS.
COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES
ARISING OUT OF ANY USE OF THE SOFTWARE OR DOCUMENTATION.
The name and trademarks of copyright holders may NOT be used in advertising or publicity pertaining to the software without
specific, written prior permission. Title to copyright in this software and any associated documentation will at all times remain with
copyright holders.
Federal Acquisitions: Commercial Software—Government Users Subject to Standard License Terms and Conditions
The product described in this document is distributed under licenses restricting its use, copying, distribution, and decompilation. No
part of the product or this document may be reproduced in any form by any means without prior written authorization of the
Sun-Netscape Alliance and its licensors, if any.
THIS DOCUMENTATION IS PROVIDED “AS IS” AND ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND
WARRANTIES, INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE
OR NON-INFRINGEMENT, ARE DISCLAIMED, EXCEPT TO THE EXTENT THAT SUCH DISCLAIMERS ARE HELD TO BE
LEGALLY INVALID.
________________________________________________________________________________________
Copyright © 2001 Sun Microsystems, Inc. Pour certaines parties préexistantes, Copyright © 2001 Netscape Communication Corp.
Tous droits réservés.
Sun, Sun Microsystems, et le logo Sun sont des marques de fabrique ou des marques déposées de Sun Microsystems, Inc. aux
Etats-Unis et d’autre pays. Netscape et le logo Netscape N sont des marques déposées de Netscape Communications Corporation
aux Etats-Unis et d’autre pays. Les autres logos, les noms de produit, et les noms de service de Netscape sont des marques déposées
de Netscape Communications Corporation dans certains autres pays.
Le produit décrit dans ce document est distribué selon des conditions de licence qui en restreignent l'utilisation, la copie, la
distribution et la décompilation. Aucune partie de ce produit ni de ce document ne peut être reproduite sous quelque forme ou par
quelque moyen que ce soit sans l’autorisation écrite préalable de l’Alliance Sun-Netscape et, le cas échéant, de ses bailleurs de licence.
3
Contents
Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
Audience for This Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
What’s in This Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
How to Use This Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Other Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Documentation Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Typographic Conventions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Chapter 1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Client Awareness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Client Detection Module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Client Data Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Extensions to iPlanet Portal Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Client Specific Authentication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Wireless Desktop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
Wireless Content Providers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
File Lookup Mechanism . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Wireless Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
JSPs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
JSP Tag Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Chapter 2 Authentication Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21Authentication Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Chapter 3 Desktop Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25The Front Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
Desktop and Mobile Devices Home Page Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
The Client Configuration Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
4 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Select Mobile Devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
Add or Remove Mobile Devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
The Content Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
Select Channels For Display . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
The Layout Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
Organize Channel Layout on Devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
The Options Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
Configure Character Set for Mobile Device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
Chapter 4 Content Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41The Calendar Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
The Mail Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
The Address Book Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
The Wireless Personal Notes Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
The PostIt Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
The Wireless URL Scraper Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
The UserInfo Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
The Wireless Bookmarks Provider Template Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
Chapter 5 Application JSPs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
iPlanet Calendar Server JSPs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
User Interface Flowcharts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
JSP Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Sample Customizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
iPlanet Messaging Server JSPs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
User Interface Flowcharts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
JSP Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
Sample Customizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
Personal Address Book JSPs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78
User Interface Flowcharts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78
JSP Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
Sample Customizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
Chapter 6 JSP Tag Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Tag Patterns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Context Tag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Bean Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86
Collection Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86
Command Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
Content Tag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
5
Session Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
Message Catalog Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
Link Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
Tag Attribute Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
Tag Library Error Logging . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
Tag Library Quick Reference . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
Utilities Tag Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
context . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
link . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
attr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
url . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
parm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
beans . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100
bean . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102
get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103
set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104
copy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106
if . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107
ifnot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108
list . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110
session . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110
catalog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112
msg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 113
content . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
edit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115
forward . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117
include . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 118
iPlanet Calendar Server Client Tag Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
context . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
fetch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 120
store . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121
delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
dateformat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
dateroll . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 126
datetime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127
event . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129
events . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131
get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133
set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134
iPlanet Messaging Server Client Tag Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135
context . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135
fetch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136
6 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
sendmessage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139
deletemessage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140
folder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141
folders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142
message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 147
line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 149
lines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 150
presetmsg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152
presetmsgs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152
get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 154
set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155
Personal Address Book Client Tag Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
context . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
fetch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157
add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 159
delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 160
modify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
entry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162
entries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164
get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166
set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
Chapter 7 Tag Swapper Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171The Desktop Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171
The Calendar Provider Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 174
The Mail Provider Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177
The Address Book Provider Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179
The Wireless Personal Note Provider Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
The PostIt Note Provider Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182
The Wireless URLScraper Provider Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182
The User Information Provider Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 183
The Bookmark Provider Tags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 183
Chapter 8 Attributes and Schemas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185Attributes for HTML Clients . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
<channelName>-description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187
<channelName>-backgroundColor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187
<channelName>-hasHelp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
<channelName>-helpLink . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
<channelName>-column . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189
<channelName>-row . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189
7
<channelName>-width . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190
<channelName>-editType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190
<channelName>-isEditable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
<channelName>-hasFrame . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
<channelName>-isMovable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
<channelName>-isMinimizable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
<channelName>-isMinimized . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
<channelName>-isRemovable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
<channelName>-isDetachable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
<channelName>-isDetached . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194
<channelName>-hasBorder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194
Common Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
<channelName>-title . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
<channelName>-clientHelpLinks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 196
<channelName>-refreshTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 196
Calendar Provider Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 197
iwtCalendarProvider-calendarUserName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 198
iwtCalendarProvider-calendarUserPassword . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 198
iwtCalendarProvider-calendarServerName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199
iwtCalendarProvider-calendarServerPort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199
iwtCalendarProvider-weekView . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
iwtCalendarProvider-dayView . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
iwtCalendarProvider-clientURL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201
iwtCalendarProvider-jspLocationLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202
iwtCalendarProvider-jspDescLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202
iwtCalendarProvider-jspSummaryLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
iwtCalendarProvider-jspEventNumLines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204
Mail Provider Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204
iwtMailProvider-msgCopyInSent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206
iwtMailProvider-clientURL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206
iwtMailProvider-clientPort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207
iwtMailProvider-sortOrder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207
iwtMailProvider-displayHeaders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208
iwtMailProvider-numberHeaders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208
iwtMailProvider-predefinedReplies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 209
iwtMailProvider-signature . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 209
iwtMailProvider-changeUserInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 210
iwtMailProvider-IMAPServerName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 210
iwtMailProvider-IMAPUserId . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
iwtMailProvider-IMAPPassword . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
iwtMailProvider-jspInboxNumLines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212
iwtMailProvider-jspFromLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212
iwtMailProvider-jspSubjectLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
8 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtMailProvider-jspMsgNumLines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 214
Address Book Provider Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 214
iwtAddressBookProvider-clientURL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216
iwtAddressBookProvider-displayEntries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216
iwtAddressBookProvider-sortOrder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217
iwtAddressBookProvider-sortBy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218
iwtAddressBookProvider-numEntries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218
iwtAddressBookProvider-maxEntries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
iwtAddressBookProvider-LDAPServerName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
iwtAddressBookProvider-LDAPport . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220
iwtAddressBookProvider-LDAPAdminId . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220
iwtAddressBookProvider-LDAPAdminPassword . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 221
iwtAddressBookProvider-LDAPSearchBase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 221
iwtAddressBookProvider-IMAPServerName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222
iwtAddressBookProvider-IMAPUserId . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222
iwtAddressBookProvider-IMAPPassword . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
iwtAddressBookProvider-ldapConnPoolStart . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
iwtAddressBookProvider-ldapConnPoolMax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224
iwtAddressBookProvider-ldapOpTimeout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224
iwtAddressBookProvider-jspAbNumLines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
Bookmark Provider Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
iwtWirelessBookmarkProviderWML-targets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
iwtWirelessBookmarkProvidercHTML-targets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
XML Provider Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227
iwtXMLProvider-xslCache . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227
iwtXMLProvider-url . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 228
iwtXMLProvider-xslFileName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 228
JAXP Jar Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229
Wireless URLScraper Provider Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
iwtWirelessURLScraperProvider-url . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
iwtWirelessURLScraperProvider-showAsLink . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231
iwtWirelessURLScraperProvider-clientPresentableTo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231
iwtWirelessURLScraperProvider-urlList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
Authentication Module Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233
iwtAuth-clientDetectionClass . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234
iwtAuth-clientDetectionEnabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234
iwtAuth-supportedAuthModules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235
iwtAuth-loginWorkerClass . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
iwtAuth-loginWorkerClasses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
Client Detection Module Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237
iwtClient-defaultClientType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237
iwtClient-clientTypes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238
Desktop Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241
9
iwtDesktop-clientAllProviders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241
iwtDesktop-clientUserSelectedProviders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 242
iwtDesktop-clientChannelListModules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243
Appendix A API Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245Client Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
Client Detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 248
Client Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 251
Provider APIs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252
Determining Presentability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252
Fetching Content . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 254
Determining Editability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255
Appendix B Sample Tasks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257Configuring the Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257
Modifying the Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257
Adding an Attribute . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 258
Customizing the Templates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 259
Adding a New ClientType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260
Customizing the Client Detection Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 263
Developing a Customized Client Detector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264
Modifying the Default Client Detector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 265
Creating Help Links . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266
Enabling Help Content Delivery on a Mobile Device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266
Developing and Storing the Help Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
Making a Provider Client Aware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
Implementing the Client Data API . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
Initializing a Provider with the Init Method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277
Using the Session API to Retrieve the Client Type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 278
Using the Client API . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279
10 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
11
Preface
The iPlanet Portal Server: Mobile Access Pack 3.0 software extends the broad
services and content aggregation platform provided by the iPlanet Portal Server 3.0
SP3 to mobile devices.
The Programmer’s Guide discusses the various components of the Mobile Access
Pack server used to authenticate and service the client.
This preface contains the following sections:
• Audience for This Guide
• What’s in This Guide
• How to Use This Guide
• Other Resources
• Typographic Conventions
Audience for This GuideThis guide is for the iPlanet Portal Server: Mobile Access Pack 3.0 software
administrators and developers. It assumes that you already know the basics of:
• The iPlanet Portal Server components, how to build providers and deploy
channels, and the portal administration and programming tasks
• One or more of the following programming languages: HTML, cHTML, WML,
Javascript, XML, and Java
What’s in This GuideThe following table provides a quick overview of what is in this guide:
How to Use This Guide
12 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
How to Use This GuideBefore you begin working with this guide, check the iPlanet Technical Publications
web site, http://docs.iplanet.com/, to make sure that you have the latest version
of this guide. Also check there for any supplementary information, such as Release
Notes, for late breaking information on the product.
Use this guide:
• To customize the look and feel of the graphical user interface of the Desktop
and Desktop components on the user’s mobile device.
• To extend the software’s capability to support and deliver content to clients
besides genericHTML, WML, and cHTML
• To extend your current portal framework to WML and cHTML clients
See this chapter For information on this
Chapter 1, “Overview” This chapter provides an overview of the various topics
discussed in this book.
Chapter 2, “Authentication Template
Files”
This chapter discusses the template files used by the
Mobile Access Pack Authentication Service.
Chapter 3, “Desktop Template Files” This chapter discusses the template files used by the
Mobile Access Pack Desktop Service.
Chapter 4, “Content Provider
Template Files”
This chapter discusses the template files used by the
Mobile Access Pack Content Providers.
Chapter 5, “Application JSPs” This chapter discusses the JSP files used by the Mobile
Access Pack Wireless Applications.
Chapter 6, “JSP Tag Libraries” This chapter discusses the JSP Tag Libraries used by the
Mobile Access Pack Wireless Applications.
Chapter 7, “Tag Swapper Tags” This chapter discusses the tag swapper tags used in the
Mobile Access Pack template files.
Chapter 8, “Attributes and Schemas” This chapter discusses the Mobile Access Pack
component attributes.
Appendix A, “API Descriptions” This appendix discusses the Mobile Access Pack public
APIs.
Appendix B, “Sample Tasks” This appendix provides some sample tasks on
customizing the Mobile Access Pack server.
Other Resources
Preface 13
Use this guide, which includes information for customizing the server, in
conjunction with the Mobile Access Pack Administration Guide, which provides
instructions for configuring the server from the administration console.
Other Resources
Documentation ResourcesThe centralized source of information on all iPlanet software documentation is the
iPlanet publications web site. The URL is http://docs.iplanet.com/ . On this
page, all available documentation are listed and linked to files you can view or
download.
The following is the documentation set for the Mobile Access Pack software:
• Mobile Access Pack Installation Guide - Includes instructions for installing the
Mobile Access Pack server.
• Mobile Access Pack Administration Guide - Includes instructions for configuring
the server from the administration console.
• Mobile Access Pack Programmer’s Guide (this book) - Includes information for
customizing and extending the Mobile Access Pack software.
• Release Notes, in HTML and PDF formats - Includes late breaking information
about the software.
• Administration Console online help - It is available in HTML format only and
is bundled with the Mobile Access Pack software. It contains information on
the administration console graphical user interface.
• Desktop online help - It is available in HTML format only and is bundled with
the Mobile Access Pack software. It contains information on the Desktop
graphical user interface and instructions for configuring the user’s mobile
device from the Desktop.
Also consult the following books which contains information related to the subject
matter discussed in this book:
• iPlanet Portal Server 3.0 Administration Guide, in HTML and PDF formats, is
available on the iPlanet Documentation web site. It includes instructions for
configuring and administering the iPlanet Portal Server.
Typographic Conventions
14 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
• iPlanet Portal Server 3.0 Programmer’s Reference Guide, in HTML and PDF
formats, is available on the iPlanet Documentation web site. It explains how to
use the iPlanet Portal Server application programming interfaces (APIs),
including the Java APIs and the over-the-wire (non-Java) APIs.
• iPlanet Portal Server 3.0 Service Pack 3a Release Notes, in HTML and PDF
formats, is available on the iPlanet Documentation web site. It includes
important information about the iPlanet Portal Server 3.0 SP3 software, which
is used to build the Mobile Access Pack software.
Typographic ConventionsThe text in this book uses the following typographic styles:
Typeface or Symbol Meaning Example
AaBbCc123 The names of commands, files, and
directories; on-screen computer
output
Edit your .login file.
Use ls -a to list all files.
AaBbCc123 On-screen computer input Type exit at the command
prompt.
15
Chapter 1
Overview
This chapter discusses the:
• Extensions to the iPlanet Portal Server 3.0 Service Pack 3 software to support
WML and cHTML clients
• Wireless Applications for WML and cHTML clients
IntroductionThe Mobile Access Pack software is an extension to the iPlanet Portal Server 3.0
SP3 software. The iPlanet Portal Server supports only generic HTML clients. The
Mobile Access Pack software extends its capability to build and deploy channels
that can deliver content to multiple HTML and non-HTML (namely WML and
cHTML) clients.
The Mobile Access Pack software includes:
• Extensions to the iPlanet Portal Server Desktop and its associated content
providers
• Wireless applications that can deliver content from the iPlanet Calendar
Server, iPlanet Messaging Server, and the Personal Address Book server via
the iPlanet Directory Server
In order to serve the iPlanet Portal Server Desktop content to non-HTML clients,
the Mobile Access Pack server includes extensions to the iPlanet Portal Server
Desktop and services that make them client aware.
Extensions to iPlanet Portal Server
16 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Client AwarenessClient awareness refers to the Mobile Access Pack server’s ability to detect the type
of client accessing the server and provide service to the client with the content in
the format supported by the client. Besides supporting generic HTML clients, the
Mobile Access Pack server can service WML and cHTML clients and can also be
extended to support other clients.
Client Detection ModuleIn order to detect the type of client accessing the server, the Mobile Access Pack
server uses a pluggable Client Detection module to determine the client’s mobile
device characteristics. For information on the Client Detector class and the Client
Detection interface, see Appendix A, “API Descriptions” and Appendix B, “Sample
Tasks.”
Client Data ObjectsThe client’s mobile device characteristics are stored in Client Data objects. The
Client Data objects store various properties of the clients, such as userAgent,
contentType, supported character set, etc. The Mobile Access Pack server provides
Client Data objects for HTML, cHTML, and WML clients. For detailed information
on Client Detection and Client Data, see Appendix A, “API Descriptions,”
Appendix B, “Sample Tasks,” and Chapter 8, “Attributes and Schemas.”
Extensions to iPlanet Portal ServerThe Mobile Access Pack server includes extensions to the iPlanet Portal Server
desktop, content providers, and authentication service to support cHTML and
WML clients.
Templates are used to determine how responses to the client should be formatted.
The Mobile Access Pack server includes templates to format responses for generic
HTML, cHTML, and WML clients. The server uses the static content in the
templates to display the component user interface. Tags are used for inserting
dynamic data into the templates. For information on the tags used in these
templates, see Chapter 7, “Tag Swapper Tags.”
Client Specific AuthenticationThe Mobile Access Pack extends the iPlanet Portal Server authentication service to:
Extensions to iPlanet Portal Server
Chapter 1 Overview 17
1. Detect the type of client accessing the server and validate that the requesting
client type is supported by the server.
The list of clients supported by the server are stored in Client Data objects.
2. Present the client specific authentication menu to the requesting client.
The list of authentication modules supported by each client is stored in
attributes. For more information on the authentication module attributes, see
Chapter 8, “Attributes and Schemas.” The Mobile Access Pack server uses
template files for displaying the authentication menu. For detailed information
on the templates used by the Mobile Access Pack to authenticate the user, see
Chapter 2, “Authentication Template Files.”
Wireless DesktopThe Mobile Access Pack server includes extensions to the various iPlanet Portal
Server desktop providers to present the user’s client specific user interface on
WML and cHTML clients. For information on the template files used by the
providers to display the desktop user interface, see Chapter 3, “Desktop Template
Files.”
Wireless Content ProvidersThe Mobile Access Pack server includes calendar, mail, and address book
providers to display:
• Summary information from the iPlanet Calendar Server, iPlanet Messaging
Server, and Personal Address Book server respectively
• Links to the specialized backend clients for interaction with the service
For information on the template files used to display the summary information, see
Chapter 4, “Content Provider Template Files.”
The Mobile Access Pack also includes a wireless Personal Notes and XML
provider. The wireless Personal Notes provider, similar in functionality to the
iPlanet Portal Server Personal Notes provider, can also support WML and cHTML
clients. The XML provider enables integration of an arbitrary XML emitting
service. It uses the JAXP 1.1 interface and the file lookup mechanism to retrieve the
client specific XSL templates and display the XML content in the format supported
by the requesting client.
The Mobile Access Pack also includes extensions to the iPlanet Portal Server User
Info, URL Scraper, Post-it Notes, JSP, and Bookmarks providers to support content
delivery to WML and cHTML clients. For information on the template files used by
these content providers, see Chapter 4, “Content Provider Template Files.”
Wireless Applications
18 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
File Lookup MechanismThe Mobile Access Pack providers use the iPlanet Portal Server file lookup
mechanism to retrieve templates for the client. Files are organized by various
properties including locale, domain, and clientType. In order to locate the files, the
server resolves the appropriate location of the template files by computing a file
system path based on:
1. A system type, typically the domain
2. The user’s configured locale
3. A component, typically the channel name
4. The client type
5. The filename
These parameters (domain, locale, component, clientType, and filename) are used
to uniquely identify a template into the file system path. This path is used to
retrieve the templates from the file system.
Within the clientType parameter is encoded a hierarchy of clientTypes starting
with the most general and ending with the most specific; for example,
WML/Nokia/7110/UP/9600 or WML/FooPhone/R520s/UP/9600 . In order to select
the appropriate template for the client, the server maps the clientType parameter
directly into the file system path and attempts to retrieve the requested filename;
for example, WML/Nokia/7110/UP/9600/filename . If that fails, then the most
specific clientType attribute (such as 9600) is removed (such as
WML/Nokia/7110/UP/filename) and the process is repeated until the template
for that clientType is found.
For more information on the file lookup mechanism, see also the File Lookup
section in the iPlanet Portal Server 3.0 SP3 Release Notes.
Wireless Applications
JSPsThe Mobile Access Pack provides JSP files to deliver content from the iPlanet
Calendar Server, iPlanet Messaging Server, and the Personal Address Book server
on WML and cHTML clients. For more information on the JSP files, see Chapter 5,
“Application JSPs.”
Wireless Applications
Chapter 1 Overview 19
JSP Tag LibrariesThe JSP files provide the static user interface. All the dynamic data (such as
appointments from the calendar, mail headers from the inbox, entries from the
address book) are retrieved using customized tag libraries. For more information
on the tag libraries, see Chapter 6, “JSP Tag Libraries.”
Wireless Applications
20 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
21
Chapter 2
Authentication Template Files
In order to authenticate the client, the Mobile Access Pack server uses the various
pluggable authentication modules (such as UNIX, LDAP, etc.). Once the identity of
the client is established, the server uses the client specific template files to display
the appropriate menu to the client.
This chapter discusses the HTML, cHTML, and WML template files used by the
authentication service. The HTML, cHTML, and WML templates discussed in this
chapter facilitate the display of the appropriate authentication menu based on the
type of client accessing the Mobile Access Pack server.
When customizing template files, do not edit the original files. Copy the files into a
separate directory and make changes to the copies. This will facilitate upgrades
and uninstalls.
Authentication Template FilesThe following template files with a .html, .chtml, and .wml extension are located in
the /etc/opt/SUNWips/auth/default/ ,
/etc/opt/SUNWips/auth/default/chtml/ , and in
/etc/opt/SUNWips/auth/default/wml/ directories respectively. These files serve
the same purpose across all clients.
Table 2-1 Authentication Template Files
Filename Description
access_fail_admin Indicates that the user has insufficient privileges or is not
authorized to access the administration console although the
user was able to log in to the Administration Console
invalidPassword Indicates that the user’s password is invalid
invalidPCookieUserid Indicates that the user’s persistent cookie is invalid
Authentication Template Files
22 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
invalid_domain Indicates that the domain is invalid, sometimes as a result of
cached cookies
loginworker_if Used to form input box
loginworker_loop Used to form input box
loginworker_main Used for text for title of page
loginworker_mainend Used for Submit button or equivalent
login_denied Indicates that the authentication failed or access is denied
because the user does not have a user profile in the database
login_fail_admin Indicates that access to the Administration Console is denied
login_fail_template Indicates that the user’s authentication attempt has failed
login_license_fail Indicates that the user’s license is invalid
login_menu Displays all available authentication methods on the user’s
authentication page
login_menu_modules This file is used to wrap each authentication module in
specific tags on the authentication menu page
login_prompt Displays the user’s login prompt
login_reauth_admin Indicates that the administrator’s session has expired and that
the administrator must re-authenticate to the Administration
Console
login_success Indicates that the user’s authentication was successful, but
the user has no default desktop page to display
login_template Displays an error message as a result of restricted access to
the server
login_timeout_admin Indicates that the administrator’s session on the
Administration Console has timed out
login_timeout_template Indicates that the user’s session has timed out
login_trustProxy_warning Warns the user that the user’s mobile device does not support
Java
logout Used to display a logout message and provide a link back to
the authentication menu
logout_admin Used to display a logout message and provide a link back to
console login
module_denied Displays an authentication module denied error message
Table 2-1 Authentication Template Files
Filename Description
Authentication Template Files
Chapter 2 Authentication Template Files 23
noLoginWorker Indicates that no login worker is available
privilege_failure Indicates that the user does not have sufficient privileges
session_invalid Indicates that the session is invalid
session_timeout Indicates that the session has timed out
userExists Indicates that the user name already exists
userPasswordSame Indicates that another user is using the same password
wrongPassword Indicates that the user entered the password incorrectly
Table 2-1 Authentication Template Files
Filename Description
Authentication Template Files
24 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
25
Chapter 3
Desktop Template Files
On the desktop and mobile device, content is displayed through a channel and the
displayed content is specific to the channel and clientType. For each supported
client, client specific template files describe the presentation and the layout of the
channel.
This chapter discusses the HTML, cHTML, and WML template files used to
display the pages that allow the user to configure the channel and the layout of the
channel on their desktop page and mobile device home page.
These files are, by default, located in
/etc/opt/SUNWips/desktop/MAP/iwtDesktop ,
/etc/opt/SUNWips/desktop/default/iwtDesktop/html ,
/etc/opt/SUNWips/desktop/default/iwtDesktop/wml/ ,
/etc/opt/SUNWips/desktop/default/iwtDesktop/chtml directories.
The Mobile Access Pack Desktop providers use the file lookup mechanism to
retrieve the client specific template files.
The Front Provider Template FilesThe Front Provider presents the user’s desktop page and navigation links to access
the graphical user interface of the other desktop providers. The Front Provider
invokes the content and application providers to display client specific content in
the form of channels. On an HTML device, these channels appear as table cells. On
a WML device, these channels appear as links to WML cards containing the
contents of the channel. The following template files provide the front page for the
user.
The Front Provider Template Files
26 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Desktop and Mobile Devices Home Page Template FilesThis page typically contains the content of the user’s selected channels. The
following template files enable the presentation of these channels on the user’s
desktop and/or mobile device home page.‘
HTML Template Files
The following template files are also used to display the desktop on a HTML client:
The Front Provider Template Files
Chapter 3 Desktop Template Files 27
• menubar.html - Provides the black menubar used in the user’s desktop. This
file replaces the menubar.html file used in the iPlanet Portal Server desktop. It
uses the [tag:iwtDesktop-fontFace1] and [tag:productName] tags.
• openClientsPage.js - Contains Javascript funtions to generate target URL for
the Mobile Devices page. This is invoked to navigate to the Mobile Devices
page.
WML Template Files
The following template files are used to display the user’s home page on a wml
client.
• frontProvider.template - Provides the markup for the home page on the
mobile devices (WML clients) with links to configured providers. It uses the
[tag:productName] , [tag:links] , and [tag:content] tags.
• providerWrapper.template - Wraps the content of each channel or provider.
It uses the [tag:provider] , [tag:title] , [tag:content] , and
[tag:prov_help] tags.
• linkWrapper.template - Contains links to each channel. It uses the
[tag:provider] and [tag:title] tags.
• provHelpLink.template - Contains links to the help file for the channel. It
uses the [tag:help_link] tag.
• frontHelpLink.template - Contains links to the help file for the Home page.
It uses the [tag:help_link] tag.
• changePage.template - Contains options to change the page. It uses the
[tag:changePageURL] and [tag:textMsg] tags.
• redirect.template - Contains markup to redirect the user to another URL. It
uses the [tag:URL] tag.
Nokia
The Front Provider Template Files
28 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The files discussed in this section are located in
/etc/opt/SUNWips/desktop/default/iwtDesktop/wml/Nokia directory and are
customized to support display of content on the Nokia 7110 phone.
• frontProvider.template - Displays the Nokia home page (similar to the
desktop on a HTML client). It uses the [tag:productName] and
[tag:content] tags.
• linkWrapper.template - Provides the template that wraps the channel into an
option. It uses the [tag:provider] and [tag:title] tags.
• providerWrapper.template - Wraps the content of each channel or provider
in the home page of Nokia. It uses the [tag:provider] , [tag:title] ,
[tag:content] , and [tag:prov_help] tags.
cHTML Template Files
The following template files are used to display the user’s home page on a cHTML
client.
• frontProvider.template - Provides the markup for home page on mobile
devices (cHTML clients) with links to configured providers. It uses the
[tag:productName] , [tag:links] , and [tag:content] tags.
• providerWrapper.template - Wraps the content of each channel or provider.
It uses the [tag:provider] , [tag:title] , [tag:content] , and
[tag:prov_help] tags.
• linkWrapper.template - Contains links to each channel. It uses the
[tag:provider] and [tag:title] tags.
• provHelpLink.template - Contains links to the help file for the channel. It
uses the [tag:help_link] tag.
• frontHelpLink.template - Contains links to the help file for the Home page.
It uses the [tag:help_link] tag.
• changePage.template - Contains options to change the page. It uses the
[tag:changePageURL] and [tag:textMsg] tags.
The Client Configuration Provider Template Files
Chapter 3 Desktop Template Files 29
• redirect.template - Contains markup to redirect the user to another URL. It
uses the [tag:URL] tag.
The Client Configuration Provider Template FilesThe template files discussed in this section allow the user to configure the mobile
devices that they will use to access the services. The user can not perform these
tasks from the mobile device and must use their desktop to specify their mobile
clientType. These template files provide support for configuring multiple
clientTypes.
Select Mobile Devices
HTML Template Files
The Client Configuration Provider Template Files
30 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
• devicemenubar.html - Provides the black menubar used in the Select Mobile
Devices, Add or Remove Mobile Devices, Select Channels For Display,
Organize Channel Layout on Devices, and Configure Character Set for Mobile
Device pages. It uses the [tag:iwtDesktop-fontFace1] and
[tag:productName] tags.
• clientConfiguration.template - Provides the page for the user to select the
mobile clients to be configured. It uses the [tag:noCache] ,
[tag:openFrontPage] , [tag:productName] , [tag:openContentPage] ,
[tag:openLayoutPage] , [tag:openClientsPage] , [tag:openOptionsPage] ,
[tag:style] , [tag:banner] , [tag:devicemenubar] ,
[tag:iwtDesktop-fontFace1] , and [tag:selectClients] tags.
• clientSelect.template - Provides a list of mobile devices that the user can
configure. It uses the [tag:clientSize] and [tag:clientOptions] tags.
• clientOption.template - This file is used by the [tag:clientOptions] tag
in the clientSelect.template file. It provides the markup for the OPTION
tag for mobile clients within the SELECT tag in the clientSelect.template
file. It uses the [tag:client] and [tag:clientType] tags.
• openConfigurationPage.js - Contains Javascript funtions to generate target
URL for the Add/Remove Clients page. This is invoked to navigate to the
Add/Remove Clients page.
• openContentPage.js - Contains Javascript funtions to generate target URL for
the client specific channels page. This is invoked to navigate to the client
specific channel selection page.
• openLayoutPage.js - Contains Javascript funtions to generate target URL for
the Layout page. This is invoked to navigate to the client specific content
Layout page.
• openOptionsPage.js - Contains Javascript funtions to generate target URL for
the Options page. This is invoked to navigate to the client specific Options
page.
The Client Configuration Provider Template Files
Chapter 3 Desktop Template Files 31
Add or Remove Mobile Devices
HTML Template Files
• devicemenubar.html - Provides the black menubar used in the Select Mobile
Devices, Add or Remove Mobile Devices, Select Channels For Display,
Organize Channel Layout on Devices, and Configure Character Set for Mobile
Device pages. It uses the [tag:iwtDesktop-fontFace1] and
[tag:productName] tags.
• addRemoveClients.template - Provides the page for the user to add or
remove mobile clients. It uses the [tag:noCache] , [tag:openFrontPage] ,
[tag:openConfigurationPage] , [tag:style] , [tag:banner] ,
[tag:devicemenubar] , [tag:iwtDesktop-fontFace1] , and
[tag:availableClients] tags.
The Content Provider Template Files
32 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
• checked.template - Provides the input to check the checkbox. It provides the
value for the [tag:checked] tag.
• clientInput.template : Provides the markup for checkbox input that
provides the clientTypes. It uses the [tag:client] , [tag:clientType] , and
[tag:checked] tags.
The Content Provider Template FilesThe template files discussed in this section provides the page that allows the user
to select the channels they wish to display on their desktop and on their mobile
devices. These template files define the type of content to be displayed on all
supported devices.
The Content Provider Template Files
Chapter 3 Desktop Template Files 33
Select Channels For Display
HTML Template Files
The Content Provider Template Files
34 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
• devicemenubar.html - Provides the black menubar used in the Select Mobile
Devices, Add or Remove Mobile Devices, Select Channels For Display,
Organize Channel Layout on Devices, and Configure Character Set for Mobile
Device pages. It uses the [tag:iwtDesktop-fontFace1] and
[tag:productName] tags.
• contentProvider.template - Provides the page that presents the available
channels for the selected mobile device. It uses the [tag:noCache] ,
[tag:productName] , [tag:openConfigurationPage] ,
[tag:openFrontPage] , [tag:style] , [tag:banner] , [tag:devicemenubar] ,
[tag:client] , [tag:clientName] , [tag:content] ,
[tag:iwtDesktop-fontFace1] tags.
• selectWrapperTrue.template - Provides the template that wraps the channel
select option for a channel that is selected. It uses the [tag:provider] ,
[tag:title] , and [tag:description] tags.
• selectWrapperFalse.template - Provides the template that wraps the
channel select option for a channel that is not selected. It uses the
[tag:provider] , [tag:title] , and [tag:description] tags.
• optionWrapper.template - Provides the template that wraps the channel into
an option. It uses the [tag:provider] and [tag:title] tags.
• providerOption.template - Provides the list of selected channel names. It
uses the [tag:providerName] and [tag:title] tags.
• providerInput.template - Provides the checkbox in the available channel
list. This is used to select or deselect channels. It uses the [tag:provider] ,
[tag:checked] , [tag:title] , and [tag:description] tags.
• providerSelect.template - Provides the markup for SELECT tag containing
providerOption. It uses the [tag:providerSize] and
[tag:providerOptions] tags.
• openConfigurationPage.js - Contains Javascript funtions to generate target
URL for the Select Mobile Devices page. This is invoked to navigate to the
Select Mobile Devices page when the user selects the cancel button.
The Content Provider Template Files
Chapter 3 Desktop Template Files 35
WML Template Files
• contentProvider.template - Provides the page that displays the list of
available channels for the user. It uses the [tag:semiColonSelectedList]
and [tag:content] .
• selectWrapperTrue.template - Provides the template that wraps the channel
select option for a channel that is selected. It uses the [tag:provider] ,
[tag:title] , and [tag:description] tags.
• selectWrapperFalse.template - Provides the template that wraps the
channel select option for a channel that is not selected. It uses the
[tag:provider] , [tag:title] , and [tag:description] tags.
• optionWrapper.template - Provides the template that wraps the channel into
an option. It uses the [tag:provider] and [tag:title] tags.
Nokia
The files discussed in this section are located in
/etc/opt/SUNWips/desktop/default/iwtDesktop/wml/Nokia directory and are
customized to support display of content on the Nokia 7110 phone.
• contentProvider.template - Provides the page that presents the available
content for Nokia and provides a list of available channels for Nokia. It uses
the [tag:semiColonSelectedList] and [tag:content] tags.
• optionWrapper.template - This file provides the template that wraps the
channel into an option. It uses the [tag:provider] and [tag:title] tags.
The Layout Provider Template Files
36 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
cHTML Template Files
• contentProvider.template - Provides the page that displays the list of
available channels for the user. It uses the [tag:semiColonSelectedList]
and [tag:content] .
• selectWrapperTrue.template - Provides the template that wraps the channel
select option for a channel that is selected. It uses the [tag:provider] ,
[tag:title] , and [tag:description] tags.
• selectWrapperFalse.template - Provides the template that wraps the
channel select option for a channel that is not selected. It uses the
[tag:provider] , [tag:title] , and [tag:description] tags.
• optionWrapper.template - Provides the template that wraps the channel into
an option. It uses the [tag:provider] and [tag:title] tags.
The Layout Provider Template FilesThe template files discussed in this section provides the mobile devices edit
content page for the user to configure and customize the layout order of the
channels on the user’s desktop and mobile devices. These template files define the
display of content on all supported devices.
The Layout Provider Template Files
Chapter 3 Desktop Template Files 37
Organize Channel Layout on Devices
HTML Template Files
• devicemenubar.html - This file provides the black menubar used in the Select
Mobile Devices, Add or Remove Mobile Devices, Select Channels For Display,
Organize Channel Layout on Devices, and Configure Character Set for Mobile
Device pages. It uses the [tag:iwtDesktop-fontFace1] and
[tag:productName] tags.
• layoutProvider.template - Provides the page that allows users to organize
their content on their mobile devices. It uses the [tag:productName] ,
[tag:openConfigurationPage] , [tag:openFrontPage] , [tag:style] ,
[tag:banner] , [tag:devicemenubar] , [tag:iwtDesktop-fontFace1] , and
[tag:provider] tags.
The Layout Provider Template Files
38 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
• anchorWrapper.template - Provides the markup for the anchor tag. It uses
the [tag:provider] and [tag:title] tags.
• openConfigurationPage.js - Contains Javascript funtions to generate target
URL for the Select Mobile Devices page. This is invoked to navigate to the
Select Mobile Devices page when the user selects the cancel button.
WML Template Files
• layoutProvider.template - Provides the page that allows users to organize
their content on their mobile devices. It uses the [tag:content] tag.
• anchorWrapper.template - Provides the markup for the anchor tag. It uses
the [tag:provider] and [tag:title] tags.
Nokia
The files discussed in this section are located in
/etc/opt/SUNWips/desktop/default/iwtDesktop/wml/Nokia directory and are
customized to support display of content on the Nokia 7110 phone.
• layoutProvider.template - Provides the page on the Nokia mobile device to
organize the layout of the content on Nokia. It uses the [tag:content] tag.
• anchorWrapper.template - This file is used by the Nokia layoutProvider and
uses the [tag:title] tag.
cHTML Template Files
The Options Provider Template Files
Chapter 3 Desktop Template Files 39
• accesskey.template - Provides the numeric entity for the numeric emoji
characters used in cHTML. It uses the [tag:accesskey-no] tag.
• entity1.template - entity9.template - Provides the entity for emoji
character image "1" through “9” respectively. Emoji are special characters
which appear in i-mode pages as small icons. In cHTML, emoji are written as
an ampersand, a pound sign followed by 5 digits
• layoutProvider.template - Provides the page that allows users to organize
their content on their mobile devices. It uses the [tag:providerCount] and
[tag:content] tags.
• anchorWrapper.template - Provides the markup for the anchor tag. It uses
the [tag:provider] and [tag:title] tags.
The Options Provider Template FilesThe template files discussed in this section provides the mobile device edit options
page for the user to configure the character set for their mobile devices. This can be
performed from the user’s desktop only.
The Options Provider Template Files
40 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Configure Character Set for Mobile Device
HTML Template Files
• optionsProvider.template - Provides the page that allows users to select the
character set to use with their mobile device. It uses the
[tag:openConfigurationPage] , [tag:openFrontPage] , [tag:style] ,
[tag:banner] , [tag:devicemenubar] , [tag:client] ,
[tag:iwtDesktop-fontFace1] , [tag:clientName] , and
[tag:charsetchoices] tags.
• charsetChoices.template - Provides the drop-down list of available
character sets for the user in the Options page. It uses the [tag:charset] and
[tag:selected] tags.
• selected.template - Provides the input for the [tag:selected] tag in the
charsetChoices.template file.
• openConfigurationPage.js - Contains Javascript funtions to generate target
URL for the Select Mobile Devices page. This is invoked to navigate to the
Select Mobile Devices page when the user selects the cancel button.
41
Chapter 4
Content Provider Template Files
Besides including extensions to the iPlanet Portal Server User Info, Personal Notes,
Post-it Notes, and Bookmarks providers, the Mobile Access Pack includes
Calendar, Mail, and Address Book providers to deliver appropriate content to
HTML, WML, and cHTML clients from the iPlanet Calendar Server, iPlanet
Messaging Server, and Personal Address Book server respectively.
This chapter discusses the:
• HTML, cHTML, and WML template files for Calendar, Mail, and Address
Book providers
• HTML, cHTML, and WML template files for Wireless Personal Note, PostIt
Note, URL Scraper, User Info, and Bookmark providers
The templates discussed in this chapter facilitate the display of the provider
content via channels on devices that support these markup languages. These
HTML, cHTML, and WML template files can be used to customize the content
delivery on the user’s Desktop and mobile device.
These template files are located in
/etc/opt/SUNWips/desktop/< locale >/< iwtComponent >/< clientType >
directory. Template files in the:
• html directory enable the display of the channel on an HTML client
• wml directory enable the display of the channel on a WML client
• chtml directory enable the display of the channel on a cHTML client
Refer to Chapter 7, “Tag Swapper Tags” for detailed information on the tags used
in these template files.
The Calendar Provider Template Files
42 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The Calendar Provider Template FilesThe following template files are located in the
/etc/opt/SUNWips/desktop/< locale >/iwtCalendarProvider/html ,
/etc/opt/SUNWips/desktop/< locale >/iwtCalendarProvider/chtml/ , and in
the /etc/opt/SUNWips/desktop/< locale >/iwtCalendarProvider/wml/
directories. These files facilitate the display of the calendar channel on all of the
supported clients.
The calendar channel gets the events and displays the day and/or week view
(stored in the iwtCalendarProvider-dayView and
iwtCalendarProvider-weekView attributes respectively), getting the start and
end time as well as the location, summary, and description. The channel then
displays the events in the display specified by the user. The summary header is
displayed on top; then the day view, which has the times, location, summary, and
description, is displayed, and the week view is displayed below the day view, with
the days of the week, the times of events, and summary information.
Figure 4-1 Sample Calendar Channel
• display-clientURL.template - This template displays the Single Sign On
URL for the calendar client on the user’s desktop. It uses the
[tag:calendar-display-client-uri] and the
[tag:calendar-display-client-sessionid] tags.
The Calendar Provider Template Files
Chapter 4 Content Provider Template Files 43
• display-error.template - This template displays an error message in the
Calendar channel. It uses the [tag:calendar-display-error] tag.
• display-summary.template - This template displays a summarized
information; for example, at the top of the channel, this file displays the
number of events for the day. It uses the [tag:iwtDesktop-fontFace1] ,
[tag:calendar-display-summary-events] tags.
• display-dayView.template - This template displays the complete day view
information. It uses the [tag:iwtDesktop-fontFace1] ,
[tag:calendar-display-dayView-dayOfWeek] ,
[tag:calendar-display-dayView-month] ,
[tag:calendar-display-dayView-day] ,
[tag:calendar-display-dayView-year] , and
[tag:calendar-display-dayView-eventList] tags.
• display-dayView-emptyEventList.template - This template displays
nothing for an empty day if the user’s calendar display preference is set to Day
View. It uses the [tag:iwtDesktop-fontFace1] tag.
• display-dayView-event.template - This template retrieves the events for
the day if the user’s calendar display preference is set to Day View. It uses the
[tag:calendar-display-dayView-event-startHourOfDay0] ,
[tag:calendar-display-dayView-event-startHourOfDay1] ,
[tag:calendar-display-dayView-event-startHour0] ,
[tag:calendar-display-dayView-event-endHourOfDay0] ,
[tag:calendar-display-dayView-event-endHourOfDay1] ,
[tag:calendar-display-dayView-event-endHour0] ,
[tag:iwtDesktop-fontFace1] ,
[tag:calendar-display-dayView-event-startHour1] ,
[tag:calendar-display-dayView-event-startMinute] ,
[tag:calendar-display-dayView-event-startAmPm] ,
[tag:calendar-display-dayView-event-endHour1] ,
[tag:calendar-display-dayView-event-endMinute] ,
[tag:calendar-display-dayView-event-endAmPm] ,
[tag:calendar-display-dayView-event-location] ,
[tag:calendar-display-dayView-event-summary] , and
[tag:calendar-display-dayView-event-description] tags.
• display-dayView-eventAllDay.template - This template displays events for
the day without specifying the start and end hour (simply denotes the event as
an “All Day” event) if the user’s calendar display preference is set to Day View.
It uses the [tag:iwtDesktop-fontFace1] ,
The Calendar Provider Template Files
44 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
[tag:calendar-display-dayView-event-allDay] ,
[tag:calendar-display-dayView-event-location] ,
[tag:calendar-display-dayView-event-summary] , and
[tag:calendar-display-dayView-event-description] tags.
• display-weekView.template - This template displays the events located in
the Week View, according to the days of the week. It uses the
[tag:iwtDesktop-fontFace1] ,
[tag:calendar-display-weekView-dayOfWeek0] -
[tag:calendar-display-weekView-dayOfWeek6] ,
[tag:calendar-display-weekView-day0] -
[tag:calendar-display-weekView-day6] , and
[tag:calendar-display-weekView-eventList0] -
[tag:calendar-display-weekView-eventList5] .
• display-weekView-emptyEventList.template - This template displays
nothing if the user’s preference is not set to Week View.
• display-weekView-event.template - This template retrieves information
about the events in the week when the user’s calendar display preference is set
to Week View. It uses the
[tag:calendar-display-weekView-event-startHourOfDay0] ,
[tag:calendar-display-weekView-event-startHourOfDay1] ,
[tag:calendar-display-weekView-event-startHour0] ,
[tag:calendar-display-weekView-event-endHourOfDay0] ,
[tag:calendar-display-weekView-event-endHourOfDay1] ,
[tag:calendar-display-weekView-event-endHour0] ,
[tag:calendar-display-weekView-event-startHour1] ,
[tag:calendar-display-weekView-event-startMinute] ,
[tag:calendar-display-weekView-event-startAmPm] ,
[tag:calendar-display-weekView-event-endHour1] ,
[tag:calendar-display-weekView-event-endMinute] ,
[tag:calendar-display-weekView-event-endAmPm] , and
[tag:calendar-display-weekView-event-summary] tags.
• display-weekView-eventAllDay.template - This template retrieves
information about the events in the week when the user’s calendar display
preference is set to Week view without specifying the start and end hour
(simply denotes the event as an “All Day” event) of the events. It uses the
[tag:calendar-display-weekView-event-allDay] and
[tag:calendar-display-weekView-event-summary] tags.
The Calendar Provider Template Files
Chapter 4 Content Provider Template Files 45
• display.template - This file is used as a wrapper for the whole channel. It
uses the [tag:calendar-display-summary] ,
[tag:calendar-display-dayView] , [tag:calendar-display-weekView] ,
[tag:calendar-display-clientURL] ,
[tag:calendar-display-client-uri] , and
[tag:calendar-display-client-sessionid] tags.
• edit.template - This template displays the calendar channel edit page on the
user’s HTML desktop only. It uses the [tag:dayView] , [tag:weekView] ,
[tag:iwtDesktop-fontFace1] , [tag:calendarServerName] ,
[tag:calendarServerPort] , [tag:calendarUserName] , and
[tag:calendarUserPassword] tags.
Figure 4-2 Sample Calendar Channel Edit Page
The Mail Provider Template Files
46 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The Mail Provider Template FilesThe following template files are located in the
/etc/opt/SUNWips/desktop/< locale >/iwtMailProvider/html ,
/etc/opt/SUNWips/desktop/< locale >/iwtMailProvider/chtml/ , and in the
/etc/opt/SUNWips/desktop/< locale >/iwtMailProvider/wml/ directories.
These files facilitate the display of the mail channel on all of the supported clients.
The mail channel uses the servername, username, and password set by the user in
the edit UserInformation page or the edit Mail page to connect to the mail server
and get the summary of the unread and total messages. The channel gets the
undeleted message headers from the user’s inbox and sorts them by the received
date on the message. The channel then displays the message headers in the sort
order specified by the user.
Figure 4-3 Sample Mail Channel
• display-clientURL.template - This template displays the Single Sign On
URL for the mail client on user’s desktop. It uses the
[tag:mail-display-clientURL-uri] tag.
• display-error.template - This template displays an error message in the
Mail channel. It uses the [tag:mail-display-error] tag.
• display-summary.template - This template serves content for the summary
of messages in the channel. It uses the [tag:iwtDesktop-fontFace1] ,
[tag:mail-display-summary-unread] , and
[tag:mail-display-summary-total] tags.
The Mail Provider Template Files
Chapter 4 Content Provider Template Files 47
• display-headers-message.template - This template displays each message
header in the Mail channel on the user’s HTML desktop. It uses the
[tag:mail-display-headers-message-cbgc] ,
[tag:mail-display-headers-message-clientURL] ,
[tag:mail-display-headers-message-subject] ,
[tag:mail-display-headers-message-mailto] ,
[tag:mail-display-headers-message-name] ,
[tag:mail-display-headers-message-date] ,
[tag:mail-display-headers-message-status] , and
[tag:iwtDesktop-fontFace1] tags.
• display-headers.template - This template is used to wrap around all the
message headers. It uses the [tag:mail-display-headers-subject] ,
[tag:mail-display-headers-from] , [tag:mail-display-headers-date] ,
[tag:mail-display-headers-status] ,
[tag:mail-display-headers-messageList] , and
[tag:iwtDesktop-fontFace1] tags.
• display.template - This template displays the complete content on the mail
channel. This file serves as a wrapper around all the other template files. It uses
the [tag:mail-display-summary] , [tag:mail-display-headers] , and
[tag:mail-display-clientURL] tags.
• edit.template - This template displays the edit page of the mail channel on
the user’s html desktop. It uses the [tag:iwtDesktop-fontFace1] ,
[tag:displayHeadersChecked] , [tag:numberHeaders] ,
[tag:topSelected] , [tag:topString] , [tag:bottomSelected] ,
[tag:bottomString] , [tag:IMAPServerName] , [tag:IMAPUserId] ,
[tag:IMAPPassword] , [tag:changeUserInfoChecked] , [tag:clientURL] ,
[tag:clientPort] (see ), [tag:msgCopyInSentChecked] , [tag:signature] ,
and [tag:preset1] to [tag:preset9] (see ) tags.
Figure 4-4 Sample Mail Channel Edit Page
The Mail Provider Template Files
48 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Figure 4-5 Sample Mail Channel Edit Page for Wireless Clients
The Address Book Provider Template Files
Chapter 4 Content Provider Template Files 49
The Address Book Provider Template FilesThe following template files are located in the
/etc/opt/SUNWips/desktop/< locale >/iwtAddressBookProvider/html ,
/etc/opt/SUNWips/desktop/< locale >/iwtAddressBookProvider/chtml/ , and
in the /etc/opt/SUNWips/desktop/< locale >/iwtAddressBookProvider/wml/
directories. These files facilitate the display of the address book channel on all of
the supported clients.
The Address Book Provider Template Files
50 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The address book channel uses the IMAP username and password set by the user
in the address book channel edit page to connect to the mail server. If the IMAP
user name and password fields are left empty in address book channel edit page,
this information is retrieved from the mail channel (edit page), and if it is not found
in the mail channel, then this information is retrieved from the user info channel
(edit page). The channel then displays a summary of the total number of entries in
the user’s address book followed by the actual address book entries.
Figure 4-6 Sample Address Book Channel
• display-clientURL.template - This template displays the link to the address
book application client. It uses the [tag:ab-display-clientURL-appURL]
tag.
• display-error.template - This template displays the error messages. It uses
the [tag:ab-display-error] tag.
• display-summary.template - This template displays the summary
information of the address book channel. It uses the
[tag:ab-display-summary-entries] tag.
• display-entry.template - This template prints out a single address book
entry. Address book entries are displayed in HTML channel only. It uses the
[tag:iwtDesktop-fontFace1] , [tag:ab-display-entry-cbgc] ,
[tag:ab-display-entry-firstname] , [tag:ab-display-entry-lastname] ,
[tag:ab-display-entry-email] , and
[tag:ab-display-entry-email-link] tags.
The Address Book Provider Template Files
Chapter 4 Content Provider Template Files 51
• display-entries.template - This template lists the entire list of address
book entries. Address book entries are displayed in HTML channel only. It
uses the [tag:iwtDesktop-fontFace1] and [tag:ab-display-entry-list]
tags.
• display.template - This template indicates what information needs to be
displayed in the channel. It uses the [tag:ab-display-summary] ,
[tag:ab-display-entries] , and [tag:ab-display-clientURL] tags.
• edit.template - This template displays the edit page of the address book
channel on the user’s HTML desktop. It uses the display-entries.template file
to list the entire list of address book entries. Address book entries are displayed
in the HTML channel only. It uses the [tag:iwtDesktop-fontFace1] ,
[tag:iwtAddressBookProvider-displayEntries] ,
[tag:iwtAddressBookProvider-numEntries] ,
[tag:iwtAddressBookProvider-isNoSorting] ,
[tag:iwtAddressBookProvider-isLnSelected] ,
[tag:iwtAddressBookProvider-isFnSelected] ,
[tag:iwtAddressBookProvider-isUpSelected] ,
[tag:iwtAddressBookProvider-isDownSelected] ,
[tag:iwtAddressBookProvider-IMAPUserId] , and
[tag:iwtAddressBookProvider-IMAPPassword] tags.
Figure 4-7 Sample Address Book Channel Edit Page
The Wireless Personal Notes Provider Template Files
52 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The Wireless Personal Notes Provider Template FilesThe following template files are located in the/etc/opt/SUNWips/desktop/< locale >/iwtWirelessPersonalNoteProvider/html ,/etc/opt/SUNWips/desktop/< locale >/iwtWirelessPersonalNoteProvider/chtml/ , and in the/etc/opt/SUNWips/desktop/< locale >/iwtWirelessPersonalNoteProvider/wml/ directories. These files facilitate the display of the personal notes channel on all
of the supported clients.
• content.template - This file serves as a wrapper around the personal note
content. It uses the [tag:note] tag.
• darkColor.template - This file contains a valid background color value and is
used by a table.
The Wireless Personal Notes Provider Template Files
Chapter 4 Content Provider Template Files 53
• lightColor.template - This template contains a valid background color
value and is used by a table.
• textColor.template - This template contains a valid color value for the text
in the table.
• edit.template - This template displays the edit page for the personal note
channel on the HTML desktop. It defines the layout and editable fields for the
end user to modify or add content. It uses the [tag:iwtDesktop-fontFace1] ,
[tag:noteCount] , and [tag:noteList] tags.
Figure 4-8 Sample Personal Notes Channel Edit Page
• editNoteListWrapper.template - This template serves as a wrapper around
the editable personal note content. It defines the table row and table cells that
are used for the layout, and the display of the personal note content. It uses the
[tag:iwtDesktop-fontFace1] , [tag:removeId] , [tag:nameId] , and
[tag:note] tags.
The PostIt Provider Template Files
54 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
• tableDataWrapper.template - This template serves as a wrapper around the
table datacell content. It specifies the background color of the table datacell (see
darkColor.template and lightColor.template), the text color of the content (see
textColor.template), and the personal note content. It uses the
[tag:iwtDesktop-fontFace1] , [tag:textColor] , and [tag:pnote] tags.
• tableWrapper.template - This template serves as a wrapper around all of the
table datacell content. It is merely the table declaration. It uses the
[tag:tableData] tag.
• linebreak.template - This template contains the markup language specific
element for line break. That is, for chtml, this file contains the "<br>" element
syntax and for wml, it contains the syntax "<br/">.
The PostIt Provider Template FilesThe following template files are located in the
/etc/opt/SUNWips/desktop/< locale >/iwtPostItProvider/chtml/ and in the
/etc/opt/SUNWips/desktop/< locale >/iwtPostItProvider/wml/ directories.
These files facilitate the display of the postit notes channel on all of the supported
clients.
• content.template - This template serves as a wrapper around the postit note
content. It uses the [tag:note] tag.
• linebreak.template - This template contains the markup language specific
element for line break. That is, in cHTML this file contains the "<br>" element
syntax and in WML, it contains the syntax "<br/">.
The Wireless URL Scraper Provider Template FilesThe following template file is located in the/etc/opt/SUNWips/desktop/< locale >/iwtWirelessURLScraperProvider/wml/ directory. These files facilitate the display of the URL Scraper channel on all of
the supported clients.
• link.template - This template displays the page as a link instead of actually
scraping the contents on a WML client. It uses the
[tag:wirelessurlscraper-linkurl] tag.
The UserInfo Provider Template Files
Chapter 4 Content Provider Template Files 55
The UserInfo Provider Template FilesThe following template files are located in the/etc/opt/SUNWips/desktop/< locale >/iwtUserInfoProvider/,/etc/opt/SUNWips/desktop/< locale >/iwtUserInfoProvider/chtml/ and in
the /etc/opt/SUNWips/desktop/< locale >/iwtUserInfoProvider/wml/
directories. These files facilitate the display of the user information channel on all
of the supported clients.
• content.template - This template serves as a wrapper around the user info
channel content. It uses the [tag:iwtUserInfoProvider-firstName] ,
[tag:iwtUserInfoProvider-lastName] , [tag:currentDate] ,
[tag:timeLeft] , and [tag:maxIdle] tags.
• edit.template - This template displays the user information channel edit
page on the HTML desktop. It uses the [tag:iwtDesktop-fontFace1] ,
[tag:iwtUserInfoProvider-firstName] ,
[tag:iwtUserInfoProvider-lastName] ,
[tag:iwtUserInfoProvider-greeting] , [tag:timezoneList] ,
[tag:iwtUser-IMAPServerName] , [tag:iwtUser-SMTPServerName] ,
[tag:iwtUser-IMAPUserId] , [tag:iwtUser-IMAPPassword] ,
[tag:localeList] , and [tag:passwordHandler] tags.
Figure 4-9 Sample User Info Channel Edit Page
The Wireless Bookmarks Provider Template Files
56 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The Wireless Bookmarks Provider Template FilesThe following template files are located in/etc/opt/SUNWips/desktop/default/iwtWirelessBookmarkProvider/html,/etc/opt/SUNWips/desktop/default/iwtBookmarkProvidercHTML/chtml/ and
in /etc/opt/SUNWips/desktop/default/iwtBookmarkProviderWML/wml/
directories. These files facilitate the display of the bookmark channel on all of the
supported clients.
The Wireless Bookmarks Provider Template Files
Chapter 4 Content Provider Template Files 57
• display.template - This template serves as a wrapper around the bookmark
content. It uses the [tag:iwtDesktop-fontFace1] and [tag:bookmarks]
tags.
• edit.template - This template serves as the edit page for the bookmark
channel from the HTML desktop. It defines the layout and editable fields for
the end user to modify or add content. It uses the
[tag:iwtDesktop-fontFace1] , [tag:resourceCount] , and
[tag:resourceList] tags.
Figure 4-10 Sample Bookmarks Channel Edit Page
• urlWrapper.template - This template serves as a wrapper for the URL or
resource. It defines the syntax for the URL. This template is used within
getContent() . It uses the [tag:link] and [tag:name] tags.
The Wireless Bookmarks Provider Template Files
58 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
For WML clients, the template supplied during installation uses a SELECT
object defined within the display.template and uses the
urlWrapper.template to define options for the SELECT (such as, <option
onpick="[tag:link]" value="[tag:name]">[tag:name]</option> ) action.
In cHTML, it defines a URL with the ANCHOR tag such as, <a
href="location">name</a> .
59
Chapter 5
Application JSPs
This chapter discusses the cHTML and WML JSP 1.1 files for iPlanet Messaging
Server, Personal Address Book server, and iPlanet Calendar Server. These files, in
conjunction with the tag libraries (see Chapter 6, “JSP Tag Libraries” for more
information), facilitate the display of the application (for iPlanet Messaging Server,
Personal Address Book, and iPlanet Calendar Server) content on devices that
support these markup languages.
The JSP files are located in<ips_install_base >/SUNWips/public_html/jsp/< locale >/< component >/< clientType > where:
• ips_install_base refers to the installation location of the iPlanet Portal Server
software
• locale refers to the user’s locale
• component refers to either mail, calendar (referred to as cal), or address book
(referred to as ab)
• clientType refers to WML or cHTML clients
Use the templates to configure and customize the content, the layout, and the user
interface of these services for each supported client type.
IntroductionWhen the client connects to the backend calendar, mail, or address book server, the
Mobile Access Pack JSP files for these servers fetch and display the content from
these servers and enable interaction with these servers via the respective tag
libraries. These files are locale and client specific, with multiple clientTypes sharing
the same JSP files. The corresponding calendar, mail, and address book providers
retrieve the appropriate client specific JSP files using the file lookup mechanism.
iPlanet Calendar Server JSPs
60 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
These JSPs and Tag Libraries use the:
• Client data for information on the client’s file path
• File lookup mechanism to retrieve the client specific file
• Profile Service to store and retrieve their own properties
• Session Service to validate the user’s session
• Logging Service to log messages related to the user’s session
The Calendar TagLibs use WCAP to access the Calendar Server. The Mail TagLibs
use the JavaMail API to access the Mail Server. The Address Book TagLibs use the
NSLDAP API to access the Directory Server.
iPlanet Calendar Server JSPsThis section discusses the WML and cHTML template files used by the calendar
client graphical user interface. See the appropriate figure and the files used for the
interfaces (in the figure) to customize the display of the calendar client on the
user’s mobile device. Refer to the “iPlanet Calendar Server Client Tag Library,” on
page 119 for detailed information on the tags used in these template files to enable
interaction with the calendar server from the user’s mobile device.
User Interface FlowchartsThis section discusses the calendar user interface, for WML and cHTML clients,
that utilize the template files discussed in “JSP Files.”
The WML and cHTML screen flowcharts shown in use calHome.jsp and
dayview.jsp . See description of relevant files in Table 5-1 on page 65 for more
information.
Figure 5-1 WML and cHTML Calendar Home Screen Flowcharts
iPlanet Calendar Server JSPs
Chapter 5 Application JSPs 61
The WML and cHTML screen flowcharts shown in use event.jsp , change.jsp ,
and delete.jsp files. See description of relevant files in Table 5-1 on page 65 for
more information.
Figure 5-2 WML and cHTML Screen Flowcharts to View an Event
The WML and cHTML screen flowcharts shown use edit.jsp , add.jsp , and
doAdd.jsp files. See description of relevant files in Table 5-1 on page 65 for more
information.
Figure 5-3 WML and cHTML Screen Flowcharts to Add Event
iPlanet Calendar Server JSPs
62 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The WML and cHTML screen flowcharts shown in use edit.jsp , change.jsp ,
changeType.jsp , and doChange.jsp files. The process of changing an event is
similar to adding an event (see and substitue Add with Change). See description of
relevant files in Table 5-1 on page 65 for more information.
Figure 5-4 WML and cHTML Screen Flowcharts to Change Event
iPlanet Calendar Server JSPs
Chapter 5 Application JSPs 63
The WML and cHTML screen flowcharts shown in use delete.jsp and
deleteType.jsp files. See description of relevant files in Table 5-1 on page 65 for
more information.
Figure 5-5 WML and cHTML Screen Flowcharts to Delete Event
iPlanet Calendar Server JSPs
64 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The WML and cHTML screen flowcharts shown in use date.jsp , doDate.jsp ,
doRoll.jsp , and goto.jsp files. See description of relevant files in Table 5-1 on
page 65 for more information.
Figure 5-6 WMl and cHTML Screen Flowcharts to Browse the Calendar
iPlanet Calendar Server JSPs
Chapter 5 Application JSPs 65
JSP Files
Table 5-1 Calendar JSPs
Filename Description
launchCal.jsp This file launches the calendar client on the user’s mobile device. It uses
the “forward” tag from the utilities tag library to display the
calHome.jsp file (see on page 61).
calHome.jsp This provides the calendar home page. It fetches the events in the calendar
database and forwards it to dayview.jsp (see on page 61).
dayview.jsp It lists all the events for the current date in a summary (see on page 61). It
provides links to:
• Add an event
• Go to a particular date
• Browse through the next 6 days from the current date
edit.jsp It provides the event properties to add or modify an event in the calendar
database.
add.jsp It provides the fields to add an event in the calendar (see on page 62). By
default, specify only the start time, end time, description, summary, and
location (see “event,” on page 129 for details) of the event.
doAdd.jsp It adds the specified event to the calendar database (see on page 62). It
uses the error code CAL_001 (see errorCode) when it is unable to add the
event in the calendar.
change.jsp It provides the fields to change the specified event properties (see on
page 63).
changeType.jsp It provides the fields to specify the type of change to make to the selected
event. By default, specify whether to change this occurance of the event
only, or to change this and all future occurances of the selected event in
the database (see on page 63). This file is required by cHTML clients only.
doChange.jsp It modifies the specified event properties in the calendar database (see on
page 63). It uses the error code CAL_001 (see errorCode) when it is unable
to add the event in the calendar.
date.jsp It provides the fields to specify a date to proceed to (see on page 64). This
is unique to each client type.
doDate.jsp It fetches and displays the events in the specified date (see on page 64). It
uses the error code CAL_001 (see errorCode) when it is unable to add the
event in the calendar.
delete.jsp It deletes the selected event from the calendar database.
iPlanet Calendar Server JSPs
66 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Sample Customizations
To add "Next Year" and "Previous Year" links in the Go To menu (as shown in onpage 64):1. Log in to the Mobile Access Pack server and become superuser.
2. Change directories to
/< iPS_install_base >/SUNWips/public_html/jsp/< locale >/cal/< clientType >.
3. Modify the goto.jsp file. That is, add a link similar to next week for next and
previous years.
Next week
<a href="doRoll.jsp?fd=WEEK_OF_YEAR">Next week</a>
Next Year:
<a href="doRoll.jsp?fd=YEAR">Next year</a>
Previous Year:
<a href="doRoll.jsp?fd=YEAR&amt=-1">Previous year</a>
4. Save and close the file.
"Next year" and "Previous year" must be localized in cal.properties file (in
<iPS_install_base >/SUNWips/locale ) instead of hard coded in the
template.
deleteType.jsp It provides the fields to specify whether to delete this instance of the event
only, or to delete this and all future instances of the selected event in the
database. It is required by cHTML clients only.
doRoll.jsp It handles the dateroll command. It takes the arguments in the URL and
displays the:
• Next 6 days or next week or month (see on page 64)
• Previous week or month (see on page 64)
event.jsp It displays all the details of the selected event (see “event,” on page 129
and on page 61).
goto.jsp It provides a navigation menu to fetch events for today, next week, next
month, previous week, previous month, or a specific date.
Table 5-1 Calendar JSPs
Filename Description
iPlanet Messaging Server JSPs
Chapter 5 Application JSPs 67
To change the time format for a day:1. Log in to the Mobile Access Pack server and become superuser.
2. Change directories to /< iPS_install_base >/SUNWips/locale .
3. Modify the cal.properties file. That is, change the title date format.
datefmt = "EEE MMM d yyyy" to "MMMMM d, yyyy"
The display for the current date will be changed, for example, from "Wed Aug
29 2001" to "August 29, 2001"
4. Save and close the file.
To add event end fields to event list in dayview:1. Log in to the Mobile Access Pack server and become superuser.
2. Change directories to
<iPS_install_base >/SUNWips/public_html/jsp/< locale >/cal/< clientType >.
3. Modify the dayview.jsp file. That is, add the following lines to display the
end time.
<cal:event>
<cal:get id="end" property="endTime"/>
<cal:dateformat name="end" format="$[i18n:timefmt]"/>
</cal:event>
4. Save and close the file.
iPlanet Messaging Server JSPsThis section discusses the WML and cHTML template files used by the messaging
server user interface for a mobile device. See the appropriate figure and the files
used by the interfaces (in the figure) to customize the display of the service content
on the user’s mobile device. Refer to the “iPlanet Messaging Server Client Tag
Library,” on page 135 for detailed information on the tags used in these template
files to enable the display of mail content on the user’s mobile device.
User Interface FlowchartsThis section discusses the mail user interface, for WML and cHTML clients, that
utilize the template files discussed in “JSP Files.”
iPlanet Messaging Server JSPs
68 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The WML and cHTML screen flowcharts shown in use the summary.jsp file. See
Table 5-2 on page 75 for more information on the files.
Figure 5-7 WML and cHTML Mail Home Screen Flowcharts
The WML and cHTML screen flowcharts shown in use inbox.jsp and
doInbox.jsp file. See Table 5-2 on page 75 for more information on the files.
Figure 5-8 WML and cHTML Inbox Screen Flowcharts
The WML and cHTML screen flowcharts shown in use getmsg.jsp and
message.jsp files. See Table 5-2 on page 75 for more information on the files.
Figure 5-9 WML and cHTML Message Screens
iPlanet Messaging Server JSPs
Chapter 5 Application JSPs 69
The WML and cHTML screen flowcharts shown in use addpab.jsp and
doAdd.jsp files. See Table 5-2 on page 75 for more information on the files.
Figure 5-10 WML and cHTML Screen Flowcharts to Add User to the Address Book
The cHTML and WML screen flowcharts shown in and use compose.jsp ,
presetMsg.jsp , typeMsg.jsp , pickaddr.jsp , cancel.jsp , and sent.jsp . See
Table 5-2 on page 75 for more information on the files.
Figure 5-11 cHTML Screen Flowcharts to Compose a Message
iPlanet Messaging Server JSPs
70 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Figure 5-12 WML Screen Flowcharts to Compose a Message
iPlanet Messaging Server JSPs
Chapter 5 Application JSPs 71
iPlanet Messaging Server JSPs
72 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The WML and cHTML screen flowcharts shown in use menu.jsp file. For WML
clients, this is embedded in the message.jsp file. See Table 5-2 on page 75 for more
information on the files.
Figure 5-13 WML and cHML Mail Menu Screens
The WMl and cHTML screen flowcharts shown in use the header.jsp file.
Figure 5-14 WML and cHTML View Headers Screens
The WML and cHTML screen flowcharts shown in and use reply.jsp ,
compose.jsp , presetMsg.jsp , typeMsg.jsp , pickaddr.jsp , cancel.jsp , and
sent.jsp files. Replying and forwarding a message uses the same flow as
composing a message (see also on page 70 and on page 71). See Table 5-2 on
page 75 for more information on the files.
Figure 5-15 cHTML Interface to Reply To or Forward a Message
iPlanet Messaging Server JSPs
Chapter 5 Application JSPs 73
Figure 5-16 WML Interface to Reply to or Forward a Message
iPlanet Messaging Server JSPs
74 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iPlanet Messaging Server JSPs
Chapter 5 Application JSPs 75
JSP Files
Table 5-2 Mail JSPs
Filename Description
launchMail.jsp It launches the mail client on the user’s mobile device (see on page 68).
summary.jsp It provides the mail home page (see on page 68) and displays the Inbox
summary (the total number of messages and the number of unread
messages).
doInbox.jsp it handles the fetch inbox command (see “fetch,” on page 136 and on
page 68).
getmsg.jsp It handles the fetch message command (see “fetch,” on page 136 and on
page 69).
addpab.jsp It provides the fields to add the sender to the personal address book
database (see also add.jsp , doAdd.jsp in Table 5-3, and on page 69).
doAdd.jsp It adds the sender to the Personal Address Book database (see on
page 69). It uses the error code AB_001 (see errorCode) when it is unable
to add the entry to the address book.
cancel.jsp It aborts the send mail operation and returns to the Inbox (see on page 70
and on page 71).
delete.jsp It deletes the selected message from the Inbox.
message.jsp It displays the message headers and body. It also indicates if there is an
attachment, but does not display attachments (see on page 69).
sent.jsp It handles the send command (see “sendmessage,” on page 139 and see on
page 70 and on page 71). It uses the error code MAIL_001 and MAIL_002(see errorCode) when it is unable to send the mail.
compose.jsp It provides the fields to compose a new message (see on page 70 and on
page 71). By default, specify only the email address to send the message
to, the subject, and the text of the message. The text of the message can be
a preset message (see presetMsg.jsp for more information).
header.jsp It displays the message headers in detail. By default, it displays the to, cc,
date, and subject property fields (see on page 72).
inbox.jsp it lists the messages in the Inbox in the reverse order; that is, the last or the
most recent message is displayed first (see on page 68).
pickaddr.jsp It allows the user to pick recipients from the Personal Address Book
database (see on page 70 and on page 71).
reply.jsp It allows the user to reply to the sender or to all recepients of the message
(see on page 73 and on page 74).
iPlanet Messaging Server JSPs
76 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Sample Customizations
To bypass the summary page and display the user’s inbox:1. Log in to the machine running the Mobile Access Pack server and become
superuser.
2. Change directories to
<iPS_install_base >/SUNWips/public_html/jsp/< locale > and in the
launchMail.jsp file, change:
<util:forward comp="mail" file="summary.jsp"/> to <util:forward
comp="mail" file="doInbox.jsp"/>
3. Save and close the file.
To display the number of new messages in the mail summary page:1. Log in to the machine running the Mobile Access Pack server and become
superuser.
2. Change directories to <iPS_install_base >/SUNWips/locale and modify the
mail.properties file. That is, in the mail.properties file, enter:
new=new message(s)
3. Change directories to
<iPS_install_base >/SUNWips/public_html/jsp/< locale >/mail and in
the summary.jsp file (in wml and chtml directories), add lines:
<mail:get property="numNewMsgs"/>
<util:msg name="i18n" key="new"/>
4. Save and close the files.
typeMsg.jsp It allows the user to type the message body (see on page 70). For WML
clients, this is embedded in compose.jsp and reply.jsp (see on
page 71).
menu.jsp It provides a menu of mail box commands including delete, reply to, or
forward a message, add sender to personal address book, view message
header, return to the Inbox or to the Mail Home page (see on page 72).
presetMsg.jsp It allows a message to be saved (or preset) for future use. For WML clients,
this is embedded in compose.jsp and reply.jsp .
Table 5-2 Mail JSPs
Filename Description
iPlanet Messaging Server JSPs
Chapter 5 Application JSPs 77
To include links to the Address Book Home and Search Address Book in the mailsummary page:1. Log in to the machine running the Mobile Access Pack server and become
superuser.
2. Change directories to /< iPS_install_base >/SUNWips/locale and modify
the mail.properties file. That is, in the mail.properties file, enter:
addressbook=Address Book
searchab=Search Address Book
3. Change directories to
<iPS_install_base >/SUNWips/public_html/jsp/< default >/mail and in
the summary.jsp file (in wml and chtml directories), add the following lines to
the end of the file:
%><%-- address book --%>
<util:link tagstart="<a" tagend=">"><%
%><util:attr attr="href"><%
%><util:url file="abHome.jsp" comp="ab"/><%
%></util:attr><%
%></util:link><%
%><util:msg name="i18n" key="addressbook"/>...</a>
%><%-- search address book --%>
<util:link tagstart="<a" tagend=">"><%
%><util:attr attr="href"><%
%><util:url file="search.jsp" comp="ab"/><%
%></util:attr><%
%></util:link><%
%><util:msg name="i18n" key="searchab"/>...</a><%
4. Save and close the files.
Personal Address Book JSPs
78 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Personal Address Book JSPsThis section discusses the WML and cHTML template files used by the address
book client graphical user interface for a mobile device. See the appropriate figure
and the files used by the interfaces (in the figure) to customize the display of the
address book client on the user’s mobile device. Refer to the “Personal Address
Book Client Tag Library,” on page 156 for detailed information on the tags used in
these template files to enable the display of address book content on the user’s
mobile device.
User Interface FlowchartsThis section discusses the address book user interface on WML and cHTML clients
that utilize the template files discussed in “JSP Files.”
The WML and cHTML screens shown in use abHome.jsp and list.jsp files. See
Table 5-3 on page 81 for detailed information on the files.
Figure 5-17 WML and cHTML Address Book Home Screens
The WML and cHTML screens shown in use view.jsp file.
Figure 5-18 WML and cHTML Screens to View a Contact
Personal Address Book JSPs
Chapter 5 Application JSPs 79
The WML and cHTML screens shown in use edit.jsp , add.jsp , and doAdd.jsp
files. See Table 5-3 on page 81 for detailed information on the files.
Figure 5-19 WML and cHTML Screen Flowcharts to Add a Contact
The WML and cHTML screens shown in use edit.jsp , change.jsp , and
doChange.jsp files. See Table 5-3 on page 81 for detailed information on the files.
Figure 5-20 WML and cHTML Screen Flowcharts to Change a Contact
Personal Address Book JSPs
80 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The WML and cHTML screens shown in use delete.jsp file. See Table 5-3 on
page 81 for detailed information on the files.
Figure 5-21 WML and cHTML Screens to Delete a Contact
The WML and cHTML screens shown in use search.jsp , doSearch.jsp , and
list2.jsp files. See Table 5-3 on page 81 for detailed information on the files.
Figure 5-22 WML and cHTML Screen Flowcharts to Search for a Contact
Personal Address Book JSPs
Chapter 5 Application JSPs 81
JSP Files
Table 5-3 Address Book JSPs
Filename Description
launchAB.jsp It launches the address book client on the user’s mobile device (see on
page 78)
abHome.jsp It provides the address book home page for the mobile client (see on
page 78). It verifies the validity of the session and initializes the connection
to the address book database. Once the connection is established, it fetches
all entries (in the sorting order discussed in “fetch,” on page 157) in the
address book database and forwards the entries to list.jsp .
list.jsp It displays all the entries in the address book database on the address book
home page (see on page 78). If there are too many entries, it chunks the
entries.
search.jsp It provides the address book search page to search for an entry in the
address book database (see on page 81). It takes only one entry property
to search for in the database.
Personal Address Book JSPs
82 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Sample Customizations
To enable search on different fields in the address book1. Log in to the machine running the Mobile Access Pack server and become
superuser.
doSearch.jsp It searches the address book database for the specified entry and forwards
the search result to list2.jsp (see on page 81). It can search for only
one entry property (see “entry,” on page 162) in the database.
list2.jsp It displays the results of the search (see “fetch,” on page 157 and on
page 81).
edit.jsp It provides the address book entry properties (see “entry,” on page 162)
for adding (see “add,” on page 159) or changing (see “modify,” on
page 161) an entry in the address book database.
add.jsp It provides the address book add contact page with empty fields to fill in
with the entry properties (see “add,” on page 159 and on page 79). By
default, to add an entry, specify only the first name, last name, email, and
home phone number.
doAdd.jsp It adds the specified entry (using the entry properties passed in the URL)
to the address book database (see on page 79). It uses the error code
AB_001 (see errorCode) when it is unable to add the entry to the address
book.
view.jsp It displays the properties of the specified address book entry on the
address book view contact page (see on page 79).
change.jsp It provides the address book change contact page to modify the specified
entry properties (see “modify,” on page 161 and on page 80). By default,
only the first name, last name, email, and home phone number can be
modified.
doChange.jsp It modifies the specified entry (using the entry id and entry properties
passed in the URL) in the address book database (see on page 80). It uses
the error code AB_001 (see errorCode) when it is unable to modify the
entry in the address book.
delete.jsp It deletes the specified address book entry from the address book database
and returns to the address book home page (see also “delete,” on page 160
and on page 80).
Table 5-3 Address Book JSPs
Filename Description
Personal Address Book JSPs
Chapter 5 Application JSPs 83
2. Change directories to
<ips_install_base >/SUNWips/public_html/jsp/< locale >/ab/< clientType>/<UP or Nokia if clientType is wml> .
3. Modify the search.jsp file. That is, add more <input> wml tags similar to
<input name="str"/> and pass them on to doSearch.jsp similar to <a
href="doSearch.jsp?str=$(str)">Go</a> .
4. Save and close the file.
5. Change directories to
<iPS_install_base >/SUNWips/public_html/jsp/< locale >/ab and modify
the doSearch.jsp file. That is, modify the fetch entry to something similar to
the following:
<ab:fetch ln="$(ln)" fn="$(fn)"/>
6. Save and close the file.
To add field values to address book entriesFor example, in order to add business phone (bp) number in the address book:
1. Log in to the machine running the Mobile Access Pack server and become
superuser.
2. Change directories to
<ips_install_base >/SUNWips/public_html/jsp/< locale >/ab/< clientType>/<UP or Nokia if clientType is wml> .
3. Modify the add.jsp file. That is, add more <input> wml tags similar to
<input name="bp"/> and pass them on to doAdd.jsp similar to <a
href="doAdd.jsp?bp=$(bp)">Go</a> .
4. Save and close the file.
5. Change directories to
<iPS_install_base >/SUNWips/public_html/jsp/< locale >/ab and modify
the doAdd.jsp file. That is:
<ab:set property="bp" value="$(bp)"/>
6. Save and close the file.
To display the error messages:1. Log in to the Mobile Access Pack server and become superuser.
2. Change directories to
<iPS_install_base >/SUNWips/public_html/jsp/< locale >/ .
Personal Address Book JSPs
84 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
3. Modify the error.jsp file. For example, add the following line:
<util:msg name="i18n" key="servererror"/>
<%= exception.toString() %>
This will print out java exception to the mobile device.
85
Chapter 6
JSP Tag Libraries
This chapter discusses the Java Server Page (JSP) tag libraries that facilitate the
delivery of content from the iPlanet Messaging Server, iPlanet Calendar Server,
and the iPlanet Personal Address Book to the user’s mobile device.
For detailed information on the usage of these tags within the Mobile Access Pack
applications, see Chapter 5, “Application JSPs”.
IntroductionThe JSP tag libraries for these applications:
• Maintain client session state using the iPlanet Portal Server session
mechanism.
• Use the iPlanet Portal Server profile interface to retrieve profile information
such as configuration (such as, backend service host/port), authentication
(such as, credentials), and preferences (such as, address book sorting).
• Log error and warning messages through the iPlanet Portal Server logging
interface.
Tag PatternsA tag typically follows one of the following patterns:
Context TagA context tag represents the session state for a valid authenticated connection to a
backend service. This tag verifies that the session is still valid and provides a
context for other tags to make requests to that service. The object a context tag gives
reference to is called the service context.
Tag Patterns
86 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
At the first request, a connection is made to the backend service using the
configuration and authentication information from the portal profile service. The
service context is based upon the current portal session so that it is available across
multiple requests.
Bean TagsA bean tag represents a java bean object to store on the current page context. The
bean properties are retrieved or modified with the get or set tags. The following
tag attributes specify how the bean is found:
• The id attribute creates a new empty bean and stores it in the page context
using the attribute’s value.
• The name attribute value is a bean object. This attribute looks for a property
with the attribute’s value in the page context.
If neither one of these attributes are set, then the current item in an enclosing
collection parent tag is used.
Get tagThe get tag retrieves the value of a property of a bean object and writes it to the
page output.
The property attribute specifies the name of the property to retrieve. If the propertyattribute is not specified, the results of the toString() method of the identified
object will be returned as the results of the get tag.
If there is a name attribute, it is used to locate the bean in the page context. If there is
no name attribute, then the enclosing bean parent tag is used to find the bean object.
Set TagThe set tag modifies the value of a property of a bean object. The property attribute
specifies the name of the property to modify. The value attribute specifies the value
to set the property to. The tag body content is executed only if the tag fails to
modify the bean property.
Collection TagsThese tags provide access to a collection of beans constructed by a preceding
command tag. Information about the collection can be accessed by the properties of
a collection tag.
Tag Patterns
Chapter 6 JSP Tag Libraries 87
This collection is typically stored within a particular service context and is
referenced implicitly by the name of the particular collection tag. For example, the
<mail:messages > tag refers to the current messages collection stored within the
current mail service context.
The id and name attributes permit bean tag like access to the properties of the
collection. This is useful for constructing paginated access to a collection from
within a Java Server Page. The optional beanid attribute, when specified when the
collection is in iterative mode, stores the "current" bean from the collection onto the
page context using the name specified by the beanid attribute.
The collection tags operate in non-iterative and iterative modes, as specified by the
iterate attribute.
In the non-iterative mode, various properties of the collection can be set or
retrieved and the body of a collection tag is processed only once.
In the iterative mode, the body is evaluated until a count property is exhausted (but
at least once), and the iteration begins at an index in the collection as specified by
the start property.
Usage ExamplesThe following reference to a collection tag establishes iteration parameters:
<collection-tag id="example">
<util:set property="start" value="$(start)"/>
<util:set property="count" value="10"/>
</collection-tag>
The following iterates through the collection in the specified manner:
<collection-tag name="example" iterate="true">
Item#<util:get property="indexOne"/>
<bean-tag>
<util:get property="some-bean-specific-property-name"/>
</bean-tag>
</collection-tag>
The following is a demonstration of the construction of a "next page" link
<collection-tag name="example">
<util:if property="nextPage">
<util:link tagstart="<a" tagend=">">
Tag Patterns
88 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<util:attr attr="href">
<url comp="whatever" file="next.jsp">
<parm name="start"><util:getproperty="nextStart"/></util:parm>
</url>
</util:attr>
</util:link>
Next Page</a>
</util:if>
</collection-tag>
Command TagsA command tag makes a request to a backend service. It uses the service context to
make the request. The request arguments come from the tag attributes, request
parameters, or iPlanet Portal Server profile settings. The request stores the results
as properties in a service context and/or as beans on the page context. The tag
body content is executed only if the request fails.
Content TagThe content tag is used to set the content type and charset of the Java Server Page
output stream. The charset is read and set from the user’s iPlanet Portal Server
profile. The content tag, combined with the catalog tags, enables JSP template files
with no localized content to generate localized output (based on message catalogs)
in the correct charset.
Session TagsThis tag provides access to session attributes.
Message Catalog TagsThese tags provide a way to store beans, that are beyond the scope of a page
context, within the scope of a session.
Link TagsThese tags construct dynamically generated link type tags.
Tag Attribute Evaluation
Chapter 6 JSP Tag Libraries 89
Tag Attribute EvaluationBefore processing a tag, the attributes of most tags in the tag libraries are subject to
the following rules of evaluation. If an attribute contains:
• $(parameterName) - This is replaced by the value of the HTTP request
parameter identified by parameterName.
• ${beanName:propertyName} - This is replaced by the value of the bean
property identified by beanName and propertyName. The bean is assumed to
exist on the current page context.
• $[catalogName:key] - This is replaced by the value of the message catalog
entry identified by catalogName and key. The catalogName refers to a catalog
bean placed on the page context by a preceeding catalog tag.
• $/componentName:attributeName[:defaultValue]/ - This is replaced by
the client (device) specific value of the iPlanet Portal Server profile attribute as
identified by componentName and attributeName. If the attribute does not exist, a
null string is returned, unless defaultValue is specified as well.
ExamplesThe following are sample evaluation of some tag attribute values:
Example 1<mail:message id="newmsg">
<mail:set property="to" value=" $(to) "/>
</mail:message>
In the above example, the value of the attribute evaluates to the value of the HTTP
request parameter named to .
Example 2<mail:message name="newmsg">
<mail:set property="to" value=" ${newmsg:to} $(to) "/>
</mail:message>
In the above example, the value of the attribute evaluates to the value of the to
property of the newmsg bean, followed by a space, and then followed by the value
of the HTTP request parameter named to .
Tag Library Error Logging
90 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Tag Library Error LoggingThe Mobile Access Pack tag libraries log error and warning messages in:
/var/opt/SUNWips/debug/mapJsp
This logging functionality is controlled by a property in the iPlanet Portal Server
configuration file:
/etc/opt/SUNWips/platform.conf
For JSP debugging, edit this file. For example, open the platform.conf file and
modify the following property:
ips.debug=warning
Tag Library Quick ReferenceThis section provides an abbreviated list of each tag in the Mobile Access Pack tag
libraries. For detailed information on each library and its collection of tags, refer to
the relevant section in this chapter.
Table 6-1 contains a list of tags from the utilities tag library.
Table 6-1 Utilities Tag Library
Tag Description
Context Tag
context This tag provides reference to the state of the utility service
for a given session.
Link Tags
link This tag constructs a link.
attr This tag adds attributes to a link tag.
url This tag aids in the construction of URLs.
parm This tag adds requests to URLs.
Collection Tags
beans This tag operates on a collection of the specified bean objects,
iterates through that collection, and makes that bean
collection available to the page.
Bean Tags
bean This tag makes a bean object available to the page.
Tag Library Quick Reference
Chapter 6 JSP Tag Libraries 91
Table 6-2 contains a library of tags for the calendar server.
get This tag retrieves the specified property and writes its value
to the page output.
set This tag updates the specified property.
copy This tag copies the specified property value from the source
bean to the target bean.
if This tag tests the specified property and includes the tag body
if the property evaluates to true.
ifnot This tag tests the specified property and includes the tag body
if the property evaluates to false.
list This tag lists all properties of the specified bean to the page
output.
Content Tag
session This tag gives a bean scope to be stored in the session.
Message Catalog Tags
catalog This tag loads a message catalog specified by the resource
attribute and makes it available to the page.
msg This tag gets a message specified by the key attribute from a
message catalog and writes it to the page output.
Content Tag
content This tag is used to set the content type and charset of the JSP
output stream from the user’s iPlanet Portal Server profile.
Command Tags
edit This tag refers to an "edit" bean which specifies that certain
editing be performed upon the enclosed body.
forward This tag performs a "forward" operation, similar to
<jsp:forward>.
include This tag performs an "include" operation, similar to
<jsp:include>.
Table 6-1 Utilities Tag Library
Tag Description
Tag Library Quick Reference
92 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Table 6-3 contains a library of tags for the mail server.
Table 6-2 iPlanet Calendar Server Client Tag Library
Tag Description
Context Tag
context This tag represents the state of the session to the calendar
service.
Command Tags
fetch This tag fetches the specified range of events into the calendar
context.
store This tag stores the specified event into the current calendar
set.
delete This tag deletes the specified event from the current calendar
set.
dateformat This tag either formats a datetime for output or parses one
from an input.
dateroll This tag rolls the specified datetime attribute value forward
or backward.
Bean Tags
datetime This tag provides the date and time bean properties.
event This tag provides the event properties.
get This tag gets the specified event bean property or field.
set This tag sets or updates the specified event bean property or
field.
Collection Tags
events This tag contains a collection of event beans in the calendar
context.
Table 6-3 iPlanet Messaging Server Client Tag Library
Tag Description
Context Tag
context This tag provides reference to the state of the mail service for
a given session.
Tag Library Quick Reference
Chapter 6 JSP Tag Libraries 93
Table 6-4 contains a list of tags from the address book tag library.
Command Tags
fetch This tag fetches a collection of folders (a collection of
messages), messages (a collection of lines), or lines into the
context.
sendmessage This tag sends or forwards an email message.
deletemessage This tag deletes an email message from the current folder.
Bean Tags
folder This tag refers to the current bean or folder within an
enclosing collection or folders <mail:folders>.
message This tag refers to the current bean or message within an
enclosing collection of messages <mail:messages>.
line This tag refers to the current bean or line within an enclosing
collection of lines <mail:lines>.
presetmsg This tag refers to a preset message from a collection of preset
messages.
get This tag retrieves the specified property and writes its value
to the page output.
set This tag updates the specified property.
Collection Tags
folders This tag refers to a collection of folders.
messages This tag refers to a collection of message beans.
lines This tag refers to a collection of line beans.
presetmsgs This tag refers to a collection of preset messages.
Table 6-4 Personal Address Book Client Tag Library
Tag Description
Context Tag
context This tag is used to maintain state between requests. It ensures
that the address book context is present within the current
pageContext.
Table 6-3 iPlanet Messaging Server Client Tag Library
Tag Description
Utilities Tag Library
94 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Utilities Tag LibraryThis tag library implements a collection of utility tags. The Utility Tag Libraries
consists of the following tags:
context
DescriptionThe context tag provides reference to the state of the utility service for a given
session. Use of this tag without a body verifies correct operation of the utility
service.
Tag BodyJava Server Page
PropertiesThe tag has the following properties:
Command Tags
fetch This tag fetches a collection of address book entries and sets
the current collection within the current address book context
(AbContext ).
add This tag adds an entry to the address book.
delete This tag deletes an address book entry.
modify This tag modifies an address book entry.
Bean Tags
entry This tag refers to an address book entry within a collection of
address book entries <ab:entries>.
get This tag retrieves the specified bean property.
set This tag sets a bean property or updates the specified bean
property.
Collection Tags
entries This tag refers to a collection of address book entries or beans.
Table 6-4 Personal Address Book Client Tag Library
Tag Description
Utilities Tag Library
Chapter 6 JSP Tag Libraries 95
ExampleThe following is an example of the context tag:
<util:context>
<util:set property="rfc2396" value="false"/>
<util:set property="urlAmpEntity" value="false"/>
</util:context>
link
DescriptionThis tag constructs a link. The content of the link is dynamically generated.
Tag BodyJava Server Page
AttributesThe tag has the following attributes:
Table 6-5 ipsMail message Tag Properties
Property Description Access
rfc2396 Indicates whether or not the url tag is escaped. If the value is
set to true, the url generated by the url tag is escaped
according to the RFC2396 rules; otherwise, the URL is not
escaped. The default value is true.
Get/Set
urlAmpEntity If value is set to true, the "&" separator in a query string
parameter list constructed by the url tag is rendered as
"&", otherwise, it is rendered as "&". The default value is
true.
Get/Set
Table 6-6 ipsUtils link Tag Attributes
Attribute Description Required?
tagstart Specifies the fragment of text to include prior to the body of
the tag
Yes
tagend Specifies the fragment of text to include after or at the end of
the tag body
Yes
Utilities Tag Library
96 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Example<util:link tagstart="<a" tagend=">">
<util:attr attr="href">
<util:url path="/DesktopServlet"></util:url>
</util:attr>
<util:attr attr="method">GET</util:attr>
</util:link> RETURN HOME</a>
In the above example, the tag generates a link that includes session encoding, if
needed. The path attribute is not subject to the rules of file lookup. The following is
an example of the emitted markup:
<a href="/DesktopServlet?sid=1a34" method="GET">RETURN HOME</a>
attr
DescriptionThis tag adds attributes to a link tag. The content of this tag is dynamically
generated.
Tag BodyJava Server Page
Tag Parent<utilsPrefix:link>
AttributesThe tag has the following attributes:
Example<util:link tagstart="<a" tagend=">">
<util:attr attr="href">
<util:url path="/DesktopServlet"></util:url>
Table 6-7 ipsUtils attr Tag Attributes
Attribute Description Required?
attr Specifies the fragment of text to include before the body of the
tag.
Yes
Utilities Tag Library
Chapter 6 JSP Tag Libraries 97
</util:attr>
<util:attr attr="method">GET</util:attr>
</util:link>RETURN HOME</a>
In the above example, the tag generates a link that includes session encoding, if
needed. The path attribute is not subject to the rules of file lookup. The following is
an example of the emitted markup:
<a href="/DesktopServlet?sid=1a34" method="GET"/>
url
DescriptionThis tag aids in the construction of URLs. The path to the URL can be specified in
the following ways:
• The path attribute can specify a path to be used during the construction of the
URL. Client specific rewriting can not be applied to this value.
• The file and comp attributes can together specify a JSP resource that will be
resolved using client data driven file lookup rules.
Also, query string parameters can be appended to the URL by including the
appropriate parm tags within the body of the url tag. All body content is discarded
except the value of the parm tag.
Tag BodyJava Server Page
Tag Parent<utilsPrefix:attr>
RestrictionsEither the path attribute, or comp and file attributes must be specified.
AttributesThe tag has the following attributes:
Table 6-8 ipsUtil url Tag Attributes
Attribute Description Required?
file Specifies the file to which to generate the URL reference to. If
file is specified, comp must be specified and path must not be
specified
No
Utilities Tag Library
98 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExamplesThe following are examples of the URL tag:
Example 1: The following is an example of url tag usage, with the path attribute:
<util:link tagstart="<a" tagend=">">
<util:attr attr="href">
<util:url path="/DesktopServlet"></util:url>
</util:attr>
<util:attr attr="method">GET</util:attr>
</util:link>RETURN HOME</a>
In the above example, the tag generates a link that includes session encoding, if
needed. The path attribute is not subject to the rules of file lookup. The following is
an example of the emitted markup:
<a href="/DesktopServlet?sid=1a34" method="GET"/>
Example 2: The following is an example of url tag usage, with file and compattributes:
<util:link tagstart="<a" tagend=">">
<util:attr attr="href">
<util:url file="inbox.jsp" comp="mail"></util:url>
</util:attr>
<util:attr attr="method">GET</util:attr>
</util:link>GO HOME</a>
In the above example, this tag generates a link that has been resolved to the correct
path for the client that has requested the page. The session encoding is added as
needed. The following is an example of the emitted markup:
<a href="/jsp/default/mail/wml/inbox.jsp?sid=1a34" method="GET"/>
comp Specifies the component (such as mail, calendar, address
book) that the target file belongs to.
No
path Specifies the path component of the URL. If path is specified,
neither file nor comp must be specified
No
Table 6-8 ipsUtil url Tag Attributes
Attribute Description Required?
Utilities Tag Library
Chapter 6 JSP Tag Libraries 99
parm
DescriptionThis tag adds request parameters to URLs. The following will be added as a query
string parameter to the URL being constructed by an enclosing url tag:
name=BODY
Here, name is a value specified by the parm tag’s name attribute and BODY is
whatever is evaluated as the parm tag’s body.
The urlAmpEntity property of the utility context controls whether the query string
parameter separator is generated as "&" or "&".
Tag BodyJava Server Page
Tag Parent<utilsPrefix:url> or <utilsPrefix:forward>
AttributesThe tag has the following attributes:
Example<util:link tagstart="<a" tagend=">">
<util:attr attr="href">
<util:url path="/DesktopServlet">
<util:parm name="op1">stuff</util:parm>
</util:url>
</util:attr>
<util:attr attr="method">GET</util:attr>
</util:link>GO HOME</a>
Table 6-9 ipsUtil parm Tag Attributes
Attribute Description Required?
name Specifies the name of the URL argument to be generated Yes
Utilities Tag Library
100 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
In the above example, the tag generates a link that includes session encoding, if
needed. The path attribute is not subject to the rules of file lookup. The following is
an example of the resultant markup:
<a href="/DesktopServlet?sid=1a34&op1=stuff" method="GET"/>
beans
DescriptionThis tag operates on a collection of the specified bean objects, iterates through that
collection, and makes that bean collection available to the page.
Tag BodyJava Server Page
RestrictionsIf the id attribute is specified, then a collection of type and size is created. If the nameattribute is specified, then the collection is restored from the page context. The typeattribute specifies the java class name of the object to create for the collection.
AttributesThe tag has the following attributes:
Table 6-10 ipsUtil beans Tag Attributes
Attribute Description Required?
id Specifies the name of the bean collection to create No
name Specifies the name of the bean collection to use No
beanid In iterative mode, stores the "current" bean from the collection
onto the page context using the name specified by this
attribute
No
iterate Specifies whether or not to iterate. By default, it is set to false,
and the collection will not iterate
No
type Specifies the type of the bean; a java class name No
size Specifies the number of beans to create for the collection Yes
Utilities Tag Library
Chapter 6 JSP Tag Libraries 101
Properties
ExamplesThe following are examples of beans collection:
Example 1: The following example creates a list of five dates and sets the seconds
to the index:
<util:beans id="dates" size="5" type="java.util.Date"iterate=”true”>
<util:get property="index" id="index"/>
<util:bean>
<util:set property="seconds" id="index"/>
</util:bean>
</util:beans>
Example 2: The following example iterates through the dates collection:
Table 6-11 ipsUtil beans Tag Properties
Property Description Access
index An integer that indicates the index of the current bean in the
collection.
Get
count An integer that indicates the number of iterations that the
collection must perform.
Get/Set
start An integer that indicates the zero based index from which to
begin the iteration.
Get/Set
end An integer that indicates the zero based index that denotes
the item upon which the iteration will terminate.
Get
startOne Used to indicate the beginning of range of the current
collection that is displayed (such as 10 to 20 messages)
Get
endOne Used to indicate the end of the range of the current collection
that is displayed (such as 10 to 20 messages)
Get
size An integer that indicates the size of the collection being
browsed.
Get
nextPage A boolean that indicates whether or not there are more items
in the collection beyond the current iterations.
Get
prevPage A boolean that indicates whether or not there are items in the
collection preceding the current iterations.
Get
Utilities Tag Library
102 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<util:beans name="dates" iterate=”true”/>
<util:bean>
date = <util:get/>
</util:bean>
</util:beans>
bean
DescriptionThis tag makes a bean object available to the page. It is similar to the
<jsp:useBean> except that it interoperates with the other bean tags in this tag
library.
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The type attribute specifies the java class name of the object to
use or create.
AttributesThe tag has the following attributes:
ExamplesThe following are examples of the bean tag:
Example 1: The following example makes a date available:
<util:bean type="java.util.Date">
date = <util:get/>
Table 6-12 ipsUtil bean Tag Attributes
Attribute Description Required?
id Specifies the name of the bean to create No
name Specifies the name of the bean to use No
type Specifies the type of the bean; a java class name No
Utilities Tag Library
Chapter 6 JSP Tag Libraries 103
</util:bean>
Example 2: The following example makes a specified date available:
<util:bean id="date" type="java.util.Date"/>
date = <util:get name="date"/>
</util:bean>
get
DescriptionThis tag retrieves the specified property and writes its value to the page output.
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The property attribute must be used to specify what to
retrieve. If the property attribute is not specified, then the bean object itself is
retrieved as a string. The id attribute specifies the name to save the retrieved
property as. If the eval attribute is specified, then the value of the attribute is
evaluated and written to the page output.
AttributesThe tag has the following attributes:
Table 6-13 ipsUtil get Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
property Specifies the name of the property to retrieve. If not specified,
then the bean itself is retrieved as a string.
Yes
id Specifies the name to save the retrieved value as No
eval Indicates the attribute to evaluate and write to page output No
edit Specifies the edit bean that will be applied to the returned
value
No
Utilities Tag Library
104 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExamplesThe following are examples of the get tag:
Example 1: The following example gets the date time property from the parent
bean:
<util:bean type="java.util.Date">
time = <util:get property="time"/>
</util:bean>
Example 2: The following example gets the date time property from the specified
bean:
<util:bean id="date" type="java.util.Date"/>
...
time = <util:get name="date" property="time"/>
Example 3: The following example gets the date bean itself as a string:
<util:bean type="java.util.Date">
date = <util:get/>
</util:bean>
Example 4: The following example gets a non-string bean property:
<util:bean: type="Bean">
<util:get property="prop" id="handle"/>
</util:bean>
Example 5: The following example gets an evaluated attribute:
<util:catalog id="catalog" resource="catalog"/>
<util:bean id="bean" type="java.util.Date"/>
Msg = <util:get eval="$[catalog:msg]"/>
Param = <util:get eval="$(requestparam)"/>
Bean = <util:get eval="{bean}"/>
set
DescriptionThis tag updates the specified property.
Utilities Tag Library
Chapter 6 JSP Tag Libraries 105
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The property attribute specifies what to update. The valueattribute specifies the string value to update the property. The id specifies the bean
object value to update the property. Either value or id must be specified.
AttributesThe tag has the following attributes:
ExamplesThe following are examples of the set tag:
Example 1: The following example sets the date time property on the parent bean:
<util:bean type="java.util.Date">
<util:set property="time" value="0"/>
</util:bean>
Example 2: The following example sets the date time property on the named bean:
<util:bean id="date" type="java.util.Date"/>
...
<util:set name="date" property="time" value="0"/>
Example 3: The following example sets a bean onto another bean property:
<util:bean id="one" type="BeanOne"/>
<util:bean id="two" type="Beantwo"/>
Table 6-14 ipsUtil set Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
property Specifies the name of the property to update Yes
value Specifies the string value of the property to update No
id Specifies the bean object value of the property to update No
edit Specifies the edit bean that will be applied to the value prior to
storage
No
Utilities Tag Library
106 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<util:set name="two" id="one" property="one"/>
copy
DescriptionThis tag copies the specified property value from the source bean to the target
bean.
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate.
AttributesThe tag has the following attributes:
ExampleThe following example copies the time property from d1 to d2:
<util:bean name="d1" type="java.util.Date"/>
...
<util:bean name="d2" type="java.util.Date"/>
...
<util:copy name="d2" property="time" source="d1"/>
Table 6-15 ipsUtil copy Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
source Specifies the name of the bean to copy from Yes
property Specifies the name of the property to copy Yes
Utilities Tag Library
Chapter 6 JSP Tag Libraries 107
if
DescriptionThis tag tests the specified property and includes the tag body if the property
evaluates to true.
Tag BodyJava Server Page
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The property attribute specifies what to test. The value attribute
specifies the string value to test the property. The id attribute specifies the bean
object value to test the property. If neither value or id is specified, then the test is
true if the property value is non-null.
AttributesThe tag has the following attributes:
ExamplesThe following are examples of the if bean:
Example 1: The following example tests if the date time equals to zero on the
parent bean:
<util:bean type="java.util.Date">
<util:if property="time" value="0">
... date.time == 0
</util:if>
</util:bean>
Example 2: The following example tests if the date time == 0 on named bean:
Table 6-16 ipsUtil if Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
property Specifies the name of the property to test Yes
value Specifies the string value of the property to test No
id Specifies the bean value of the property to test No
Utilities Tag Library
108 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<util:bean id="date" type="java.util.Date"/>
...
<util:if name="date" property="time" value="0">
... date.time == 0
</util:if>
Example 3: The following example tests if the bean property is non-null:
<util:bean type="Bean">
<util:if property="name">
... Bean.name != null </util:if>
</util:bean>
Example 4: The following example tests using two beans:
<util:bean id="one" type="BeanOne"/>
<util:bean id="two" type="BeanTwo"/>
<util:if name="one" property="bean" id="two">
... one.bean == two
</util:if>
ifnot
DescriptionThis tag tests the specified property and includes the tag body if the property
evaluates to false.
Tag BodyJava Server Page
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The property attribute specifies what to test. The value attribute
specifies the string value to test the property. The id attribute specifies the bean
object value to test the property. If neither value or id is specified, then the test is
true if the property value is non-null.
AttributesThe tag has the following attributes:
Utilities Tag Library
Chapter 6 JSP Tag Libraries 109
ExamplesThe following are examples of the ifnot bean:
Example 1: The following example tests if the date time does not equal to zero on
the parent bean:
<util:bean type="java.util.Date">
<util:ifnot property="time" value="0">
... date.time != 0
</util:ifnot>
</util:bean>
Example 2: The following example tests if the date time does not equal to zero on
the named bean:
<util:bean id="date" type="java.util.Date"/>
...
<util:ifnot name="date" property="time" value="0">
... date.time != 0
</util:ifnot>
Example 3: The following example tests if the bean property is null:
<util:bean type="Bean">
<util:ifnot property="name">
... Bean.name == null
</util:ifnot>
</util:bean>
Example 4: The following example tests using two beans:
Table 6-17 ipsUtil ifnot Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
property Specifies the name of the property to test Yes
value Specifies the string value of the property to test No
id Specifies the bean object value of the property to test No
Utilities Tag Library
110 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<util:bean id="one" type="BeanOne"/>
<util:bean id="two" type="BeanTwo"/>
<util:ifnot name="one" property="bean" id="two">
... one.bean != two
</util:ifnot>
list
DescriptionThis tag lists all properties of the specified bean to the page output. The list format
may not be suitable for markup and should be contained in <PRE> or equivalent
tags.
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, a parent bean tag is used to locate the bean on
which to operate.
ExamplesThe following are examples of the list bean:
Example 1: The following example lists the properties of a parent bean:
<util:bean type="java.util.Date">
<util:list/>
</util:bean>
Example 2: The following example lists the properties of a named bean:
<util:bean id="date" type="java.util.Date"/>
...
<util:list name="date"/>
session
DescriptionThis tag provides access to session attributes.
Utilities Tag Library
Chapter 6 JSP Tag Libraries 111
Tag BodyEmpty
RestrictionsIf the id attribute is specified, then the page attribute is restored using the sessionattribute. If the name attribute is specified, then the session attribute is saved using
the page attribute. If neither attribute is specified, then the session attribute is
removed.
AttributesThe tag has the following attributes:
ExamplesThe following are examples of the session bean:
Example 1: The following example creates a date bean to use:
<util:bean id="now" type="java.util.Date"/>
Example 2: The following example saves that bean into the session attributes:
<util:session name="now" attribute="viewDay"/>
Example 3: The following example restores from the session attributes:
<util:session id="now" attribute="viewDay"/>
Example 4: The following example removes the bean from the session attributes:
<util:session attribute="viewDay"/>
Table 6-18 ipsUtil session Tag Attributes
Attribute Description Required?
id Specifies the name of the page attribute to restore from the
session attribute
No
name Specifies the name of the page attribute to save into the sessionattribute
No
attribute Specifies the name of the session attribute to operate on Yes
Utilities Tag Library
112 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
catalog
DescriptionThis tag loads a message catalog specified by the resource attribute and makes it
available to the page. A message catalog is a locale specific
java.util.ResourceBundle object.
Tag BodyJava Server Page
RestrictionsThe id attribute is used to make the message catalog available after the catalog end
tag. The name attribute is used to make an existing catalog available.
This tag also makes a scripting variable, specified by the id attribute, available. Use
the getMsg(String key) method to get the message string.
AttributesThe tag has the following attributes:
ExamplesThe following are examples of the message catalog:
Example 1: The following example gets a message from a sample catalog:
<util:catalog resource="sample">
Message = <util:msg key="message"/>
</util:catalog>
Example 2: The following example gets a key from a named catalog:
<util:catalog id="sample" resource="sample"/>
Table 6-19 ipsUtil catalog Tag Attributes
Attribute Description Required?
id Specifies the name to save the catalog as when saving the
catalog on the page context. This is also the name for the
scripting variable
No
name Specifies the name to use to retrieve the catalog when
retrieving the catalog from the page context
No
resource Specifies the resource name to locate the message catalog No
Utilities Tag Library
Chapter 6 JSP Tag Libraries 113
...
Message = <util:msg name="sample" key="message"/>
Example 3: The following example gets a key using scripting:
<util:catalog id="sample" resource="sample"/>
...
Message = <%= sample.getMsg("message") %>
msg
DescriptionThis tag gets a message specified by the key attribute from a message catalog and
writes it to the page output.
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, then a parent catalog is used to locate the
message catalog.
AttributesThe tag has the following attributes:
ExamplesThe following are examples of the msg command:
Example 1: The following example gets a message from a sample catalog:
<util:catalog resource="sample">
Message = <util:msg key="message"/>
</util:catalog>
Example 2: The following example gets a key from a named catalog:
Table 6-20 ipsUtil msg Tag Attributes
Attribute Description Required?
name Specifies the name of the message catalog to use No
key Specifies the key used to locate the message in the catalog Yes
Utilities Tag Library
114 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<util:catalog id="sample" resource="sample"/>
...
Message = <util:msg name="sample" key="message"/>
content
DescriptionThe content tag is used to set the contentType and character set of the JSP output
stream from the user’s iPlanet Portal Server profile. The character set used when
the JSP is compiled does not matter since there is no localized content in the JSP.
The content tag enables generating localized output (based on message catalogs) in
the correct character set.
Tag BodyJava Server Page
AttributesThe tag has the following attributes:
ExampleThe following is an example of the content tag usage:
<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN""http://www.wapforum.org/DTD/wml_1.1.xml">
<%@ taglib uri="/taglibs/ips_taglib_util.jar" prefix="util" %>
<util:content type="text/vnd.wap.wml"/>
<util:catalog resource="mail" id="i18n" />
<wml>
<util:link tagstart="<card" tagend=">"><%
%><util:attr attr="ontimer"><%
%><util:url file="doInbox.jsp" comp="mail"></util:url><%
Table 6-21 ipsUtil content Tag Attributes
Attribute Description Required?
type It sets the contentType for the output stream Yes
Utilities Tag Library
Chapter 6 JSP Tag Libraries 115
%></util:attr><%
%></util:link>
<timer value="30"/>
<do type="accept"><%
%><util:link tagstart="<go" tagend="/>"><%
%><util:attr attr="href"><%
%><util:url file="doInbox.jsp" comp="mail"></util:url><%
%></util:attr><%
%></util:link>
</do>
<p>
<b><util:msg name="i18n" key="sendcancel"/></b>
</p>
</card>
</wml>
edit
DescriptionThis tag is used to perform limited editing on the tag body. The edit tag refers to
an "edit" bean which specifies that certain editing be performed upon the enclosed
body. The edit will be performed in the following order:
1. String substitution, if any specified.
2. String truncation, if any specified.
3. Character entity escaping, if any specified.
The edit bean can also be referenced by the get and/or set tags which results in
the appropriate modifications to the values being get or set.
Tag BodyJava Server Page
RestrictionsAt least one attribute must be specified and both the attributes must not be
specified together.
Utilities Tag Library
116 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
AttributesThe tag has the following attributes:
Properties
ExampleThe following is an example to truncate a mail subject line:
<util:edit id="t1">
<util:set property="truncation" value="20"/>
<util:set property="escape" value="true"/>
</util:edit>
...
<util:edit name="t1">
<mail:message>
Table 6-22 ipsUtil edit Tag Attributes
Attribute Description Required?
id Specifies the id of the bean to edit No
name Specifies the name of the bean to use No
Table 6-23 ipsUtil edit Tag Properties
Property Description Access
truncation Specifies the number of characters to truncate the body to Get/Set
escape Specifies whether or not to apply XML style character entity
escaping to the body. For a non-WML device, the characters
that will be escaped are: ‘<‘, ‘>’, ‘&’, and ‘”’. For a WML
device, the characters that will be escaped, in addition to
those for a non-WML device, are: “$” and “‘”.
Get/Set
from If present, specifies that all instances of the indicated value be
replaced by the value specified by the to attribute
Get/Set
to Specifies the string with which to replace all occurrences of
the string specified by the from attribute. If to is not specified,
it defaults to a null string.
Get/Set
Utilities Tag Library
Chapter 6 JSP Tag Libraries 117
<mail:get property="subject"/>
</mail:message>
</util:edit>
...
<mail:get property="subject" edit="t1"/>
forward
DescriptionThis tag performs a "forward" operation, similar to <jsp:forward> , but constructs
the JSP resource name in one of the following two ways:
1. The path attribute can specify a path to be used verbatim during the
construction of the URL. Client data specific rewriting will not be applied to
this value.
2. The file and comp attributes together can specify a JSP resource that will be
resolved using client data driven file lookup rules.
Additionally, query string parameters can be appended to the URL by including
the appropriate parm tags within the body of the forward tag. With the exception
of the parm tags, all body content is discarded.
The parameters that are ultimately passed to the destination resource are the
concatenation of those present in the original request, and those specified in the
body of the forward tag.
Tag BodyJava Server Page
RestrictionsAt least one of the attributes must be specified.
AttributesThe tag has the following attributes:
Table 6-24 ipsUtil forward Tag Attributes
Attribute Description Required?
file Specifies the file to lookup and forward No
comp Specifies the component that the target file belongs to such as
"mail", "cal" (for calendar), or "ab" (for address book)
No
Utilities Tag Library
118 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExampleThe following is a forward tag example usage:
<util:forward file="inbox.jsp" comp="mail"/>
<util:forward file="inbox.jsp" comp="mail">
<util:parm name="parm1">abc</util:parm>
</util:forward>
include
DescriptionThis tag performs an "include" operation, similar to <jsp:include> , but will
construct the JSP resource name in one of the following two ways:
• The path attribute may specify a path to be used verbatim during the
construction of the URL. Client data specific rewriting will not be applied to
this value.
• The file and comp attributes together can specify a JSP resource that will be
resolved using client data driven file lookup rules.
Tag BodyEmpty
RestrictionsAt least one of the attributes must be specified.
AttributesThe tag has the following attributes:
path Specifies the path component of the URL. If path is specified,
neither file nor comp must be specified
No
Table 6-25 ipsUtil include Tag Attributes
Attribute Description Required?
file Specifies the file to lookup and include No
Table 6-24 ipsUtil forward Tag Attributes
Attribute Description Required?
iPlanet Calendar Server Client Tag Library
Chapter 6 JSP Tag Libraries 119
ExampleThe following is an example of the include tag usage:
<util:include file="inbox-common.jsp" comp="mail"/>
iPlanet Calendar Server Client Tag LibraryThis tag library consists of a collection of tags that enables calendar access to any
class of device that utilizes a markup style presentation system. The calendar tag
libraries consists of the following tags.
context
DescriptionThe context tag represents the state of the session to the calendar service. If no
connection exists, then an authenticated session is created and the context for that
session is saved for use across requests.
Pages must have this tag near the top of the page and before using any other tags in
the calendar tag library.
Tag BodyEmpty
PropertiesThe tag provides the following page properties:
comp Specifies the component that the target file belongs to such as
"mail", "cal" (for calendar), or "ab" (for address book)
No
path Specifies the path component of the URL. If path is specified,
neither file nor comp must be specified
No
Table 6-26 Calendar context Tag Properties
Property Description Access
events Indicates the list of current events. This is typically updated
by the fetch tag.
Get
Table 6-25 ipsUtil include Tag Attributes
Attribute Description Required?
iPlanet Calendar Server Client Tag Library
120 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExamplesThe following is an example of the calendar context tag:
<cal:context/>
fetch
DescriptionThis tag fetches the specified range of events into the calendar context. The range is
specified using datetime tags with the id attribute. If an error occurs during
processing, the tag body is evaluated and the remainder of the page is skipped.
Tag BodyJava Server Page
RestrictionsUse either day or both start and end attributes to specify the range of events to fetch.
If no attributes are specified, all events for the current day are retrieved.
AttributesThe tag has the following attributes:
eventSize Indicates the size of the current event list as an integer Get
event Indicates the specified event in the current event list as an
index property
Get
viewDay Indicates the current view day. This can be set by the java
server page to carry the day view across requests
Get/Set
viewDaySet Specifies whether the viewDay property is set or not Get
Table 6-27 Calendar fetch Tag Attributes
Attribute Description Required?
day Specifies an entire day to retrieve No
start Specifies the start time of the range to retrieve No
end Specifies the end time of the range to retrieve No
Table 6-26 Calendar context Tag Properties
Property Description Access
iPlanet Calendar Server Client Tag Library
Chapter 6 JSP Tag Libraries 121
ExamplesThe following are examples of the fetch command:
Example 1: The following example fetches todays events:
<cal:fetch>
... fetch failed ...
</cal:fetch>
Example 2: The following example fetches events for a day:
<cal:datetime id="start"/>
... set start time ...
<cal:fetch day="start">
... fetch failed ...
</cal:fetch>
Example 3: The following example fetches events for a range:
<cal:datetime id="start"/>
<cal:datetime id="end"/>
... set start & end times ...
<cal:fetch start="start" end="end">
... fetch failed ...
</cal:fetch>
store
DescriptionThis tag stores the specified event into the current calendar set. It can either store a
new event or update an existing event. If an error occurs during processing, the tag
body is evaluated and the remainder of the page is skipped.
Tag BodyJava Server Page
RestrictionsIf the name attribute is not specified, then a parent event tag is used to find the
event to operate on. The modifier attribute can only be used to update an existing
event.
iPlanet Calendar Server Client Tag Library
122 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
AttributesThe tag has the following attributes:
The modifier attribute can accept either the string or number as follows:
ExamplesThe following are examples of the store command:
Example 1: The following example stores an event by name:
<cal:event id="event1">
<cal:store name="event1">
...store failed...
</cal:store>
</cal:event>
Example 2: The following example stores an event and all future occurrences:
<cal:event>
<cal:store modifier="THISANDFUTURE">
...store failed...
</cal:store>
Table 6-28 Calendar store Tag Attributes
Attribute Description Required?
name Specifies the name of the event bean to store No
modifier Specifies how to update an existing event (see Table 6-29) No
Table 6-29 Modifier Attribute Values
String Number Description
THISINSTANCE 0 Modify this event instance only
THISANDALL 1 Modify this and all occurrences
THISANDFUTURE 2 Modify this and all future occurrences
THISANDPRIOR 3 Modify this and previous occurrences
iPlanet Calendar Server Client Tag Library
Chapter 6 JSP Tag Libraries 123
</cal:event>
delete
DescriptionThis tag deletes the specified event from the current calendar database. If an error
occurs during processing, the tag body is evaluated and the remainder of the page
is skipped.
Tag BodyJava Server Page
RestrictionsIf the name attribute is not specified then a parent event tag is used to find the
event to operate on. The modifier attribute can only be used to update an existing
event.
AttributesThe tag has the following attributes:
The modifier attribute can accept either the string or number as follows:
Table 6-30 Calendar delete Tag Attributes
Attribute Description Required?
name Specifies the name of the event bean to delete No
modifier Specifies how to modify future events (see Table 6-31) No
Table 6-31 Modifier Attribute Values
String Number Description
THISINSTANCE 0 This event instance only
THISANDALL 1 This and all occurrences
THISANDFUTURE 2 This and all future occurrences
THISANDPRIOR 3 This and previous occurrences
iPlanet Calendar Server Client Tag Library
124 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExamplesThe following are examples of the delete command:
Example 1: The following example deletes an event by name
<cal:event id="event1"/>
<cal:delete name="event1">
...delete failed...
</cal:delete>
</cal:event>
Example 2: The following example deletes an event and all future occurrences
<cal:event>
<cal:delete modifier="THISANDFUTURE">
...delete failed...
</cal:delete>
</cal:event>
dateformat
DescriptionThe dateformat tag either formats a datetime (see “datetime”) for output or
parses one from an input. The format attribute specifies the format to use to format
the output or to parse from input. If the parse attribute is specified, then that value
is used as the parse string to set the specified datetime. If the parse attribute is not
specified, then the datetime is formatted to the page output.
Tag BodyJava Server Page
RestrictionsIf the name attribute is specified, then that datetime bean is used. Otherwise the
parent datetime tag is used.
AttributesThe tag has the following attributes:
iPlanet Calendar Server Client Tag Library
Chapter 6 JSP Tag Libraries 125
PropertiesThe tag provides the following bean properties:
ExamplesThe following are examples of the dateformat command:
Example 1: The following is an example to create a “now” datetime and output in
hours and minutes:
<cal:datetime id="now">
<cal:dateformat name="now" format="hh:mm"/>
</cal:datetime>
Example 2: The following is an example to set datetime from hours and minutes to
parse string:
<cal:datetime>
<cal:dateformat format="hh:mm" parse="10:30"/>
</cal:datetime>
Table 6-32 Calendar dateformat Tag Attributes
Attribute Description Required?
name Specifies the name of the datetime bean to use. If the
datetime bean is not specified, then it searches for a
datetime parent tag
No
format Specifies the java.text.SimpleDateFormat format
string to use to format or parse the datetime bean
Yes
parse Indicates the string to parse into a datetime bean using the
format attribute
No
Table 6-33 ipsCal dateformat Tag Properties
Property Description Access
errorCode Indicates the error code in case the execution of the tag fails.
An empty error code indicates a generic tag execution failure
and CAL_001 indicates that an invalid date has been entered.
Get
iPlanet Calendar Server Client Tag Library
126 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
dateroll
DescriptionThe dateroll tag rolls the specified datetime (see “datetime”) attribute value forward
or backward. If an error occurs during processing, the tag body is evaluated and
the remainder of the page is skipped.
Tag BodyJava Server Page
AttributesThe tag has the following attributes:
Table 6-34 Calendar dateroll Tag Attributes
Attribute Description Required?
name Specifies the datetime bean to operate on. If the datetime bean is
not specified, then it searches for a datetime parent tag.
No
field Specifies the field of the roll and by default, it is set to DATE.
These correspond to fields in java.util.Calendar (see
Table 6-35)
No
amount Specifies the amount of the roll. The amount of roll must be
an integer value. By default, it is set to one. Note that positive
values roll forward and negative values roll backward.
No
Table 6-35 java.util.Calendar field values
Field Description
HOUR hour of the day
HOUR_OF_DAY hour of the day in 24 hour clock
MINUTE minute within hour
SECOND second within minute
DATE day of month
DATE_OF_MONTH day of month
DATE_OF_WEEK day of week; 0-6
DATE_OF_YEAR day of year; 0-365
iPlanet Calendar Server Client Tag Library
Chapter 6 JSP Tag Libraries 127
ExamplesThe following are examples of the dateroll command:
Example 1: The following is an example to roll forward one day from today
<cal:datetime id="now"/>
<cal:dateroll name="now"/>
Example 2: The following is an example to roll forward 2 weeks
<cal:datetime id="now"/>
<cal:dateroll name="now"
amount="2" field="WEEK_OF_YEAR"/>
Example 3: The following is an example to roll back 5 hours
<cal:datetime id="now"/>
<cal:dateroll name="now"
amount="-5" field="HOUR"/>
datetime
DescriptionThe datetime tag provides the date and time bean properties.
Tag BodyJava Server Page
RestrictionsOnly one attribute must be used at a time. The datetime properties are only valid
from the start tag to the end tag.
MONTH month of year
YEAR year
WEEK_OF_MONTH week number in month
WEEK_OF_YEAR week number in year
Table 6-35 java.util.Calendar field values
Field Description
iPlanet Calendar Server Client Tag Library
128 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
ExamplesThe following are examples of the datetime bean:
Example 1: The following is an example is to create a ’now’ datetime at the current
time
<cal:datetime id="now"/>
Example 2: The following is an example is to create a ’start’ datetime with today at
10:30
<cal:datetime id="start">
<cal:set property="hours" value="10"/>
<cal:set property="minutes" value="30"/>
</cal:datetime>
Table 6-36 Calendar datetime Tag Attributes
Attribute Description Required?
id Specifies the id of the bean to create No
name Specifies the name of the bean to use No
Table 6-37 Calendar datetime Tag Properties
Property Description Access
hours Indicates the hour of the time in a 24 hour clock Get/Set
minutes Indicates the minute of the time Get/Set
seconds Indicates the second of the time Get/Set
day Indicates the day of the date Get/Set
month Indicates the month of the date Get/Set
year Indicates the 4 digit year of the date Get/Set
iPlanet Calendar Server Client Tag Library
Chapter 6 JSP Tag Libraries 129
Example 3: The following example uses an existing datetime
<cal:datetime name="now">
Day = <cal:get property="day"/>
Month = <cal:get property="month"/>
Year = <cal:get property="Year"/>
</cal:datetime>
event
DescriptionThis tag provides the event properties.
Tag BodyJava Server Page
RestrictionsOnly one attribute must be used at a time. If no attributes are specified, then the
current event in the parent collection is used. The event properties are only valid
from the start tag to the end tag.
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-38 Calendar event Tag Attributes
Attribute Description Required?
id Specifies the id of the bean to create No
name Specifies the name of the bean to use No
index Specifies the index into the current event list of the event bean
to find
No
iPlanet Calendar Server Client Tag Library
130 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExamplesThe following are examples of the event bean:
Example 1: The following is an example to create a ’new’ event
<cal:event id="new"/>
Example 2: The following is an example to create a ’new’ event with a summary
<cal:event id="new">
<cal:set property="summary" value="Event Summary"/>
</cal:event>
Example 3: The following example uses an existing event:
<cal:event name="now">
Start = <cal:get property="startTime"/>
End = <cal:get property="endTime"/>
Summary = <cal:get property="summary"/>
</cal:event>
Example 4: The following example retrieves an event by id
Table 6-39 Calendar event Tag Properties
Property Description Access
id Indicates the event id in the current calendar set Get
startTime Indicates the start time of the event Get/Set
endTime Indicates the end time of the event Get/Set
description Indicates the long description of the event Get/Set
summary Indicates the short summary of the event Get/Set
location Indicates the location of the event Get/Set
allDay Indicates whether or not the event lasts all day Get/Set
recurrence Indicates whether the event is part of a recurring series of
events
Get
creationTime Indicates the creation time of the event; that is, the datetime Get
modificationTime Indicates the modification time of the event; that is, the
datetime
Get
iPlanet Calendar Server Client Tag Library
Chapter 6 JSP Tag Libraries 131
<cal:event id="event" eventid="$(eid)">
<cal:set property="summary" value="new summary"/>
</cal:event>
Example 5: The following example refers to a current event in the event collection:
<cal:events>
<cal:event>
...
</cal:event>
</cal:events>
events
DescriptionThis tag refers to a collection of event beans in the calendar context. This tag
iterates on its body until the collection is exhausted or as constrained by the startand count properties.
Tag BodyJava Server Page
RestrictionsThe current event collection on the calendar context is used.
AttributesThe tag has the following attributes:
Table 6-40 Calendar events Tag Attributes
Attribute Description Required?
id Specifies the name of the entries collection to create. No
name Specifies the name of the entries collection to use. No
beanid In iterative mode, stores the "current" bean from the collection
onto the page context using the name specified by this
attribute
No
iterate Specifies iteration. It takes a boolean value and is, by default,
set to false and the collection will not iterate.
No
iPlanet Calendar Server Client Tag Library
132 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
PropertiesThe tag provides the following bean properties:
ExampleThe following example enumerates through the event bean collection:
<cal:events iterate=”true”>
<cal:event>
...
</cal:event>
</cal:events>
Table 6-41 Calendar events Tag Properties
Property Description Access
index An integer that indicates the index of the current bean in the
collection.
Get
count An integer that indicates the number of iterations that the
collection must perform.
Get/Set
start An integer that indicates the zero based index from which to
begin the iteration.
Get/Set
end An integer that indicates the zero based index that denotes
the item upon which the iteration will terminate.
Get
startOne Used to indicate the beginning of range of the current
collection that is displayed (such as 10 to 20 events)
Get
endOne Used to indicate the end of the range of the current collection
that is displayed (such as 10 to 20 events)
Get
size An integer that indicates the size of the collection being
browsed.
Get
nextPage A boolean that indicates whether or not there are more items
in the collection beyond the current iterations.
Get
prevPage A boolean that indicates whether or not there are items in the
collection preceding the current iterations.
Get
iPlanet Calendar Server Client Tag Library
Chapter 6 JSP Tag Libraries 133
get
DescriptionThis tag gets the specified event bean property or field.
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. Either property or field attribute can be used to specify what to
retrieve. The id attribute specifies the name to save the retrieved property.
AttributesThe tag has the following attributes:
ExamplesThe following are examples of the get bean:
Example 1: The following is an example to get the event summary property:
<cal:event>
summary=<cal:get property="summary"/>
</cal:event>
Example 2: The following is an example to get the datetime HOURS field:
<cal:datetime>
hours=<cal:get field="HOURS"/>
</cal:datetime>
Table 6-42 Calendar get Tag Attributes
Attribute Description Required?
name Specifies the name of the datetime bean to use No
property Specifies the name of the property to retrieve. If no property
is specified, then the bean is retrieved as a string.
No
field Specifies the name of the java.util.Calendar field to
retrieve
No
id Specifies the name to save the retrieved result as No
iPlanet Calendar Server Client Tag Library
134 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
set
DescriptionThis tag sets or updates the specified event bean property or field. If the property
is already successfully set, it skips the body content. Otherwise, it evaluates the
body content.
Tag BodyJava Server Page
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. Either the property or field attribute must be used to specify
what to update. Either the value or id attribute is used to specify the value of the
property to update.
AttributesThe tag has the following attributes:
ExamplesThe following are examples of the set bean:
Example 1: The following is an example to set the event summary property:
<cal:event>
<cal:set property="summary" value="new summary"/>
</cal:event>
Example 2: The following is an example to set the datetime HOURS field:
Table 6-43 Calendar set Tag Attributes
Attribute Description Required?
name Specifies the name of the datetime bean to use No
property Specifies the name of the property to update No
field Specifies the name of the java.util.Calendar field to
update
No
value Specifies the value of the property to update No
id Specifies the bean object value of the property to update No
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 135
<cal:datetime>
<cal:set field="HOURS" value="10"/>
</cal:datetime>
Example 3: The following is an example to set the event start time to a datetime
bean:
<cal:datetime id="now"/>
<cal:event>
<cal:set property="startTime" id="now"/>
</cal:event>
iPlanet Messaging Server Client Tag LibraryThe tags in this library enable email access to WML and cHTML clients. It consists
of the following tags.
context
DescriptionThis tag provides reference to the state of the mail service for a given session. Use
of this tag without a body verifies the correct operation of the mail service.
Tag BodyJava Server Page
PropertiesThe tag provides the following bean properties:
Table 6-44 ipsMail context Tag Properties
Property Description Access
inboxNumMsgs Specifies the number of messages in the INBOX Get
inboxNumUnreadMsgs Specifies the number of unread messages in the INBOX Get
inboxNumNewMsgs Specifies the number of new messages in the INBOX Get
numMsgs Specifies the number of messages in the current folder Get
numUnreadMsgs Specifies the number of unread messages in the current folder Get
numNewMsgs Specifies the number of new messages in the current folder Get
iPlanet Messaging Server Client Tag Library
136 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExampleThe following is an example of the context tag usage:
<mail:context/>
...
<mail:context>
<p>Number of New Messages:<mail:get property="inboxNumNewMsgs"/>
</mail:context>
fetch
DescriptionThe mail fetch tag builds a collection of the type specified by the collection attribute.
This tag can fetch into the context a collection of:
• Folders, which are a collection of messages from the user’s inbox
• Messages, which are a collection of lines from the user’s message
• Lines
signature Specifies the user’s predefined signature Get
atmsgstart Specifies whether or not there is a message prior to the
current message
Get
atmsgend Specifies the whether or not there is a message following the
current message
Get
nextmsgidx Specifies the index of the message following the message
from which was fetched the current lines collection
Get
prevmsgidx Specifies the index of the message preceding the message
from which was fetched the current lines collection
Get
presetEmpty Specifies whether or not the user has any predefined
messages
Get
doMsgInclude Specifies whether or not to include the original message
within a reply message
Set
includeSig Specifies whether or not to append the user’s signature onto
an outbound message
Set
Table 6-44 ipsMail context Tag Properties
Property Description Access
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 137
A fetch of any given collection type creates a "current" collection of that type; for
example, a fetch of a "messages" collection creates the current "messages" collection.
These "current" collections are associated with the current Mail context.
A fetch of a "lines" collection assumes that id refers to a message within a
"messages" collection that was fetched previously, using the same mail context .
If an error occurs during processing, the tag body is evaluated and the remainder
of the page will be skipped.
Tag BodyJava Server Page
AttributesThe tag has the following attributes:
Table 6-45 ipsMail fetch Tag Attributes
Attribute Description Required?
collection Identifies the type of collection to
fetch
Yes.
id Identifies which collection to fetch If collection is:
Folders, the attribute value is
ignored
Messages, the attribute identifies
the folder to fetch the messages
from
Lines, the attribute identifies
which message to fetch
sb Indicates which field to Sort By. See
Table 6-46 for information on possible
values for this attribute.
If collection is:
Folders, the attribute value is
ignored
Messages, the attribute identifies
by which message field to sort by
Lines, the attribute value is
ignored
iPlanet Messaging Server Client Tag Library
138 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
PropertiesThe tag provides the following bean properties:
ExampleThe following is an example of the fetch command:
sd Specifies the Sort Direction as either
upwards or downwards
If collection is:
Folders, the attribute value can be
up or down
Messages, the attribute value can
be up or down
Lines, the attribute value is
ignored
Table 6-46 ipsMail sb Attribute Values
Possible Values Description
inbox collection left as order of inbox
subject collection sorted by the “subject" field
from collection sorted by the "from" field
date collection sorted by the received date
id collection sorted by the message id
seen collection sorted by the "seen" message flag
recent collection sorted by the "recent" message flag
Table 6-47 ipsMail fetch Tag Properties
Property Description Access
errorCode Indicates the error code in case the execution of the tag fails.
An empty error code indicates a generic tag execution failed
error.
Get
Table 6-45 ipsMail fetch Tag Attributes
Attribute Description Required?
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 139
<mail:context/>
...
<mail:fetch collection="messages" id="INBOX" sb="date" sd="down">
<p>Fail.
</mail:fetch>
...
<mail:fetch collection="lines" id="0">
<p>Fail.
</mail:fetch>
...
<mail:lines>
<mail:line>
<mail:get property="text"/>
</mail:line>
</mail:lines>
sendmessage
DescriptionThis tag sends or forwards an email message. If an error occurs during processing,
the tag body is evaluated and the remainder of the page is skipped.
Tag BodyJava Server Page
AttributesThe tag has the following attributes:
Table 6-48 ipsMail sendmessage Tag Attributes
Attribute Description Required?
msgname Indicates the name of message bean to send or forward Yes
fwdindex Specifies the index of the message to forward No
replyindex Specifies the index of the message to reply to No
iPlanet Messaging Server Client Tag Library
140 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
PropertiesThe tag provides the following bean properties:
ExampleThe following is an example of the sendmessage command:
<mail:context/>
...
<mail:message id="foo">
<mail:set property="to" value="$(to)"/>
<mail:set property="subject" value="$(subject)"/>
<mail:set property="text" value="$(text)"/>
</mail:message>
...
<mail:sendmessage msgname="foo">
<p>Fail.
</mail:sendmessage>
deletemessage
DescriptionThis tag deletes an email message from the current folder. If an error occurs during
processing, the tag body is evaluated and the remainder of the page is skipped.
Tag BodyJava Server Page
Table 6-49 ipsMail sendmessage Tag Properties
Property Description Access
errorCode Indicates the error code in case the execution of the tag fails.
An empty error code indicates a generic tag execution failure,
MAIL_001 indicates that the server was unable to send
message because of invalid email address, and MAIL_002indicates that the server was unable to send message.
Get
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 141
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
ExampleThe following is an example of the deletemessage command:
<mail:context/>
...
<mail:deletemessage index="$(idx)">
<p>Fail.
</mail:deletemessage>
folder
DescriptionThis tag provides the folder properties. This tag refers to the current bean or folder
within an enclosing collection of folders <mail:folders >. The body of this tag can
contain get tags to generate the contents of the specified bean tag or current folder.
Tag BodyJava Server Page
Table 6-50 ipsMail deletemessage Tag Attributes
Attribute Description Required?
index Specifies the message to delete. The index specifies an entry
within the current messages collection.
Yes
Table 6-51 ipsMail deletemessage Tag Properties
Property Description Access
errorCode Indicates the error code in case the execution of the tag fails.
An empty error code indicates a generic tag execution failure.
Get
iPlanet Messaging Server Client Tag Library
142 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Tag Parent<mailPrefix:folders >
PropertiesThe tag provides the following bean properties:
ExampleThe following is an example of the folder tag:
<mail:context/>
...
<mail:fetch collection="folders"/>
...
<mail:folders iterate="true">
<mail:folder>
<p>Folder Name:<mail:get property="name"/>
</mail:folder>
</mail:folders>
folders
DescriptionThis tag refers to a collection of folders in the mail context . This tag iterates upon
its body until the collection is exhausted or as constrained by the start and countproperties.
Tag BodyJava Server Page
RestrictionsThe start and count properties must be set only when the iterate attribute is set to
false.
Table 6-52 ipsMail folder Tag Properties
Property Description Access
name Indicates the name of the folder Get
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 143
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-53 ipsMail folders Tag Attributes
Attribute Description Required?
id Specifies the name of the entries collection to create. No
name Specifies the name of the entries collection to use. No
beanid In iterative mode, stores the "current" bean from the collection
onto the page context using the name specified by this
attribute
No
iterate A boolean that selects iteration. By default, it is set to false
and the collection will not iterate.
No
Table 6-54 ipsMail folders Tag Properties
Property Description Access
index An integer that indicates the index of the current bean in the
collection
Get
count An integer that indicates the number of iterations that the
collection must perform
Get/Set
start An integer that indicates the zero based index from which to
begin the iteration
Get/Set
end An integer that indicates the zero based index that denotes
the item upon which the iteration will terminate
Get
startOne Used to indicate the beginning of range of the current
collection that is displayed (such as 10 to 20 messages)
Get
endOne Used to indicate the end of the range of the current collection
that is displayed (such as 10 to 20 messages)
Get
size An integer that indicates the size of the collection being
browsed
Get
nextPage A boolean that indicates whether or not there are more items
in the collection beyond the current iterations.
Get
iPlanet Messaging Server Client Tag Library
144 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExamplesThe following are examples of the folders tag:
<mail:folders id="folderlist">
<mail:set property="start" value="$(start)"/>
<mail:set property="count" value="5"/>
</mail:folders>
<mail:folders name="folderlist" iterate="true">
<mail:folder>
<p>Folder Name:<mail:get property="name"/>
</mail:folder>
</mail:folders>
message
DescriptionThis tag provides the message properties. It refers to the current bean or message
within an enclosing collection of messages <mail:messages >. A message bean can
be created and referenced by using the id or name attributes. The body of this tag
can contain get or set tags to generate the contents of the specified bean tag or the
current message.
Tag BodyJava Server Page
Tag Parent<mailPrefix:messages >
AttributesThe tag has the following attributes:
prevPage A boolean that indicates whether or not there are items in the
collection preceding the current iterations.
Get
Table 6-54 ipsMail folders Tag Properties
Property Description Access
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 145
PropertiesThe tag provides the following bean properties:
Table 6-55 ipsMail message Tag Attributes
Attribute Description Required?
id Indicates the name of the bean to create No
name Specifies the name of the bean to use No
Table 6-56 ipsMail message Tag Properties
Property Description Access
from Provides access to the full address specified in the "From:"
header (for example, John Doe <[email protected]>).
Get/Set
fromAddress Provides access to just the address specified in the "From:"
header, excluding the comment field (for example,
Get
fromPersonal Provides access to the comment specified in the "From:"
header if there is one, excluding the actual address (for
example, John Doe).
Get
replyTo Provides access to the "Reply-To:" header if the header exists.
If the header does not exist, the same value as the fromproperty is returned.
Get
replyToAddress Provides access to just the address portions of the "Reply-To:"
header if the header exists. If the header does not exist, the
same value as the fromAddress property is returned.
Get
replyToPersonal Provides access to just the comment portions of the
"Reply-To:" header if the header exists and has a comment. If
the header does not exist, the same value as the fromPersonalproperty is returned.
Get
to Provides access to the entire "To:" message header. Get/Set
toAddress Provides access to just the address portions of the "To:"
header.
Get
toAddressReply Provides access to just the address portions of the "To:"
header, excluding any address that matches the user’s.
Get
cc Provides access to the entire "Cc:" message header. Get/Set
iPlanet Messaging Server Client Tag Library
146 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExamplesThe following are examples of the message tag:
<mail:context/>
...
<mail:fetch collection="messages" id="INBOX" sb="date" sd="down"/>
...
<mail:messages id="msgs">
<mail:set property="start" value="$(start)"/>
<mail:set property="count" value="5"/>
</mail:messages>
<mail:messages iterate=”true”>
<mail:message>
<p>Subject: <mail:get property="subject"/>
</mail:message>
</mail:messages>
ccAddress Provides access to just the address portions of the "Cc:"
header.
Get
ccAddressReply Provides access to just the address portions of the "Cc:"
header, excluding any address that matches the sender’s.
Get
bcc Identifies the blind carbon copy target. Get
seen A boolean that indicates if the message has been seen. Get
recent A boolean that indicates if the message is recent. Get
deleted A boolean that indicates if the message is deleted. Get
subject Identifies the message subject Get/Set
date Identifies the message date Get/Set
index Message index Get
text Message text Get/Set
Table 6-56 ipsMail message Tag Properties
Property Description Access
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 147
messages
DescriptionThis tag refers to a collection of message beans in the mail context. This tag iterates
upon its body until the collection is exhausted or as constrained by the start and
count properties.
Tag BodyJava Server Page
RestrictionsThe start and count properties must be set only when the iterate attribute is set to
false.
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-57 ipsMail messages Tag Attributes
Attribute Description Required?
id Specifies the name of the entries collection to create. No
name Specifies the name of the entries collection to use. No
beanid In iterative mode, stores the "current" bean from the collection
onto the page context using the name specified by this
attribute
No
iterate A boolean that selects iteration. By default, it is set to false
and the collection will not iterate.
No
Table 6-58 ipsMail messages Tag Properties
Property Description Access
index An integer that indicates the index of the current bean in the
collection.
Get
count An integer that indicates the number of iterations that the
collection must perform.
Get/Set
iPlanet Messaging Server Client Tag Library
148 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExampleThe following are examples of the messages tag:
<mail:context/>
...
<mail:fetch collection="messages" id="INBOX" sb="date" sd="down"/>
...
<mail:messages id="msgs">
<mail:set property="start" value="$(start)"/>
<mail:set property="count" value="5"/>
</mail:messages>
<mail:messages name="msgs" iterate="true">
<mail:message>
<p>Subject: <mail:get property="subject"/>
</mail:message>
</mail:messages>
start An integer that indicates the zero based index from which to
begin the iteration.
Get/Set
end An integer that indicates the zero based index that denotes
the item upon which the iteration will terminate.
Get
startOne Used to indicate the beginning of range of the current
collection that is displayed (such as 10 to 20 messages)
Get
endOne Used to indicate the end of the range of the current collection
that is displayed (such as 10 to 20 messages)
Get
size An integer that indicates the size of the collection being
browsed.
Get
nextPage A boolean that indicates whether or not there are more items
in the collection beyond the current iterations.
Get
prevPage A boolean that indicates whether or not there are items in the
collection preceding the current iterations.
Get
Table 6-58 ipsMail messages Tag Properties
Property Description Access
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 149
line
DescriptionThis tag provides the line properties. This tag refers to the current bean or line
within an enclosing collection of lines <mail:lines >. The body of this tag can
contain get tag to generate output derived from the contents of the line tag.
Tag BodyJava Server Page
Tag Parent<mailPrefix:lines >
PropertiesThe tag provides the following bean properties:
ExampleThe following is an example of the line tag:
<mail:context/>
...
<mail:fetch collection="lines" id="$(msgidx)"/>
...
<mail:lines id="list">
<mail:set property="start" value="$(start)"/>
<mail:set property="count" value="5"/>
</mail:lines>
<mail:lines iterate=”true”>
<mail:line>
<mail:get property="text"/>
</mail:line>
Table 6-59 ipsMail line Tag Properties
Property Description Access
text Refers to the current line of text Get
iPlanet Messaging Server Client Tag Library
150 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
</mail:lines>
lines
DescriptionThis tag refers to a collection of line beans. This tag iterates upon its body until the
collection is exhausted or as constrained by the start and count properties.
Tag BodyJava Server Page
RestrictionsThe start and count properties must be set only when the iterate attribute is set to
false.
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-60 ipsMail lines Tag Attributes
Attribute Description Required?
id Specifies the name of the entries collection to create. No
name Specifies the name of the entries collection to use. No
beanid In iterative mode, stores the "current" bean from the collection
onto the page context using the name specified by this
attribute
No
iterate A boolean that selects iteration. By default, it is set to false
and the collection will not iterate.
No
Table 6-61 ipsMail lines Tag Properties
Property Description Access
index An integer that indicates the index of the current bean in the
collection.
Get
count An integer that indicates the number of iterations that the
collection must perform.
Get/Set
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 151
ExamplesThe following are examples of the lines tag:
<mail:context/>
...
<mail:fetch collection="lines" id="$(msgidx)"/>
...
<mail:lines id="list">
<mail:set property="start" value="$(start)"/>
<mail:set property="count" value="5"/>
</mail:lines>
<mail:lines name="list" iterate="true">
<mail:line>
<mail:get property="text"/>
</mail:line>
</mail:lines>
start An integer that indicates the zero based index from which to
begin the iteration.
Get/Set
end An integer that indicates the zero based index that denotes
the item upon which the iteration will terminate.
Get
startOne Used to indicate the beginning of range of the current
collection that is displayed (such as 10 to 20 lines)
Get
endOne Used to indicate the end of the range of the current collection
that is displayed (such as 10 to 20 lines)
Get
size An integer that indicates the size of the collection being
browsed.
Get
nextPage A boolean that indicates whether or not there are more items
in the collection beyond the current iterations.
Get
prevPage A boolean that indicates whether or not there are items in the
collection preceding the current iterations.
Get
Table 6-61 ipsMail lines Tag Properties
Property Description Access
iPlanet Messaging Server Client Tag Library
152 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
presetmsg
DescriptionThis tag refers to a preset message from a collection of preset messages. It provides
access to the properties of the current message from the preset messages collection.
Tag BodyJava Server Page
RestrictionsThe presetmsg tag can only be used with the presetmsgs collection tag to provide
access to the current preset message in the collection.
PropertiesThe tag provides the following bean properties:
ExampleThe following is an example of the presetmsg bean:
<mail:presetmsgs iterate=”true”>
<mail:presetmsg>
preset msg text = <mail:get property="msg"/>
</mail:presetmsg>
</mail:presetmsgs>
presetmsgs
DescriptionThis tag refers to a collection of preset messages. It provides access to the collection
of preset messages. The tag body is evaluated once for each item in the collection or
as constrained by the start and count properties.
Table 6-62 ipsMail presetmsg Tag Properties
Property Description Access
msg Refers to the text of the preset message. Get
number Refers to the number of the preset message Get
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 153
Tag BodyJava Server Page
RestrictionsUse the presetmsg tag to access a preset message from the collection. The start and
count properties must be set only when the iterate attribute is set to false.
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-63 ipsMail presetmsgs Tag Attributes
Attribute Description Required?
id Specifies the name of the presetmsgs collection to create. No
name Specifies the name of the presetmsgs collection to use. No
beanid In iterative mode, stores the "current" bean from the collection
onto the page context using the name specified by this
attribute
No
iterate A boolean that selects iteration. By default, it is set to false
and the collection will not iterate.
No
Table 6-64 ipsMail presetmsgs Tag Properties
Property Description Access
index An integer that indicates the index of the current bean in the
collection.
Get
count An integer that indicates the number of iterations that the
collection must perform.
Get/Set
start An integer that indicates the zero based index from which to
begin the iteration.
Get/Set
end An integer that indicates the zero based index that denotes
the item upon which the iteration will terminate.
Get
startOne Used to indicate the beginning of range of the current
collection that is displayed (such as 1 to 9 messages)
Get
iPlanet Messaging Server Client Tag Library
154 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExampleThe following is an example of the presetmsgs collection:
<mail:presetmsgs iterate=”true”>
<mail:presetmsg>
preset msg text = <mail:get property="msg"/>
</mail:presetmsg>
</mail:presetmsgs>
get
DescriptionThis tag retrieves the specified property and writes its value to the page output.
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The property attribute must be used to specify what to
retrieve. If the property attribute is not specified, then the bean object itself is
retrieved as a string. The id attribute specifies the name to save the retrieved
property. If the eval attribute is specified, then the value of the attribute is
evaluated and written to the page output.
AttributesThe tag has the following attributes:
endOne Used to indicate the end of the range of the current collection
that is displayed (such as 1 to 9 messages)
Get
size An integer that indicates the size of the collection being
browsed.
Get
nextPage A boolean that indicates whether or not there are more items
in the collection beyond the current iterations.
Get
prevPage A boolean that indicates whether or not there are items in the
collection preceding the current iterations.
Get
Table 6-64 ipsMail presetmsgs Tag Properties
Property Description Access
iPlanet Messaging Server Client Tag Library
Chapter 6 JSP Tag Libraries 155
ExampleThe following is an example to get the subject property:
<mail:message>
<mail:get property="subject"/>
</mail:message>
set
DescriptionThis tag updates the specified property.
Tag BodyEmpty
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The property attribute specifies what to update. The valueattribute specifies the string value to update the property. The id specifies the bean
object value to update the property. Either value or id must be specified.
AttributesThe tag has the following attributes:
Table 6-65 ipsMail get Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
property Specifies the name of the property to retrieve. If not specified,
then the bean itself is retrieved as a string.
Yes
id Specifies the name to save the retrieved value as No
eval Indicates the attribute to evaluate and write to page output No
edit Specifies the edit bean that will be applied to the returned
value
No
Personal Address Book Client Tag Library
156 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExampleThe following is an example to set the message subject property:
<mail:message>
<mail:set property="subject" value="new subject"/>
</mail:message>
Personal Address Book Client Tag LibraryThis address book tag library consists of a collection of tags that enables address
book access to WML and cHTML clients. The address book tag library consists of
the following tags:
context
DescriptionThis tag is used to maintain address book state between requests. It must appear
before all other tags within the ipsAb tag library.
Tag BodyJava Server Page or Empty
PropertiesThe tag provides the following bean properties:
Table 6-66 ipsMail set Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
property Specifies the name of the property to update Yes
value Specifies the string value of the property to update No
id Specifies the bean object value of the property to update No
edit Specifies the edit bean that will be applied to the value prior to
storage
No
Personal Address Book Client Tag Library
Chapter 6 JSP Tag Libraries 157
ExampleThe following is an example of the context tag usage:
<%@ taglib uri="/taglibs/ips_taglib_ab.jar" prefix="ab" %>
<ab:context/>
<ab:fetch any="$(any)" ln="$(ln)" fn="$(fn)" bp="$(bp)" em="$(em)"hp="$(hp)" fp="$(fp)" mp="$(mp)" pp="$(pp)" sb="ln" sd="up">
Error in Looking up address book.
</ab:fetch>
Number of Address Book entries:
<ab:context>
<ab:get property="numEntries"/>
</ab:context>
fetch
DescriptionThe fetch tag sets the current collection within the current address book context. If
no attributes (see Table 6-68) are specified, the entire address book is returned
within the collection. If an error occurs during processing, the tag body is
evaluated and the remainder of the page is skipped.
All of the search attributes support simple wildcard expressions, using the ’*’
character. If the wildcard is not specified, the ’*’ character is prepended and
appended to the search expression to yield a search pattern that produces results
that match any entry that at least contains the requested string.
Tag BodyJava Server Page
Table 6-67 ipsAb context Tag Properties
Property Description Access
numEntries Specifies the number of entries in the address book Get
entriesEmpty Specifies whether or not the address book is empty Get
Personal Address Book Client Tag Library
158 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
RestrictionsOnly sb and sd attributes can be used with the any attribute.
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-68 ipsAB fetch Tag Attributes
Attribute Description Required?
sb Sort By attribute specifies how to sort the address book entries No
sd Sort Direction attribute specifies WHAT DIRECTION? No
fn First Name attribute indicates that search must be performed
by first name
No
ln Last Name attribute indicates that the search must be
performed by last name
No
em Email Address attribute indicates that the search must be
performed by email address
No
bp Business Phone attribute indicates that the search must be
performed by business phone number
No
hp Home Phone attribute indicates that the search must be
performed by home phone number
No
fp Fax Phone attribute indicates that the search must be
performed by fax phone number
No
mp Mobile Phone attribute indicates that the search must be
performed by mobile phone number
No
pp Pager Phone attribute indicates that the search must be
performed by pager phone number
No
any This attribute indicates that all the fields must be searched for
any match
No
Table 6-69 ipsAb fetch Tag Properties
Property Description Access
errorCode Indicates the error code in case the execution of the tag fails.
An empty error code indicates a generic tag execution failure.
Get
Personal Address Book Client Tag Library
Chapter 6 JSP Tag Libraries 159
ExampleThe following is an example of the fetch command:
<%@ taglib uri="/taglibs/ips_taglib_ab.jar" prefix="ab" %>
<ab:context/>
<ab:fetch ln="$(ln)" fn="$(fn)" bp="$(bp)" em="$(em)" hp="$(
hp)" fp="$(fp)" mp="$(mp)" pp="$(pp)" sb="ln" sd="up">
Error in Looking up address book.
</ab:fetch>
add
DescriptionThe add tag adds an entry to the address book. If an error occurs during processing,
the tag body is evaluated and the remainder of the page is skipped.
Tag BodyJava Server Page
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-70 ipsAb add Tag attributes
Attribute Description Required?
name Indicates the name of the address book entry bean to add and
store
Yes
Table 6-71 ipsAb add Tag Properties
Property Description Access
errorCode Indicates the error code in case the execution of the tag fails.
An empty error code indicates a generic tag execution failure
and AB_001 indicates that the add command failed because
last name was not entered.
Get
Personal Address Book Client Tag Library
160 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExampleThe following is an example of the add command:
<%@ taglib uri="/taglibs/ips_taglib_ab.jar" prefix="ab" %>
<ab:context/>
<ab:entry id="addentry">
<ab:set property="fn" value="$(fn)"/>
<ab:set property="ln" value="$(ln)"/>
<ab:set property="em" value="$(em)"/>
</ab:entry>
<ab:add name="addentry">
Problem adding Entry
</ab:add>
Entry added successfully
delete
DescriptionThe delete tag deletes an address book entry. If an error occurs during processing,
the tag body is evaluated and the remainder of the page is skipped.
Tag BodyJava Server Page
RestrictionsThis tag must be used before a fetch or collection tag.
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-72 ipsAb delete Tag Attributes
Attribute Description Required?
entryid Specifies the address book entry to delete Yes
Personal Address Book Client Tag Library
Chapter 6 JSP Tag Libraries 161
ExampleThe following is an example of the delete command:
<%@ taglib uri="/taglibs/ips_taglib_ab.jar" prefix="ab" %>
<ab:context/>
<ab:delete entryid="$(entryid)">
Problem deleting Entry
</ab:delete>
Entry deleted successfully
modify
DescriptionThe modify tag modifies an address book entry. If an error occurs during
processing, the tag body is evaluated and the remainder of the page is skipped.
Tag BodyJava Server Page
RestrictionsThis tag must be used before a fetch or collection tag.
AttributesThe tag has the following attributes:
Table 6-73 ipsAb delete Tag Properties
Property Description Access
errorCode Indicates the error code in case the execution of the tag fails.
An empty error code indicates a generic tag execution failure.
Get
Table 6-74 ipsAb modify Tag Attributes
Attribute Description Required?
name Indicates the name of the address book entry bean that
requires the modifications.
Yes
entryid Specifies the address book entry to modify. Yes
Personal Address Book Client Tag Library
162 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
PropertiesThe tag provides the following bean properties:
ExampleThe following is an example of the modify command:
<%@ taglib uri="/taglibs/ips_taglib_ab.jar" prefix="ab" %>
<ab:context/>
<ab:entry id="modentry">
<ab:set property="fn" value="$(fn)"/>
<ab:set property="ln" value="$(ln)"/>
<ab:set property="em" value="$(em)"/>
</ab:entry>
<ab:modify name="modentry" entryid="$(entryid)">
Problem modifying Entry
</ab:modify>
Entry modified successfully
entry
DescriptionThis tag provides the properties for an address book entry. This tag refers to an
address book entry within a collection of address book entries <ab:entries >. The
body of this tag can contain get or set tags to generate the contents of the specified
bean tag or entry.
Tag BodyJava Server Page
Table 6-75 ipsAb modify Tag Properties
Property Description Access
errorCode Indicates the error code in case the execution of the tag fails.
An empty error code indicates a generic tag execution failure
and AB_001 indicates that the modification failed because
last name was not entered.
Get
Personal Address Book Client Tag Library
Chapter 6 JSP Tag Libraries 163
Tag Parent<abPrefix: entries >
RestrictionsOnly one attribute must be used at a time. If no attributes are specified, then the
current entry in the parent collection is used.
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
ExamplesThe following are examples of the entry bean:
Table 6-76 ipsAb entry Tag Attributes
Attribute Description Required?
id Specifies the id of the bean or entry to create No
name Specifies the name of the bean or entry to use No
entryid Specifies the address book entry id to use No
Table 6-77 ipsAb entry Tag Properties
Property Description Access
fn Refers to the first name Get/Set
ln Refers to the last name Get/Set
em Refers to the email address Get/Set
bp Refers to the business phone Get/Set
hp Refers to the home phone Get/Set
fp Refers to the fax phone Get/Set
mp Refers to the mobile phone Get/Set
pp Refers to the pager phone Get/Set
entryid Refers to the id of an address book entry Get/Set
Personal Address Book Client Tag Library
164 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Example 1: The following is an example of the current entry in the entries
collection:
<ab:context>
<ab:get property="numEntries"/>
</ab:context>
<ab:entries iterate=”true”>
<ab:entry>
Entry Id: <ab:get property="entryid"/>
First Name: <ab:get property="fn"/>
Last Name: <ab:get property="ln"/>
Email: <ab:get property="em"/>
</ab:entry>
</ab:entries>
Example 2: The following example retrieves an entry by entryid:
<ab:entries iterate=”true”>
<ab:entry entryid="$(entryid)">
First Name: <ab:get property="fn"/>
Last Name: <ab:get property="ln"/>
Email: <ab:get property="em"/>
</ab:entry>
</ab:entries>
entries
DescriptionThis tag refers to a collection of address book entries or beans in the address book
context. This tag iterates upon its body until the collection is exhausted or as
constrained by the start and count properties.
Tag BodyJava Server Page
Personal Address Book Client Tag Library
Chapter 6 JSP Tag Libraries 165
RestrictionsThe Address Book fetch command must be sent before invoking this tag. The startand count properties must be set only when the iterate attribute is set to false.
AttributesThe tag has the following attributes:
PropertiesThe tag provides the following bean properties:
Table 6-78 ipsAb entries Tag Attributes
Attribute Description Required?
id Specifies the name of the entries collection to create. No
name Specifies the name of the entries collection to use. No
beanid In iterative mode, stores the "current" bean from the collection
onto the page context using the name specified by this
attribute
No
iterate A boolean that selects iteration. By default, it is set to false
and the collection will not iterate.
No
Table 6-79 ipsAb entries Tag Properties
Property Description Access
index An integer that indicates the index of the current bean in the
collection.
Get
count An integer that indicates the number of iterations that the
collection must perform.
Get/Set
start An integer that indicates the zero based index from which to
begin the iteration.
Get/Set
end An integer that indicates the zero based index that denotes
the item upon which the iteration will terminate.
Get
startOne Used to indicate the beginning of range of the current
collection that is displayed (such as 10 to 20 entries)
Get
endOne Used to indicate the end of the range of the current collection
that is displayed (such as 10 to 20 entries)
Get
size An integer that indicates the size of the collection being
browsed.
Get
Personal Address Book Client Tag Library
166 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
ExampleThe following is an example of the entries tag:
<ab:context>
<ab:get property="numEntries"/>
</ab:context>
<ab:entries iterate=”true”>
<ab:entry>
Entry Id: <ab:get property="entryid"/>
First Name: <ab:get property="fn"/>
Last Name: <ab:get property="ln"/>
Email: <ab:get property="em"/>
</ab:entry>
</ab:entries>
get
DescriptionThis tag retrieves the specified bean property.
Tag BodyEmpty
nextPage A boolean that indicates whether or not there are more items
in the collection beyond the current iterations.
Get
prevPage A boolean that indicates whether or not there are items in the
collection preceding the current iterations.
Get
Table 6-79 ipsAb entries Tag Properties
Property Description Access
Personal Address Book Client Tag Library
Chapter 6 JSP Tag Libraries 167
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The property attribute must be used to specify what to retrieve.
If the property to retrieve is not specified, then the bean object itself is retrieved as a
string. The id attribute specifies the name to save the retrieved property as. If the
eval attribute is specified, then the value of the attribute is evaluated and written to
the page output.
AttributesThe tag has the following attributes:
ExamplesThe following is an example of the get bean:
<%@ taglib uri="/taglibs/ips_taglib_ab.jar" prefix="ab" %>
<ab:context/>
<ab:fetch ln="$(ln)" fn="$(fn)" bp="$(bp)" em="$(em)" hp="$(
hp)" fp="$(fp)" mp="$(mp)" pp="$(pp)" sb="ln" sd="up">
Error in Looking up address book.
</ab:fetch>
Number of Address Book entries:
<ab:context>
<ab:get property="numEntries"/>
</ab:context>
<ab:entries>
<ab:entry>
Table 6-80 ipsAb get Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
property Specifies the name of the property to retrieve Yes
id Specifies the name to save the retrieved value as No
eval Specifies the attribute to evaluate and write to page output No
edit Specifies the edit bean that will be applied to the returned
value
No
Personal Address Book Client Tag Library
168 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Entry Id: <ab:get property="entryid"/>
First Name: <ab:get property="fn"/>
Last Name: <ab:get property="ln"/>
Email: <ab:get property="em"/>
</ab:entry>
</ab:entries>
set
DescriptionThis tag sets a bean property or updates the specified bean property.
Tag BodyJava Server Page
RestrictionsIf the name attribute is not specified, then it uses a parent bean tag to locate the bean
on which to operate. The property attribute specifies what to update. The valueattribute specifies the string value to update the property with. The id attribute
specifies the bean object value to update the property with. Either value or idattribute must be specified.
AttributesThe tag has the following attributes:
ExamplesThe following is an example of the set bean:
Table 6-81 ipsAb set Tag Attributes
Attribute Description Required?
name Specifies the name of the bean to use No
property Specifies the name of the property to set or update Yes
value Specifies the string value of the property to set or update No
id Specifies the bean object value of the property to update No
edit Specifies the edit bean that will be applied to value prior to
storage
No
Personal Address Book Client Tag Library
Chapter 6 JSP Tag Libraries 169
<%@ taglib uri="/taglibs/ips_taglib_ab.jar" prefix="ab" %>
<ab:context/>
<ab:entry id="addentry">
<ab:set property="fn" value="$(fn)"/>
<ab:set property="ln" value="$(ln)"/>
<ab:set property="em" value="$(em)"/>
</ab:entry>
<ab:add name="addentry">
Problem saving Entry
</ab:add>
Entry saved successfully
Personal Address Book Client Tag Library
170 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
171
Chapter 7
Tag Swapper Tags
This chapter discusses the tag swapper tags used by the Mobile Access Pack server
components. These tags are used in the template files to dynamically generate
content. That is, the tags provide the method to insert dynamic data into static
template files. The value of these tags are described in the following sections.
For detailed information on usage of these tags in template files, see Chapter 3,
“Desktop Template Files” and Chapter 4, “Content Provider Template Files.”
The Desktop TagsThe following tags are used in the iwtDesktop component template files (see
Chapter 3, “Desktop Template Files” for more information).
Table 7-1 iwtDesktop Tags
Tag Description
[tag:iwtDesktop-fontFace1] This tag is substituted with the font face value used by the html
<font> tag
[tag:productName] This tag is substituted with the vlue of the
iwtPlatform-productName attribute value
[tag:content] This tag is substituted with the channel or provider content
[tag:style] These tags are substituted with the contents of style.html ,
banner.html , devicemenubar.html , and menubar.htmltemplate files respectively
[tag:banner]
[tag:devicemenubar]
[tag:menubar]
[tag:title] These tags are substituted with the channel title and description
respectively[tag:description]
The Desktop Tags
172 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
[tag:links] This contains the links to the providers on the home page for WML
and cHTML clients
[tag:URL] This tag is substituted with the URL
[tag:charset] This tag is substituted with the list of available character sets
[tag:charsetchoices] This tag is substituted with the list of character sets available for the
specified clientType. It gets its value from the
charsetChoices.template file
[tag:semiColonSelectedList] This tag is used to display the user defined selections as checked
when the user selects the Contens page. The list of selected options
are delimited by a semicolon
[tag:noCache] See Page 100 in the iPlanet Portal Server 3.0 Programmer’s
Reference Guide for a description of these tags. These tags are
substituted with the content for noCache.html and
openFrontPage.js template files respectively
[tag:openFrontPage]
[tag:openContentPage] This tag displays the page to select channels for the mobile device.
This uses the content in the openContentPage.js file in the
/etc/opt/SUNWips/desktop/< locale >/iwtDesktop/htmldirectory
[tag:openLayoutPage] This tag displays the page to arrange the content layout on the
mobile device. This uses thecontent in the openLayoutPage.jsfile in the
/etc/opt/SUNWips/desktop/< locale >/iwtDesktop/htmldirectory
[tag:openConfigurationPage] This tag displays the page to add or remove mobile devices from the
user’s desktop. This uses the content in the
openConfigurationPage.js file in the
/etc/opt/SUNWips/desktop/< locale >/iwtDesktop/htmldirectory
[tag:openClientsPage] This tag displays the page to configure the mobile clients from the
user’s desktop. This uses the content in the openClientsPage.jsfile in the
/etc/opt/SUNWips/desktop/< locale >/iwtDesktop/htmldirectory
[tag:openOptionsPage] This tag displays the page to configure the character sets for the
user’s mobile device. This uses the content in the
openOptionsPage.js file in the
/etc/opt/SUNWips/desktop/< locale >/iwtDesktop/htmldirectory
Table 7-1 iwtDesktop Tags
Tag Description
The Desktop Tags
Chapter 7 Tag Swapper Tags 173
[tag:provider] This is substituted with the channel name. It is used in INPUT,
CARD and OPTION tags when the name has to be used for the
value or the name of the tag
[tag:providerCount] This tag keeps a count of the number of channels selected for
display by the user. This is used in the SELECT tag for organizing
the providerList. This is used in the Layout page to set the table
height
[tag:providerName] This tag is substituted with the name of the channel and is used in
the OPTION tag
[tag:providerSize] This contains the number of providers and is used in a SELECT tag
for providerList to size the selection box
[tag:providerOptions] This tag gets its value from the providerOption.template file.
This contains the list of OPTION tags for providers used in SELECT
tag for providerList
[tag:client] It is substituted with the clientType (in WML). It is used in INPUT
and OPTION tags for the options, content, and layout providers
[tag:clientName] This tag is substituted with the given name of the selected
clientType (such as Nokia)
[tag:clientType] This tag is substituted with the type of client (html, chtml, or wml).
It is used in INPUT and OPTION tags
[tag:clientSize] This sets the size of a SELECT tag (selection box) based on the
number of clients
[tag:clientOptions] This tag gets its value from clientOption.template file. It
contains the list of OPTION tags for clients used in a SELECT tag
[tag:availableClients] This tag is substituted with the list of available clients
[tag:selectClients] This tag is substituted with the list of clients selected by the user
[tag:checked] This tag is substituted with the value in the checked.templatefile
[tag:selected] This tag gets its value from the selected.template file and
indicates whether or not a selection has been made
[tag:accesskey-no] This contains the numeric entity for the numeric emoji characters
used in cHTML. It gets its value from the accesskey.templatefile
[tag:front_help] This tag is substituted with the path to the help file for the home
page
Table 7-1 iwtDesktop Tags
Tag Description
The Calendar Provider Tags
174 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The Calendar Provider TagsThe following tags are used in the iwtCalendarProvider template files (see “The
Calendar Provider Template Files,” on page 42 for more information).
[tag:prov_help] This tag is substituted with the provider specific help file. It gets its
value from the provHelpLink.template file
[tag:help_link] This is substituted with the path to the client specific help file
[tag:changePageURL] This is substituted with the path to the file to go or change to
[tag:textMsg] This is substituted with the text message
[tag:accesskey-no] This is substituted with the numeric entity for the numeric emoji
characters used for cHTML clients
Table 7-2 iwtCalendarProvider Tags
Tag Description
[tag:calendar-display-client-uri]
This tag is substituted with the Single Sign On URL to the user’s
calendar client
[tag:calendar-display-client-sessionid]
This tag is substituted with the user’s session id
[tag:dayView] This tag is substituted with the checkbox for choosing day view in
the edit calendar page
[tag:calendar-display-dayView-event-startHourOfDay0]
This tag is used for displaying calendar events or appointment data
[tag:calendar-display-dayView-event-startHourOfDay1]
This tag is used for displaying calendar events or appointment data
[tag:calendar-display-dayView-event-startHour0]
This tag is used for displaying calendar events or appointment data
[tag:calendar-display-dayView-event-endHourOfDay0]
This tag is used for displaying calendar events or appointment data
[tag:calendar-display-dayView-event-endHourOfDay1]
This tag is used for displaying calendar events or appointment data
[tag:calendar-display-dayView-event-endHour0]
This tag is used for displaying calendar events or appointment data
Table 7-1 iwtDesktop Tags
Tag Description
The Calendar Provider Tags
Chapter 7 Tag Swapper Tags 175
[tag:calendar-display-dayView-event-startHour1]
This tag is substituted with the event start hour
[tag:calendar-display-dayView-event-startMinute]
This tag is substituted with the event start minute
[tag:calendar-display-dayView-event-startAmPm]
This tag is substituted with the event start time as ‘am’ or ‘pm’
[tag:calendar-display-dayView-event-endHour1]
This tag is substituted with the event end hour
[tag:calendar-display-dayView-event-endMinute]
This tag is substituted with the event end minute
[tag:calendar-display-dayView-event-endAmPm]
This tag is substituted with the event end time as ‘am’ or ‘pm’
[tag:calendar-display-dayView-event-location]
This tag is substituted with the location of the event
[tag:calendar-display-dayView-event-summary]
This tag is substituted with the summary text of the event
[tag:calendar-display-dayView-event-description]
This tag is substituted with the description text of the event
[tag:calendar-display-dayView-event-allDay]
This tag is substituted with the event marked as an all day event
[tag:calendar-display-dayView-dayOfWeek]
This tag is substituted with the day of the week
[tag:calendar-display-dayView-month]
This tag is substituted with the month
[tag:calendar-display-dayView-day]
This tag is substituted with the day
[tag:calendar-display-dayView-year]
This tag is substituted with the year
[tag:calendar-display-dayView-eventList]
This tag is substituted with the events with all of their information
retrieved from display-dayView-event.template file
[tag:calendar-display-error]
This tag is substituted with the error message
[tag:calendar-display-summary-events]
This tag is substituted with the summary of the events
Table 7-2 iwtCalendarProvider Tags
Tag Description
The Calendar Provider Tags
176 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
[tag:weekView] This tag is substituted with the checkbox for choosing week view in
the edit calendar page
[tag:calendar-display-weekView-event-allDay]
This tag is substituted with the event marked as an all day event
[tag:calendar-display-weekView-event-startHourOfDay0]
This tag is substituted with the 0 based 24-hour clock
[tag:calendar-display-weekView-event-startHourOfDay1]
This tag is substituted with the 1 based 24-hour clock
[tag:calendar-display-weekView-event-startHour0]
This tag is substituted with the 0 based 12-hour clock
[tag:calendar-display-weekView-event-endHourOfDay0]
This tag is substituted with the 0 based 24-hour clock
[tag:calendar-display-weekView-event-endHourOfDay1]
This tag is substituted with the 1 based 24-hour clock
[tag:calendar-display-weekView-event-endHour0]
This tag is substituted with the 0 based 12-hour clock
[tag:calendar-display-weekView-event-startHour1]
This tag is substituted with the event start hour
[tag:calendar-display-weekView-event-startMinute]
This tag is substituted with the event’s start minute
[tag:calendar-display-weekView-event-endHour1]
This tag is substituted with the event’s end hour
[tag:calendar-display-weekView-event-endMinute]
This tag is substituted with the event’s end minute
[tag:calendar-display-weekView-event-startAmPm]
This tag is substituted with the event’s start time as am or pm
[tag:calendar-display-weekView-event-endAmPm]
This tag is substituted with the event’s end time as am or pm
[tag:calendar-display-weekView-event-summary]
This tag is substituted with the summary text of the event
[tag:calendar-display-weekView-dayOfWeek0] -[tag:calendar-display-weekView-dayOfWeek6]
This tag is substituted with the day of the week where 0 refers to
Monday and so forth
Table 7-2 iwtCalendarProvider Tags
Tag Description
The Mail Provider Tags
Chapter 7 Tag Swapper Tags 177
The Mail Provider TagsThe tags discussed in Table 7-3 are used in the iwtMailProvider template files
(see “The Mail Provider Template Files,” on page 46 for more information).
[tag:calendar-display-weekView-day0] -[tag:calendar-display-weekView-day6]
This tag is substituted with the date in the week where day0 refers
to 1 and so forth
[tag:calendar-display-weekView-eventList0] -[tag:calendar-display-weekView-eventList5]
This tag is substituted with the events scheduled for the
corresponding date (see
[tag:calendar-display-weekView-dayOfWeek0] -[tag:calendar-display-weekView-dayOfWeek6] . It gets its
value from display-weekView-event.template file
[tag:calendar-display-summary]
This tag is a wrapper for summary view
[tag:calendar-display-dayView]
This tag is a wrapper for day view
[tag:calendar-display-weekView]
This tag is a wrapper for week view
[tag:calendar-display-clientURL]
This tag is substituted with the actual calendar client url
[tag:calendarServerName] This tag is substituted with the input box to enter port number for
calendar server in the edit calendar page (see on page 45)
[tag:calendarServerPort] This tag is substituted with the input box to enter port number for
calendar server in the edit calendar page (see on page 45)
[tag:calendarUserName] This tag is substituted with the input box in the edit calendar page
to enter user name required for calendar server (see on page 45)
[tag:calendarUserPassword] This tag is substituted with the input box in the edit calendar page
to enter user password required for calendar server (see on page 45)
Table 7-3 iwtMailProvider Tags
Tag Description
[tag:clientURL] This tag is substituted with the URL of the mail client
[tag:clientPort] This tag is substituted with the mail client port number
Table 7-2 iwtCalendarProvider Tags
Tag Description
The Mail Provider Tags
178 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
[tag:mail-display-clientURL-uri]
This tag is substituted with the Single Sign On URL to the mail client
[tag:mail-display-clientURL]
This tag is substituted with the content from the
display-clientURL.template file
[tag:mail-display-error] This tag is substituted with the error message specific to the
exception received
[tag:mail-display-headers-message-clientURL]
This tag is substituted with the Single Sign on url to the mail client
[tag:mail-display-headers-message-subject]
This tag is substituted with the subject of the message header
[tag:mail-display-headers-message-mailto]
This tag is substituted with the email address of the message sender
[tag:mail-display-headers-message-name]
This tag is substituted with the name of the mail sender
[tag:mail-display-headers-message-cbgc]
This tag is substituted with the background color
[tag:mail-display-headers-message-date]
This tag is substituted with the date the message was sent
[tag:mail-display-headers-message-status]
This tag is substituted with the status of the message as read or
unread
[tag:mail-display-headers-subject]
This tag is substituted with the localized string for the heading
(subject)
[tag:mail-display-headers-from]
This tag is substituted with the localized string for the heading
(from)
[tag:mail-display-headers-date]
This tag is substituted with the localized string for the heading
(date)
[tag:mail-display-headers-status]
This tag is substituted with the localized string for the heading
(status)
[tag:mail-display-headers-messageList]
This tag is substituted with the content from the
display-headers-message.template file
[tag:mail-display-summary-unread]
This tag is substituted with the number of unread messages
[tag:mail-display-summary-total]
This tag is substituted with the total number of messages
Table 7-3 iwtMailProvider Tags
Tag Description
The Address Book Provider Tags
Chapter 7 Tag Swapper Tags 179
The Address Book Provider TagsThe tags discussed in Table 7-4 are used in the iwtAddressBookProvider template
files (see “The Address Book Provider Template Files,” on page 49 for more
information).
[tag:mail-display-summary] This tag is substituted with the content from the
display-summary.template file
[tag:mail-display-headers] This tag is substituted with the content from the
display-headers.template file
[tag:displayHeadersChecked] This tag indicates whether displayHeaders checkbox is checked (see
on page 48)
[tag:numberHeaders] This tag is substituted with the number of message headers to be
displayed on the user’s desktop (see on page 48)
[tag:topSelected] This tag is substituted with the user’s message sort order preference
if most recent is to be at the top of the inbox (see on page 48)
[tag:topString] This tag is substituted with the localized string for “most recent at
top”(see on page 48)
[tag:bottomSelected] This tag is substituted with the user’s message sort order preference
if most recent is to be at the bottom of the inbox (see on page 48)
[tag:bottomString] This tag is substituted with the localized string for “most recent at
bottom” (see on page 48)
[tag:IMAPServerName] This tag is substituted with the IMAP server name (see on page 48)
[tag:IMAPUserId] This tag is substituted with the user’s user id (see on page 48)
[tag:IMAPPassword] This tag is substituted with the user’s password see on page 48)
[tag:changeUserInfoChecked] This tag indicates whether or not to update the user’s mail server
information in the user’s info channel settings
[tag:msgCopyInSentChecked] This tag indicates whether or not to place a copy of the message in
sent mail (see on page 49)
[tag:signature] This tag is substituted with the user’s signature file (see on page 49)
[tag:preset1] to[tag:preset9]
These tags are substituted with the appropriate predefined
messages (see on page 49)
Table 7-3 iwtMailProvider Tags
Tag Description
The Address Book Provider Tags
180 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Table 7-4 iwtAddressBookProvider Tags
Tag Description
[tag:ab-display-clientURL-appURL]
This tag is substitued with the actual URL to the address book client
[tag:ab-display-entry-list] This tag gets all the address book entries for the user in the format
specified in display-entry.template file
[tag:ab-display-entry-cbgc] This tag contains the background color of the channel
[tag:ab-display-entry-firstname]
This tag is substitued with the first name of the user
[tag:ab-display-entry-lastname]
This tag is substitued with the last name of the user
[tag:ab-display-entry-email]
This tag is substitued with the email address of the user
[tag:ab-display-entry-email-link]
This tag is substitued with the email address of the user as a link. If
an email address is not specified, then the message ’Email not
specified’ is displayed
[tag:ab-display-error] This tag is substitued with the error message
[tag:ab-display-summary-entries]
This tag is substitued with the number of address book entries for
the user
[tag:ab-display-summary] This tag is substitued with the address book summary for the user.
The content for this is retrieved from
display-summary.template file (see page 50).
[tag:ab-display-entries] This tag is substitued with the address book entries for the user. The
content for this is retrieved from display-entries.templatefile (see page 51)
[tag:ab-display-clientURL] This tag is substitued with the URL to the address book application
on the mobile device. The contents for this come from
display-clientURL.template file (see page 50)
[tag:iwtAddressBookProvider-displayEntries]
This tag indicates whether to display address book entries in the
address book channel, or to just display the summary. Its value is
retrieved from the ’Display entries’ checkbox in the edit address
book page (see on page 52)
[tag:iwtAddressBookProvider-numEntries]
This tag indicates the number of address book entries the user has
selected to be displayed on the address book channel. Its value
comes from the ’Number of entries’ input box in the edit address
book page (see on page 52)
The Wireless Personal Note Provider Tags
Chapter 7 Tag Swapper Tags 181
The Wireless Personal Note Provider TagsThe tags discussed in Table 7-5 are used only in the iwtPersonalNoteProvider
template files (see “The Wireless Personal Notes Provider Template Files,” on
page 52 for more information).
[tag:iwtAddressBookProvider-isLnSelected]
This tag indicates whether sorting is to be done on the last name for
the address book entries to be displayed. Its value comes from the
’Sort By’ list in the edit address book page (see on page 52)
[tag:iwtAddressBookProvider-isFnSelected]
This tag indicates whether sorting is to be done on the first name for
the address book entries to be displayed. Its value comes from the
’Sort By’ list in the edit address book page (see on page 52)
[tag:iwtAddressBookProvider-isNoSorting]
This tag indicates that no specific choice is made for sorting the
address book entries by
[tag:iwtAddressBookProvider-isUpSelected]
This tag indicates whether ascending sorting order has been
selected for the display of address book entries. Its value comes
from the ’Sort Order’ list in the edit address book page (see on
page 52)
[tag:iwtAddressBookProvider-isDownSelected]
This tag indicates whether the decending sorting order has been
selected for the display of address book entries. Its value comes
from the ’Sort Order’ list in the edit address book page (see on
page 52)
[tag:iwtAddressBookProvider-IMAPUserId]
This tag is substituted with the user id of the user whose address
book is to be retrieved. This is used to authenticate the user against
the IMAP server before the address book for the user can be
retrieved
[tag:iwtAddressBookProvider-IMAPPassword]
This tag is substituted with the password corresponding to the
IMAP user id. It is used to authenticate the user against the IMAP
server before the address book for the user can be retrieved
Table 7-5 iwtPersonalNoteProvider Tags
Tag Description
[tag:noteCount] This tag contains an attribute that tracks the number of personal
notes that are editable. This value is used by the
WirelessPersonalNoteProvider.processEdit() method.
[tag:noteList] This tag is substituted with the editable personal note textboxes.
Table 7-4 iwtAddressBookProvider Tags
Tag Description
The PostIt Note Provider Tags
182 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The PostIt Note Provider TagsThe tags discussed in Table 7-6 are used in the iwtPostItProvider template files
(see “The PostIt Provider Template Files,” on page 54 for more information).
The Wireless URLScraper Provider TagsThe tags discussed in Table 7-7 are used in the iwtwirelssURLScraperProvider
template files for WML clients (see “The Wireless URL Scraper Provider Template
Files,” on page 54 for more information).
[tag:nameId] This tag tracks which personal note to edit.
[tag:removeId] This tag tracks which personal note to remove.
[tag:tableData] This tag is substituted with all the evaluated content from the table
data wrapper logic (see page 54). This includes the personal note
content which typically contains rows of data.
[tag:pnote] This tag is substituted with the personal note content.
[tag:bgColor] This tag is substituted with the background color. This value is
retrieved from both the darkColor.template and
lightColor.template files and this value alternates between the
darkColor and the lightColor beginning with the lightColor.
[tag:textColor] This tag is substituted with the text color retrieved from the
textColor.template file.
Table 7-6 PostIt Note Provider Tags
Tag Description
[tag:note] This tag is substituted with the provider or channel content.
Table 7-7 iwtWirelessURL Scraper Tags
Tag Description
[tag:wirelessurlscraper-linkurl]
This tag is substituted with the link to the URL.
Table 7-5 iwtPersonalNoteProvider Tags
Tag Description
The User Information Provider Tags
Chapter 7 Tag Swapper Tags 183
The User Information Provider TagsThe tags discussed in Table 3-8 are used only in the iwtUserInfoProvider
template files (see “The UserInfo Provider Template Files,” on page 55 for more
information).
The Bookmark Provider TagsThe tag swapper tags discussed in Table 7-9 are used in the iwtBookmarkProvider
template files (see “The Wireless Bookmarks Provider Template Files,” on page 56
for more information).
Table 7-8 iwtUserInfoProvider Tags
Tag Description
[tag:iwtUserInfoProvider-firstName]
This tag is substituted with the first name of the user for the user
information channel.
[tag:iwtUserInfoProvider-lastName]
This tag is substituted with the last name of the user for the user
information channel.
[tag:iwtUserInfoProvider-greeting]
This tag is substituted with the greeting for the user.
[tag:timezoneList] This tag is substituted with the user’s timezone.
[tag:currentDate] This tag is substituted with the current date.
[tag:timeLeft] This tag is substituted with the amount of time left in the user’s
session before the session expires.
[tag:maxIdle] This tag is substituted with the configured maximum amount of
time that the user’s session is allowed to be idle before the session
expires.
[tag:iwtUser-IMAPServerName] This tag is substituted with the IMAP server name of the user.
[tag:iwtUser-SMTPServerName] This tag is substituted with the SMTP server name of the user.
[tag:iwtUser-IMAPUserId] This tag is substituted with the IMAP server user id of the user.
[tag:iwtUser-IMAPPassword] This tag is substituted with the IMAP server password of the user.
[tag:localeList] This tag is substituted with the list of available locales for the user.
[tag:passwordHandler] This tag encrypts the user’s password.
The Bookmark Provider Tags
184 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Table 7-9 iwtBookmarkProvider tags
Tag Description
[tag:bookmarks] This tag is substituted with the bookmark provider content which
typically includes bookmarks to URL’s.
[tag:resourceCount] This attribute tracks the number of resources or bookmarks that are
editable. This value is used by the
BookMarkProvider.processEdit() method.
[tag:resourceList] This tag is substituted with the editable resources or bookmarks textboxes.
One textbox is populated with the resource name and the other textbox is
populated with the resource location.
[tag:link] This tag is substituted with the URL location.
[tag:name] This tag is substituted with the name of the resource or the value of the
html <title> tag.
185
Chapter 8
Attributes and Schemas
This chapter discusses the attributes used by the Mobile Access Pack:
• Content providers
• Authentication, Desktop, and Client Detection modules
These attributes are stored in the iPlanet Portal Server profile service. The
attributes discussed in this chapter can be modified from the command line and
also from the administration console graphical user interface. Please see
Appendix B, “Sample Tasks” for more information on modifying these attributes.
Attributes for HTML ClientsThe following HTML channel attributes are used by the server components to
configure a channel for HTML clients only.
Table 8-1 Provider Attributes
Attribute Type Description AcceptableValue
<channelName>-description
string This attribute stores the user-visible
description of the channel. This
description is displayed in the Content
page of the desktop.
string
<channelName>-backgroundColor
string This attribute stores a valid HTML
background color value for the channel
string
<channelName>-helpLink string This attribute stores the path to the
channel help page for an HTML client. The
path must be relative to the web server’s
docroot.
Relative path
to the help file
Attributes for HTML Clients
186 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<channelName>-hasHelp boolean This attribute specifies whether or not the
channel has help
true or false
<channelName>-column string This attribute specifies the column where
the channel is displayed
1-3
<channelName>-row string This attribute specifies the vertical
ordering of the channel in a column
1-n
<channelName>-width singlechoi
ce
This attribute specifies the width of the
channel on the user’s desktop
thin, thick,
full_top, or
full_bottom
<channelName>-editType singlechoi
ce
This attribute specifies the type of edit
page that will be returned from the
channel
edit_subset or
edit_complete
<channelName>-isEditable
boolean This attribute specifies whether or not the
channel can be edited/configured from
the user’s desktop
true or false
<channelName>-hasFrame boolean This attribute specifies whether or not the
channel contains a frame
true or false
<channelName>-isMovable
boolean This attribute specifies whether or not the
channel can be moved
true or false
<channelName>-isMinimizable
boolean This attribute specifies whether or not the
channel can be minimized
true or false
<channelName>-isMinimized
boolean This attribute specifies whether or not the
channel will be displayed as just a title bar
on the desktop
true or false
<channelName>-isRemovable
boolean This attribute specifies whether or not the
channel can be removed
true or false
<channelName>-isDetachable
boolean This attribute specifies whether or not the
channel can be detached
true or false
<channelName>-isDetached
boolean This specifies whether or not the channel
will be displayed detached from the
desktop in a pop-up window
true or false
<channelName>-hasBorder
boolean This attribute specifies whether or not the
channel contains a border
true or false
Table 8-1 Provider Attributes
Attribute Type Description AcceptableValue
Attributes for HTML Clients
Chapter 8 Attributes and Schemas 187
<channelName>-descriptionThe following is an example of the <channelName >-description attribute. This
attribute stores the user-visible description of the channel. This description is
displayed in the Content page.
<iwt:Att name="< channelName >-description"
type="string"
idx="a150"
userConfigurable="false">
<Val>Component description</Val>
<Rperm>ADMIN</Rperm>
<Rperm>OWNER</Rperm>
</iwt:Att>
<channelName>-backgroundColorThe following is an example of <channelName >-backgroundColor attribute. This
attribute stores a valid HTML background color value for the channel window.
HTML color values can be specified as a literal string which is the color’s actual
name (for example, aquamarine) or as a hexadecimal triplet (for example,
#7FFFD4).
<iwt:Att name="< channelName >-backgroundColor"
type="string"
desc="Background Color"
idx="a106"
userConfigurable="true">
<Val>#DDDDDD</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Attributes for HTML Clients
188 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<channelName>-hasHelpThe following is an example of <channelName >-hasHelp attribute. This attribute
specifies whether or not the channel has end-user help available. A value of true
indicates that the channel has help content and a value of false indicates that the
channel does not include help. This is used to determine whether or not to display
the help icon (?) on the channel.
<iwt:Priv name="< channelName >-hasHelp"
type="boolean"
desc="Help?"
idx="X-x106"
val="false">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
<Rperm>OWNER</Rperm>
</iwt:Priv>
<channelName>-helpLinkThe following is an example of the <channelName >-helpLink attribute. This
attribute stores the path to the component’s help page for a html client. The path
must be relative to <servername >:< portnumber >/help/< locale >.
<iwt:Att name="< channelName >-helpLink"
type="string"
desc="Help Page"
idx="X-x104"
userConfigurable="true">
<Val>http://< servername >:< port >/help/< locale >/ComponentTOC.html</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
<Rperm>OWNER</Rperm>
</iwt:Att>
Attributes for HTML Clients
Chapter 8 Attributes and Schemas 189
<channelName>-columnThe following is an example of the <channelName >-column attribute. This attribute
specifies the column in the desktop page where the channel will be displayed.
Typically, the column width can be thin-thick (value not required), thick-thin
(value not required), thin-thick-thin (value of 1 indicates leftmost column and
value of 2 indicates rightmost column, and the thick width does not require a
value), thin-thin-thin (value of 1 indicates leftmost column, value of 2 indicates the
rightmost column, and value of 3 indicates the center column).
<iwt:Att name="< channelName >-column"
desc="Column"
type="string"
idx="X-x109"
userConfigurable="TRUE">
<Val>1</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
<Wperm>ADMIN</Wperm><Wperm>OWNER</Wperm>
</iwt:Att>
<channelName>-rowThe following is an example of the <channelName >-row attribute. This attribute
specifies the the vertical ordering or positioning of the channel in a column. If
conflict arises (as a result of more than two channels requiring the same position),
the order in the channel list is used.
<iwt:Att name="< channelName >-row"
type="string"
desc="Row"
idx="X-x110"
userConfigurable="true">
<Val>1</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Attributes for HTML Clients
190 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<channelName>-widthThe following is an example of the <channelName >-width attribute. This attribute
specifies the width of the channel. A channel can be thin, thick, occupy the width of
the desktop at the top (full_top) or botton (full_bottom).
<iwt:Att name="< channelName >-width"
type="singlechoice"
desc="Width"
idx="X-x100"
userConfigurable="true">
<Val>thick</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
<CVal>thin</CVal>
<CVal>thick</CVal>
<CVal>full_top</CVal>
<CVal>full_bottom</CVal>
</iwt:Att>
<channelName>-editTypeThe following is an example of the <channelName >-editType attribute. This
attribute specifies the type of edit page that will be returned for the channel. The
acceptable values are:
• edit_complete - Indicates that it will return a complete HTML page.
• edit_subset - Indicates that it will return a subset of an HTML page that will be
further wrapped by a template to add things like bordering, sumbit buttons,
etc.
<iwt:Att name="< channelName >-editType"
type="singlechoice"
desc="Edit Form Type"
idx=""
userConfigurable="true">
<Val>edit_subset</Val>
Attributes for HTML Clients
Chapter 8 Attributes and Schemas 191
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
<CVal>edit_subset</CVal>
<CVal>edit_complete</CVal>
</iwt:Att>
<channelName>-isEditableThe following is an example of the <channelName >-isEditable attribute. This
attribute specifies whether or not the channel is editable from the user’s desktop.
This is used to determine whether or not to display the edit icon on the channel.
This is also used to control access to configuring the channel; that is, a value of false
will not permit the user to configure or edit the channel setup from the user’s
desktop.
<iwt:Priv name="< channelName >-isEditable"
type="boolean"
desc="Editable?"
idx="X-x107"
val="false">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Priv>
<channelName>-hasFrameThe following is an example of the <channelName >-hasFrame attribute. This
attribute specifies whether or not the channel contains a frame (see iPlanet Portal
Server 3.0 Service Pack 3a Release Notes for more information on setting up framed
and frameless channels).
<iwt:Att name="< channelName >-hasFrame"
type="boolean"
desc="Framed?"
idx="X-x108"
userConfigurable="true">
<Val>true</Val>
Attributes for HTML Clients
192 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
<channelName>-isMovableThe following is an example of the <channelName >-isMovable attribute. This
attribute specifies whether or not the channel can be moved in the desktop (see
iPlanet Portal Server 3.0 Service Pack 3a Release Notes for more information on
locking a channel’s position on the desktop).
<iwt:Priv name="< channelName >-isMovable"
type="boolean"
desc="Movable?"
idx="a107"
val="true">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Priv>
<channelName>-isMinimizableThe following is an example of the <channelName >-isMinimizable attribute. This
attributes specifies whether or not a channel can be minimized in the user’s
desktop. This is used to determine whether or not to display the Minimize icon on
the channel.
<iwt:Priv name="< channelName >-isMinimizable"
type="boolean"
desc="Minimizable?"
idx="a102"
val="true">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Priv>
Attributes for HTML Clients
Chapter 8 Attributes and Schemas 193
<channelName>-isMinimizedThe following is an example of the <channelName >-isMinimized attribute. This
attribute specifies whether or not the channel will be displayed as just a title bar on
the desktop that the user can maximize.
<iwt:Att name="< channelName >-isMinimized"
desc="Minimized?"
type="boolean"
idx="X-x102"
userConfigurable="TRUE">
<Val>false</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
<Wperm>ADMIN</Wperm><Wperm>OWNER</Wperm>
</iwt:Att>
<channelName>-isRemovableThe following is an example of the <channelName >-isRemovable attribute. This
attribute specifies whether or not the channel can be removed from the desktop.
This is used to determine whether or not to display the Remove icon on the
channel.
<iwt:Priv name="< channelName >-isRemovable"
type="boolean"
desc="Removable?"
idx="a105"
val="true">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Priv>
<channelName>-isDetachableThe following is an example of the <channelName >-isDetachable attribute. This
attribute specifies whether or not the channel can be detached from the desktop
into a smaller pop-up window. A value of true indicates that the channel is
detachable and false indicates that the channel is non-detachable.
Attributes for HTML Clients
194 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<iwt:Priv name="< channelName >-isDetachable"
type="boolean"
desc="Detachable?"
idx="a103"
val="true">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Priv>
<channelName>-isDetachedThe following is an example of the <channelName >-isDetached attribute. This
attribute specifies whether the channel will be displayed detached from the
desktop as a pop-up window.
<iwt:Att name="< channelName >-isDetached"
type="boolean"
desc="Detached?"
idx="X-x101"
userConfigurable="true">
<Val>false</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
<channelName>-hasBorderThe following is an example of the <channelName >-hasBorder attribute. This
attribute specifies whether or not the channel has a border. A true value indicates
that the channel has a border and false value indicates that the channel has no
border.
<iwt:Priv name="< channelName >-hasBorder"
type="boolean"
desc="Border?"
idx="a104"
val="true">
Common Attributes
Chapter 8 Attributes and Schemas 195
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Priv>
Common AttributesThe following channel attributes are used by the Mobile Access Pack components
to configure a channel.
<channelName>-titleThe following is an example of the <channelName >-title attribute. This attribute
stores the name or title of the channel. This is the user visible channel title. This title
is displayed on the channel and in the Content page.
<iwt:Att name="< channelName >-title"
desc="Title"
type="string"
idx="a101"
userConfigurable="TRUE">
<Val>Channel Name</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
<Wperm>ADMIN</Wperm>
</iwt:Att>
Table 8-2 Provider Attributes
Attribute Type Description AcceptableValue
<channelName>-title string This attribute stores theuser-visible
channel title.
string
<channelName>-clientHelpLinks
string This attribute stores the path to the client
specific help files for the channel
clientType|pat
h to help file
<channelName>-refreshTime
boolean This attribute specifies the time interval
between refreshing channel content
0 - n
Common Attributes
196 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<channelName>-clientHelpLinksThe following is an example of the <channelName >-clientHelpLinks attribute.
This attribute stores the path to the client specific help for the component or
channel.
<iwt:Att name="< channelName >-clientHelpLinks"
desc ="Component Help Links"
type="stringlist"
idx="a201"
userConfigurable="TRUE">
<Val>clientType|Path_to_help_file</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
<Wperm>ADMIN</Wperm><Wperm>OWNER</Wperm>
</iwt:Att>
Each clientType listed here must exactly and accurately match the clientType that
is found in the Client Data. Specify only one file (such as ComponentTOC.html or a
higher level table of contents with links to more files if needed) per component in
this attribute. The path to the help file must be relative to
<iPS_install_base >/SUNWips/public_html/docs/< locale >/online_help .
<channelName>-refreshTimeThe following is an example of the <channelName >-refreshTime attribute. This
attribute specifies the amount of time, in seconds, until the channel content, cached
by the desktop, expires. When the user refreshes the desktop page, the Desktop
checks each channel to see if the refresh time (specified in this attribute by each
channel) has elapsed since the channel’s content was cached. If the time had not
elapsed, then the Desktop builds its page using a cached copy of the channel’s
content. If the cache expires, then the Desktop fetches fresh content from the
channel.
<iwt:Att name="< channelName >-refreshTime"
desc="Refresh Time"
type="string"
idx="X-x105"
userConfigurable="TRUE">
<Val>0</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
Calendar Provider Attributes
Chapter 8 Attributes and Schemas 197
<Wperm>ADMIN</Wperm>
</iwt:Att>
Calendar Provider AttributesThe following attributes reside in the profile component iwtCalendarProvider .
Table 8-3 iwtCalendarProvider Attributes
Attribute Type Description AcceptableValue
iwtCalendarProvider-calendarUserName
string This attribute stores the calendar user’s
name.
User name
iwtCalendarProvider-calendarUserPassword
string This attribute stores the calendar user’s
password.
User Password
iwtCalendarProvider-calendarServerName
string This attribute stores the user’s calendar
server name.
Calendar
server name
iwtCalendarProvider-calendarServerPort
string This attribute stores the user’s calendar
server port number.
Calendar
server port
iwtCalendarProvider-weekView
boolean This attribute specifies whether or not the
user’s calendar view preference is set to
weekly view.
true or false
iwtCalendarProvider-dayView
boolean This attribute specifies whether or not the
user’s calendar view preference is set to
daily view.
true or false
iwtCalendarProvider-clientURL
stringlist This attribute stores the client type and the
client specific calendar server URL for that
client type.
clientType|CA
LENDAR
CLIENT URL
iwtCalendarProvider-jspLocationLength
stringlist This attribute specifies the number of
characters about the location of the event
to display.
clientType|Nu
mber of
characters
iwtCalendarProvider-jspDescLength
stringlist This attribute specifies the number of
characters about the description of the
event to display.
clientType|Nu
mber of
characters
iwtCalendarProvider-jspSummaryLength
stringlist This attribute specifies the number of
characters about the summary of the event
to display.
clientType|Nu
mber of
characters
iwtCalendarProvider-jspEventNumLines
stringlist This attribute specifies the number of
events to display.
clientType|Nu
mber of events
Calendar Provider Attributes
198 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtCalendarProvider-calendarUserNameThe following is an example of the iwtCalendarProvider-calendarUserName
attribute. This attribute’s value can be specified from the edit Calendar page on the
user’s desktop. This attribute stores the user’s calendar server id and is used to
connect to the calendar server.
<iwt:Att name="iwtCalendarProvider-calendarUserName"
type="string"
desc="Calendar User Name"
idx="a202"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtCalendarProvider-calendarUserPasswordThe following is an example of the
iwtCalendarProvider-calendarUserPassword attribute. This attribute’s value
can be specified from the edit Calendar page on the user’s desktop. This attribute
stores the user’s calendar server password and is used to connect to the calendar
server.
<iwt:Att name="iwtCalendarProvider-calendarUserPassword"
type="string"
desc="Calendar User Password"
idx="a203"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Calendar Provider Attributes
Chapter 8 Attributes and Schemas 199
iwtCalendarProvider-calendarServerNameThe following is an example of the iwtCalendarProvider-calendarServerName
attribute. This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
calendar
• From the edit Calendar page on the user’s desktop
This attribute stores the user’s calendar server name and is used to connect to the
user’s calendar server.
<iwt:Att name="iwtCalendarProvider-calendarServerName"
type="string"
desc="Calendar Server Name"
idx="a200"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtCalendarProvider-calendarServerPortThe following is an example of the iwtCalendarProvider-calendarServerPort
attribute. This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
calendar client
• From the edit Calendar page on the user’s desktop
This attribute stores the user’s calendar server port number and is used to connect
to the user’s calendar server.
<iwt:Att name="iwtCalendarProvider-calendarServerPort"
type="string"
desc="Calendar Server Port"
idx="a201"
userConfigurable="true">
<Val></Val>
Calendar Provider Attributes
200 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
The calendar channel uses the servername, port number, username and password
set by the user in the edit page and stored in the
iwtCalendarProvider-calendarServerName ,iwtCalendarProvider-calendarServerPort,iwtCalendarProvider-calendarUserName , and
iwtCalendarProvider-calendarUserPassword attributes respectively to connect
to the calendar server and get the events.
iwtCalendarProvider-weekViewThe following is an example of the iwtCalendarProvider-weekView attribute.
This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
calendar
• From the edit Calendar page on the user’s desktop
If set to true, the calendar displays a weekly view of events. By default, this is set to
true.
<iwt:Att name="iwtCalendarProvider-weekView"
type="boolean"
desc="Week View"
idx="a205"
userConfigurable="true">
<Val>true</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtCalendarProvider-dayViewThe following is an example of the iwtCalendarProvider-dayView attribute. This
attribute gets its value:
• From the Administration Console at the time of configuring the channel for the
calendar client
Calendar Provider Attributes
Chapter 8 Attributes and Schemas 201
• From the edit Calendar page on the user’s desktop
If set to true, the calendar displays a daily view of events. By default, this is set to
true.
<iwt:Att name="iwtCalendarProvider-dayView"
type="boolean"
desc="Day View"
idx="a204"
userConfigurable="true">
<Val>true</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtCalendarProvider-clientURLThe following is an example of the iwtCalendarProvider-clientURL attribute.
This attribute’s value can be specified from the administration console at the time
of configuring the channel for the calendar client or by using the ipsadmin
command (see “Configuring the Attributes,” on page 257).
The server URL to build the Single Sign On link is configured in this profile
attribute. This attribute uses a stringlist to store the clientType and the client
specific server URL for that clientType. If the clientType is not found in the session,
then the calendar channel defaults it to genericHTML. The channel iterates through
the list of values from this attribute and gets the clientURL corresponding to the
clientType accessing the calendar server.
<iwt:Att name="iwtCalendarProvider-clientURL"
desc="Client URL"
type="stringlist"
idx="X-x200"
userConfigurable="TRUE">
<Val>genericHTML|INST_CALENDAR_CLIENT_URL</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
<Wperm>ADMIN</Wperm>
</iwt:Att>
Calendar Provider Attributes
202 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtCalendarProvider-jspLocationLengthThe following is an example of iwtCalendarProvider-jspLocationLength
attribute. This attribute specifies the number of characters to display about the
event location on the corresponding client. This is only applicable to clients that
utilize the calendar JSP template files (discussed in “iPlanet Calendar Server JSPs,”
on page 60).
<iwt:Att name="iwtCalendarProvider-jspLocationLength"
type="stringlist"
desc="Length of Event Location to Display Via JSP"
idx="X-x113"
userConfigurable="true">
<Val>genericHTML|40</Val>
<Val>cHTML|25</Val>
<Val>WML|25</Val>
<Val>nokia_7110|25</Val>
<Val>siemans_s35|25</Val>
<Val>pana_p503i|25</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtCalendarProvider-jspDescLengthThe following is an example of iwtCalendarProvider-jspDescLength attribute.
This attribute specifies the number of characters to display about the event
description on the corresponding client. This is only applicable to clients that
utilize the calendar JSP template files (discussed in “iPlanet Calendar Server JSPs,”
on page 60).
<iwt:Att name="iwtCalendarProvider-jspDescLength"
type="stringlist"
desc="Length of Event Description to Display Via JSP"
idx="X-x114"
userConfigurable="true">
<Val>genericHTML|1024</Val>
Calendar Provider Attributes
Chapter 8 Attributes and Schemas 203
<Val>cHTML|300</Val>
<Val>WML|300</Val>
<Val>nokia_7110|300</Val>
<Val>siemans_s35|300</Val>
<Val>pana_p503i|300</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtCalendarProvider-jspSummaryLengthThe following is an example of the iwtCalendarProvider-jspSummaryLength
attribute. This attribute specifies the number of characters to display about the
event summary on the corresponding client. This is only applicable to clients that
utilize the calendar JSP template files (discussed in “iPlanet Calendar Server JSPs,”
on page 60).
<iwt:Att name="iwtCalendarProvider-jspSummaryLength"
type="stringlist"
desc="Length of Event Summary to Display Via JSP"
idx="X-x112"
userConfigurable="true">
<Val>genericHTML|40</Val>
<Val>cHTML|25</Val>
<Val>WML|25</Val>
<Val>nokia_7110|25</Val>
<Val>siemans_s35|25</Val>
<Val>pana_p503i|25</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Mail Provider Attributes
204 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtCalendarProvider-jspEventNumLinesThe following is an example of the iwtCalendarProvider-jspEventNumLines
attribute. This attribute stores the number of calendar events to display on the
corresponding client. This is only applicable to clients that utilize the calendar JSP
template files (discussed in “iPlanet Calendar Server JSPs,” on page 60).
<iwt:Att name="iwtCalendarProvider-jspEventNumLines"
type="stringlist"
desc="Number of Events to Display Via JSP"
idx="X-x111"
userConfigurable="true">
<Val>genericHTML|10</Val>
<Val>cHTML|7</Val>
<Val>WML|7</Val>
<Val>nokia_7110|7</Val>
<Val>siemans_s35|7</Val>
<Val>pana_p503i|7</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Mail Provider AttributesThe attributes discussed in Table 8-4 reside in the profile component
iwtMailProvider .
Table 8-4 iwtMailProvider Attributes
Attribute Type Description AcceptableValue
iwtMailProvider-msgCopyInSent
boolean This attribute specifies whether or not the
user prefers to store a copy of the message
in the Sent folder
true or false
iwtMailProvider-clientURL
stringlist This attribute stores the URL to the mail
server for each supported client type
clientType|URL_to_Mail_Server
Mail Provider Attributes
Chapter 8 Attributes and Schemas 205
iwtMailProvider-clientPort
string This attribute stores the mail client port
number
clientPortNum
ber
iwtMailProvider-sortOrder
stringlist This attribute specifies the order to sort the
messages by
top or bottom
iwtMailProvider-displayHeaders
boolean This attribute specifies whether or not to
display the message headers on the user’s
mail channel
true or false
iwtMailProvider-numberHeaders
string This attribute specifies the number of
message headers to display on the user’s
mail channel
0 to n
iwtMailProvider-predefinedReplies
stringlist This attribute stores the user’s predefined
replies
Predefined
replies
iwtMailProvider-signature
string This attribute stores the user’s signature User’s
signature
iwtMailProvider-changeUserInfo
boolean This attribute specifies whether or not to
update the user profile
true or false
iwtMailProvider-IMAPServerName
string This attribute stores the user’s IMAP
server name
Server Name
iwtMailProvider-IMAPUserId
string This attribute stores the user’s IMAP user
id
User Id
iwtMailProvider-IMAPPassword
protected This attribute stores the user’s IMAP
password
User’s
Password
iwtMailProvider-jspInboxNumLines
stringlist This attribute specifies the number of lines
from the Inbox to display
clientType|nu
mber of lines
iwtMailProvider-jspFromLength
stringlist This attribute specifies the number of
characters from the From header to
display
clientType|nu
mber of
characters
iwtMailProvider-jspSubjectLength
stringlist This attribute specifies the number of
characters from the Subject header to
display
clientType|nu
mber of
characters
iwtMailProvider-jspMsgNumLines
stringlist This attribute specifies the number of lines
from the message to display
clientType|nu
mber of lines
Table 8-4 iwtMailProvider Attributes
Attribute Type Description AcceptableValue
Mail Provider Attributes
206 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtMailProvider-msgCopyInSentThe following is an example of the iwtMailProvider-msgCopyInSent attribute.
This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
mail client
• From the edit Mail page on the user’s desktop
This attribute indicates whether or not to save a copy of the message in the user’s
Sent folder. By default, this is set to true.
<iwt:Att name="iwtMailProvider-msgCopyInSent"
type="boolean"
desc="Place a copy of message in Sent"
idx="a206"
userConfigurable="true">
<Val>true</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-clientURLThe following is an example of the iwtMailProvider-clientURL attribute. This
attribute’s value can be specified from the administration console at the time of
configuring the channel for the mail client and/or from the Edit Mail channel page.
The server URL to build the Single Sign On link is configured in this profile
attribute. This attribute uses a stringlist to store the clientType and the client
specific server URL for that clientType. If the client type is not found in the session,
then the mail channel defaults it to generic HTML. The channel iterates through the
list of values from this attribute and gets the client URL corresponding to the
clientType accessing the mail server.
<iwt:Att name="iwtMailProvider-clientURL"
type="stringlist"
desc="Client URL"
idx="a203"
userConfigurable="true">
Mail Provider Attributes
Chapter 8 Attributes and Schemas 207
<Val>genericHTML|INST_MAIL_CLIENT_URL</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-clientPortThe following is an example of the iwtMailProvider-clientPort attribute. This
attribute stores the port number of the mail client.
<iwt:Att name="iwtMailProvider-clientPort"
type="string"
desc="Client Port"
idx="a207"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-sortOrderThe following is an example of the iwtMailProvider-sortOrder attribute. This
attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
mail client
• From the edit Mail page on the user’s desktop
This attribute indicates the order in which to sort the user’s messages in the inbox
for display. The user can either view the most recent at the top or at the bottom. By
default, the most recent message are displayed at the top of the inbox.
<iwt:Att name="iwtMailProvider-sortOrder"
type="string"
desc="Sort Order"
idx="a202"
userConfigurable="true">
Mail Provider Attributes
208 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<Val>top</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-displayHeadersThe following is an example of the iwtMailProvider-displayHeaders attribute.
This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
mail client
• From the edit Mail page on the user’s desktop
This attribute indicates whether or not to display the message headers in the user’s
mail channel. By default, this is set to true.
<iwt:Att name="iwtMailProvider-displayHeaders"
type="string"
desc="Display Headers"
idx="a200"
userConfigurable="true">
<Val>true</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-numberHeadersThe following is an example of the iwtMailProvider-numberHeaders attribute.
This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
mail client
• From the edit Mail page on the user’s desktop
This attribute indicates the number of message headers to display in the user’s mail
channel. By default, up to five message headers are displayed in the user’s mail
channel and the channel limits the maximum number of message headers to be
displayed to 30.
Mail Provider Attributes
Chapter 8 Attributes and Schemas 209
<iwt:Att name="iwtMailProvider-numberHeaders"
type="string"
desc="Number of Headers"
idx="a201"
userConfigurable="true">
<Val>5</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-predefinedRepliesThe following is an example of the iwtMailProvider-predefinedReplies
attribute. This attribute’s value can be specified from the edit Mail page on the
user’s desktop and/or from the Administration Console. This attribute allows the
user to create and store messages to send out later, typically, from the mobile
device. The predefined messages cannot exceed thirty characters. Although these
messages can be set up from the Administration Console as well, these messages
must be created by the user from their edit Mail page.
<iwt:Att name="iwtMailProvider-predefinedReplies"
type="stringlist"
desc="Predefined Replies"
idx="a205"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-signatureThe following is an example of the iwtMailProvider-signature attribute. This
attribute’s value can be specified from the edit Mail page on the user’s Desktop
and/or from the Administration Console. This attribute allows the user to create
and store a signature from the user’s Desktop. Although this can be set from the
administration console as well, this must be set by the user from the edit Mail page.
Mail Provider Attributes
210 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
<iwt:Att name="iwtMailProvider-signature"
type="string"
desc="Signature"
idx="a204"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-changeUserInfoThe following is an example of the iwtMailProvider-changeUserInfo attribute.
This attribute specifies whether or not to update the user’s IMAP server name, user
id, and password information in the user info channel. If this attribute is set to true,
the IMAP server name (see iwtMailProvider-IMAPServerName ), user id (see
iwtMailProvider-IMAPUserId ), and password (see
iwtMailProvider-IMAPPassword ) specified via this component will overwrite the
IMAP server name, user id, and password specified in the user info channel.
<iwt:Att name="iwtMailProvider-changeUserInfo"
type="boolean"
desc="Change Mail Server attributes on UserInfo"
idx="a211"
userConfigurable="true">
<Val>false</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-IMAPServerNameThe following is an example of the iwtMailProvider-IMAPServerName attribute.
This attribute stores the user’s IMAP server name.
<iwt:Att name="iwtMailProvider-IMAPServerName"
type="string"
Mail Provider Attributes
Chapter 8 Attributes and Schemas 211
desc="IMAP ServerName to authenticate against"
idx="a208"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-IMAPUserIdThe following is an example of the iwtMailProvider-IMAPUserId attribute. This
attribute stores the user’s IMAP server user id.
<iwt:Att name="iwtMailProvider-IMAPUserId"
type="string"
desc="Mail Server User Id"
idx="a209"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-IMAPPasswordThe following is an example of the iwtMailProvider-IMAPPassword attribute.
This attribute stores the user’s IMAP server password.
<iwt:Att name="iwtMailProvider-IMAPPassword"
type="protected"
desc="Mail Server User Password"
idx="a210"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
Mail Provider Attributes
212 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
</iwt:Att>
iwtMailProvider-jspInboxNumLinesThe following is an example of the iwtMailProvider-jspInboxNumLines
attribute. This attribute specifies the number of lines from the Inbox to display on
the corresponding client. This is only applicable to clients that utilize the mail JSP
templates.
<iwt:Att name="iwtMailProvider-jspInboxNumLines"
type="stringlist"
desc="Number of Inbox Lines to Display Via JSP"
idx="X-x111"
userConfigurable="true">
<Val>genericHTML|10</Val>
<Val>cHTML|11</Val>
<Val>WML|9</Val>
<Val>nokia_7110|9</Val>
<Val>siemans_s35|9</Val>
<Val>pana_p503i|10</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-jspFromLengthThe following is an example of the iwtMailProvider-jspFromLength attribute.
This attribute specifies the number of characters from the From header to display
on the corresponding client. This is only applicable to clients that utilize the mail
JSP templates.
<iwt:Att name="iwtMailProvider-jspFromLength"
type="stringlist"
desc="Length of From Header to Display Via JSP"
idx="X-x113"
userConfigurable="true">
<Val>genericHTML|40</Val>
Mail Provider Attributes
Chapter 8 Attributes and Schemas 213
<Val>cHTML|18</Val>
<Val>WML|23</Val>
<Val>nokia_7110|23</Val>
<Val>siemans_s35|23</Val>
<Val>pana_p503i|18</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtMailProvider-jspSubjectLengthThe following is an example of the iwtMailProvider-jspSubjectLength
attribute. This attribute specifies the number of characters from the Subject header
to display on the corresponding client. This is only applicable to clients that utilize
the mail JSP template files.
<iwt:Att name="iwtMailProvider-jspSubjectLength"
type="stringlist"
desc="Length of Subject Header to Display Via JSP"
idx="X-x114"
userConfigurable="true">
<Val>genericHTML|40</Val>
<Val>cHTML|18</Val>
<Val>WML|23</Val>
<Val>nokia_7110|23</Val>
<Val>siemans_s35|23</Val>
<Val>pana_p503i|18</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Address Book Provider Attributes
214 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtMailProvider-jspMsgNumLinesThe following is an example of the iwtMailProvider-jspMsgNumLines attribute.
This attribute specifies the number of lines from the message to display on the
corresponding client. This is only applicable to clients that utilize the mail JSP
template files.
<iwt:Att name="iwtMailProvider-jspMsgNumLines"
type="stringlist"
desc="Number of Message Lines to Display Via JSP"
idx="X-x112"
userConfigurable="true">
<Val>genericHTML|10</Val>
<Val>cHTML|11</Val>
<Val>WML|9</Val>
<Val>nokia_7110|9</Val>
<Val>siemans_s35|9</Val>
<Val>pana_p503i|11</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Address Book Provider AttributesThe attributes discussed in Table 8-5 reside in the profile component
iwtAddressBookProvider .
Table 8-5 iwtAddressBookProvider Attributes
Attribute Type Description AcceptableValue
iwtAddressBookProvider-clientURL
stringlist This attribute stores the URL to the iPlanet
Messaging Server hosting the address
book for each supported client type
clientType|UR
L_TO_AB_SER
VER
iwtAddressBookProvider-displayEntries
string This attribute indicates whether or not to
display the address book entries
true or false
Address Book Provider Attributes
Chapter 8 Attributes and Schemas 215
iwtAddressBookProvider-sortOrder
string This attribute specifies the sor order for
the address book entries
up or down
iwtAddressBookProvider-sortBy
string This attribute specifies the field to sort the
address book entries by
firstname or
lastname
iwtAddressBookProvider-numEntries
string This attribute specifies the number of
address book entries to display
0 - n
iwtAddressBookProvider-maxEntries
string This attribute specifies the maximum
number of address book entries to display
0 - n
iwtAddressBookProvider-LDAPServerName
string This attribute stores the address book
database server name
LDAP server
name
iwtAddressBookProvider-LDAPport
string This attribute stores the address book
database server port number
LDAP server
port
iwtAddressBookProvider-LDAPAdminId
string This attribute stores the distinguished
name of the address book database
administrator
LDAP admin
DN
iwtAddressBookProvider-LDAPAdminPassword
string This attribute stores the password of the
address book database administrator
LDAP admin
password
iwtAddressBookProvider-LDAPSearchBase
string This attribute stores the base distinguished
name in the LDAP database for address
book
LDAP search
base
iwtAddressBookProvider-IMAPServerName
string This attribute stores the user’s IMAP
server name
IMAP server
name
iwtAddressBookProvider-IMAPUserId
string This attribute stores the user’s IMAP user
id
IMAP user id
iwtAddressBookProvider-IMAPPassword
protected This attribute stores the user’s IMAP
password.
IMAP user
password
iwtAddressBookProvider-ldapConnPoolStart
stringlist This attribute specifies the number to
LDAP connection pools to start.
0 - n
iwtAddressBookProvider-ldapConnPoolMax
stringlist This attribute specifies the maximum
number to LDAP connection pools to
establish.
0 - n
iwtAddressBookProvider-ldapOpTimeout
stringlist This attribute specifies the time, in
milliseconds, after which the LDAP
operation will terminate.
time in
milliseconds
Table 8-5 iwtAddressBookProvider Attributes
Attribute Type Description AcceptableValue
Address Book Provider Attributes
216 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtAddressBookProvider-clientURLThe following is an example of the iwtAddressBookProvider-clientURL
attribute. This attribute’s value can be specified from the administration console at
the time of configuring the client channel.
The server URL used to build the Single Sign On link is configured in this profile
attribute. This attribute uses a stringlist to store the clientType and the client
specific server URL for that clientType. If the clientType is not found in the session,
then the address book channel defaults it to generic HTML. The channel iterates
through the list of values from this profile component attribute and gets the client
URL based on the clientType accessing the address book server.
The isPresentable() method tries to get the client specific template for the
channel content. If the template exists, then it returns true, else returns false.
<iwt:Att name="iwtAddressBookProvider-clientURL"
type="stringlist"
desc="Client URL"
idx="a203"
userConfigurable="true">
<Val>genericHTML|INST_AB_CLIENT_URL</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-displayEntriesThe following is an example of the iwtAddressBookProvider-displayEntries
attribute. This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
address book client
• From the edit Address Book page on the user’s desktop
iwtAddressBookProvider-jspAbNumLines
stringlist This attribute specifies the number of
address book entries to display
clientType|nu
mber of lines
Table 8-5 iwtAddressBookProvider Attributes
Attribute Type Description AcceptableValue
Address Book Provider Attributes
Chapter 8 Attributes and Schemas 217
This attribute indicates whether or not to display the user’s address book entries in
the address book channel. By default, it is set to true.
<iwt:Att name="iwtAddressBookProvider-displayEntries"
type="string"
desc="Display Entries"
idx="a300"
userConfigurable="true">
<Val>true</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-sortOrderThe following is an example of the iwtAddressBookProvider-sortOrder
attribute. This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
address book client
• From the edit Address Book page on the user’s desktop
This attribute indicates the order in which to sort the user’s address book entries
for display. The user can either select an ascending order or descending order of
display of entries. By default, the address book entries are sort in an ascending
order. The possible values are up and down.
<iwt:Att name="iwtAddressBookProvider-sortOrder"
type="string"
desc="Sort Order"
idx="a304"
userConfigurable="true">
<Val>up</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Address Book Provider Attributes
218 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtAddressBookProvider-sortByThe following is an example of the iwtAddressBookProvider-sortBy attribute.
This attribute gets its value:
• From the administration console at the time of configuring the channel for the
address book client
• From the edit Address Book page on the user’s desktop
This attribute indicates the field in which to sort the user’s address book entries for
display. The user can either select to display entries by first name or last name. By
default, the address book entries are sort by first name. The possible values are
firstname and lastname .
<iwt:Att name="iwtAddressBookProvider-sortBy"
type="string"
desc="Sort on given field"
idx="a303"
userConfigurable="true">
<Val>Lastname</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-numEntriesThe following is an example of the iwtAddressBookProvider-numEntries
attribute. This attribute’s value can be specified:
• From the Administration Console at the time of configuring the channel for the
address book client
• From the edit Address Book page on the user’s desktop
This attribute specifies the number of address book entries to display on the user’s
address book channel. By default, up to five entries will be displayed on the user’s
address book channel.
Note that the number of entries that can be displayed is limited by the maximum
number of entries allowed to be displayed on the channel (see
iwtAddressBookProvider-maxEntries for more information).
<iwt:Att name="iwtAddressBookProvider-numEntries"
Address Book Provider Attributes
Chapter 8 Attributes and Schemas 219
type="string"
desc="Number of Entries"
idx="a301"
userConfigurable="true">
<Val>5</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-maxEntriesThe following is an example of the iwtAddressBookProvider-maxEntries
attribute. This attribute’s value can be specified from the Administration Console
at the time of configuring the channel for the address book client. This attribute
indicates the maximum number of entries that can displayed on the address book
channel. By default, up to thirty entries can be displayed on the user’s address
book channel.
<iwt:Att name="iwtAddressBookProvider-maxEntries"
type="string"
desc="Maximum number of Entries"
idx="a302"
userConfigurable="true">
<Val>30</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-LDAPServerNameThe following is an example of the iwtAddressBookProvider-LDAPServerName
attribute. This attribute’s value can be specified from the Administration Console
at the time of configuring the channel for the address book client. This attribute
stores the address book database server name. This is used at the time of retrieving
entries for the user and for performing searches in the address book database.
<iwt:Att name="iwtAddressBookProvider-LDAPServerName"
type="string"
Address Book Provider Attributes
220 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
desc="Address Book LDAP server"
idx="l200"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-LDAPportThe following is an example of the iwtAddressBookProvider-LDAPport attribute.
This attribute’s value can be specified from the Administration Console at the time
of configuring the channel for the address book client. This attribute stores the
address book database server port number. This is used at the time of retrieving
entries for the user and for performing searches in the address book database.
<iwt:Att name="iwtAddressBookProvider-LDAPport"
type="string"
desc="Address Book LDAP server port"
idx="l201"
userConfigurable="true">
<Val>389</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-LDAPAdminIdThe following is an example of the iwtAddressBookProvider-LDAPAdminId
attribute. This attribute’s value can be specified from the Administration Console
at the time of configuring the channel for the address book client. This attribute
stores the address book database administrator’s name. This is used at the time of
retrieving entries for the user and for performing searches in the address book
database.
<iwt:Att name="iwtAddressBookProvider-LDAPAdminId"
type="string"
desc="Address Book Admin user DN"
Address Book Provider Attributes
Chapter 8 Attributes and Schemas 221
idx="l202"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-LDAPAdminPasswordThe following is an example of the
iwtAddressBookProvider-LDAPAdminPassword attribute. This attribute’s value
can be specified from the Administration Console at the time of configuring the
channel for the address book client. This attribute stores the address book database
administrator’s password. This is used at the time of retrieving entries for the user
and for performing searches in the address book database.
<iwt:Att name="iwtAddressBookProvider-LDAPAdminPassword"
type="string"
desc="Address Book Admin user password"
idx="l203"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-LDAPSearchBaseThe following is an example of the iwtAddressBookProvider-LDAPSearchBase
attribute. This attribute gets its value from the Administration Console at the time
of configuring the channel for the address book client. This attribute specifies the
directory search base in which to initiate the search for the LDAP directory.
<iwt:Att name="iwtAddressBookProvider-LDAPSearchBase"
type="string"
desc="Searchbase for the LDAP directory"
idx="l204"
Address Book Provider Attributes
222 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-IMAPServerNameThe following is an example of the iwtAddressBookProvider-IMAPServerName
attribute. This attribute’s value can be specified from the Administration Console
at the time of configuring the address book client channel. This attribute stores the
user’s IMAP server name. This is used for authentication of the Address Book
users.
<iwt:Att name="iwtAddressBookProvider-IMAPServerName"
type="string"
desc="IMAP ServerName to authenticate against"
idx="a200"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-IMAPUserIdThe following is an example of the iwtAddressBookProvider-IMAPUserId
attribute. This attribute gets its value from the edit Address Book page on the
user’s desktop. This attribute stores the user’s IMAP user id. This is used to verify
the validity of the credentials of the user against the specified IMAP server.
<iwt:Att name="iwtAddressBookProvider-IMAPUserId"
type="string"
desc="Address Book User Id"
idx="a201"
userConfigurable="true">
<Val></Val>
Address Book Provider Attributes
Chapter 8 Attributes and Schemas 223
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-IMAPPasswordThe following is an example of the iwtAddressBookProvider-IMAPPassword
attribute. This attribute stores the user’s IMAP user password. This is used to
verify the validity of the credentials of the user against the specified IMAP server.
<iwt:Att name="iwtAddressBookProvider-IMAPPassword"
type="protected"
desc="Address Book User Password"
idx="a202"
userConfigurable="true">
<Val></Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-ldapConnPoolStartThe following is an example of the
iwtAddressBookProvider-ldapConnPoolStart attribute. This attribute can be
modified only by using the ipsadmin command (see “Configuring the Attributes,”
on page 257). This attribute specifies the number of LDAP connections to open
initially in the connection pool used to connect to the LDAP server handling the
address book. By default, upto five connections are established.
<iwt:Att name="iwtAddressBookProvider-ldapConnPoolStart"
type="string"
desc="The number of LDAP connections to start off with"
idx="g100"
userConfigurable="false">
<Val>5</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
Address Book Provider Attributes
224 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
</iwt:Att>
iwtAddressBookProvider-ldapConnPoolMaxThe following is an example of the iwtAddressBookProvider-ldapConnPoolMax
attribute. This attribute can be modified only by using the ipsadmin command (see
“Configuring the Attributes,” on page 257). This attribute specifies the maximum
number of LDAP connections to allow in the connection pool used to connect to the
LDAP server handling the address book. By default, a maximum of twenty
connections are allowed.
<iwt:Att name="iwtAddressBookProvider-ldapConnPoolMax"
type="string"
desc="Maximum number of LDAP connections in the connection pool"
idx="g101"
userConfigurable="false">
<Val>20</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAddressBookProvider-ldapOpTimeoutThe following is an example of the iwtAddressBookProvider-ldapOpTimeout
attribute. This attribute can be modified only by using the ipsadmin command (see
“Configuring the Attributes,” on page 257). This attribute specifies the amount of
time, in milliseconds, after which the LDAP operation to the ldap server must
terminate if it does not receive a response back from the server. By default, the
LDAP operation will terminate after 20000 ms (20 seconds).
<iwt:Att name="iwtAddressBookProvider-ldapOpTimeout"
type="string"
desc="The time in ms after which an ldap operation times out"
idx="g102"
userConfigurable="false">
<Val>20000</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
Bookmark Provider Attributes
Chapter 8 Attributes and Schemas 225
</iwt:Att>
iwtAddressBookProvider-jspAbNumLinesThe following is an example of the iwtAddressBookProvider-jspAbNumLines
attribute. This attribute specifies the number of address book lines (entries) to
display on the corresponding client. This is only applicable to clients that utilize the
address book JSP template files.
<iwt:Att name="iwtAddressBookProvider-jspAbNumLines"
type="stringlist"
desc="Number of AB Lines to Display Via JSP"
idx="X-x111"
userConfigurable="true">
<Val>genericHTML|10</Val>
<Val>cHTML|9</Val>
<Val>WML|9</Val>
<Val>nokia_7110|9</Val>
<Val>siemans_s35|9</Val>
<Val>pana_p503i|9</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Bookmark Provider AttributesThe attributes discussed in Table 8-6 reside in the profile component
iwtWirelessBookmarkProvider .
Table 8-6 iwtWirelessBookmarkProvider* attributes
Attribute Type Description AcceptableValue
iwtWirelessBookmarkProvide
rWML-targets
stringlist This attribute stores the resources or URLs
for a WML client
URL
iwtWirelessBookmarkProvide
rcHTML-targets
stringlist This attribute stores the resources or URLs
for a cHTML client
URL
Bookmark Provider Attributes
226 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtWirelessBookmarkProviderWML-targetsThe following is an example of the iwtWirelessBookmarkProviderWML-targets
attribute. This attribute’s value can be specified:
• From the Administration Console at the time of configuring the client specific
bookmark channel
• From the edit WML Bookmark page on the user’s desktop
This attribute stores the bookmarked URLs or resources for a WML client.
<iwt:Att name="iwtWirelessBookmarkProviderWML-targets"
type="stringlist"
desc="Boomarks"
idx="a200"
userConfigurable="true">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtWirelessBookmarkProvidercHTML-targetsThe following is an example of the
iwtWirelessBookmarkProvidercHTML-targets attribute. This attribute’s value
can be specified:
• From the Administration Console at the time of configuring the client specific
bookmark channel
• From the edit cHTML Bookmark page on the user’s desktop
This attribute stores the bookmarked URLs or resources for a cHTML client.
<iwt:Att name="iwtWirelessBookmarkProvidercHTML-targets"
type="stringlist"
desc="Boomarks"
idx="a200"
userConfigurable="true">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
XML Provider Attributes
Chapter 8 Attributes and Schemas 227
XML Provider AttributesThe attributes discussed in Table 8-7 reside in the profile component
iwtXMLProvider .
iwtXMLProvider-xslCacheThe following is an example of the iwtXMLProvider-xslCache attribute. This
attribute specifies whether or not caching of pre-processed XSLs to use for
transformation is enabled. By default, this is enabled.
<iwt:Att name="iwtXMLProvider-xslCache"
desc="XSL Cache ?"
type="boolean"
idx="X-x301"
userConfigurable="TRUE">
<Val>true</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
<Wperm>ADMIN</Wperm>
</iwt:Att>
Table 8-7 iwtXMLProvider Attributes
Attribute Type Description AcceptableValue
iwtXMLProvider-xslCache
boolean This attribute indicates whether or not
caching is enabled. By default, it is
enabled.
true or false
iwtXMLProvider-url string This attributes stores the location of the
XML content file or the URL that generates
the XML content. This attribute can have
URLs of type of HTTP or HTTPS or File
URL.
Path to XML
source
iwtXMLProvider-xslFileName
string This attribute stores the XSL template file
to be used for transformation.
Absolute path
(ex.
/abc/xyz/test.
xsl) to the
template file or
the base
filename only
XML Provider Attributes
228 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtXMLProvider-urlThe following is an example of the iwtXMLProvider-url attribute. This attribute
specifies the location of the XML content file or the URL that generates the XML
content. This attribute can store:
• URLs of type of HTTP or HTTPS
• File URL
<iwt:Att name="iwtXMLProvider-url"
desc="XML Content URL"
type="string"
idx="a200"
userConfigurable="TRUE">
<Val>http://mum.red.iplanet.com:8080/books.xml</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
<Wperm>ADMIN</Wperm>
</iwt:Att>
iwtXMLProvider-xslFileNameThe following is an example of the iwtXMLProvider-xslFileName attribute. This
attribute specifies the XSL template file to be used for transforming the XML
content. It can store:
• The absolute path to the XSL template file
• The base XSL filename. If this is specified, the path will be determined using
the file lookup mechanism.
<iwt:Att name="iwtXMLProvider-xslFileName"
desc="XSL Filename"
type="string"
idx="X-x109"
userConfigurable="TRUE">
<Val>books1.xsl</Val>
<Rperm>ADMIN</Rperm><Rperm>OWNER</Rperm>
<Wperm>ADMIN</Wperm>
</iwt:Att>
JAXP Jar Attributes
Chapter 8 Attributes and Schemas 229
See the Administration Guide for information on saving XSL template files.
JAXP Jar AttributesThe attributes discussed in Table 8-7 reside in the profile component iwtJAXPJars .
The following is an example of the iwtJAXPJars-jaxpJars attribute. This attribute
stores the path to the JAXP jar files. This includes (and requires) the relative path
from the directory where the iPlanet Portal Server server is installed (which is, by
default, /opt ). These files are used by the XML Provider for the XSLT engine and
these files are used by all the XMLprovider channels.
<iwt:Att name="iwtJAXPJars-jaxpJars"
type="stringlist"
desc="Location of JAXP Jar Files relative to install dir."
idx="X-x1"
userConfigurable="false">
<Val>SUNWips/lib/xmlp/crimson.jar</Val>
<Val>SUNWips/lib/xmlp/xalan.jar</Val>
<Val>SUNWips/lib/xmlp/jaxp.jar</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Table 8-8 iwtJAXPJars Attributes
Attribute Type Description AcceptableValue
iwtJAXPJars-jaxpJars stringlist This attribute stores the location of the
JAXP (Java API for XML Parsing v1.1) jar
files.
Path to
crimson.jar ,
xalan.jar ,
and jaxp.jar
Wireless URLScraper Provider Attributes
230 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Wireless URLScraper Provider AttributesThe attributes discussed in Table 8-9 reside in the profile component
iwtWirelessURLScraperProvider .
iwtWirelessURLScraperProvider-urlThe following is an example of the iwtWirelessURLScraperProvider-url
attribute. This attribute stores the URL from which to scrape the contents for
display on a HTML client. This default content URL is used for serving up content
to HTML browsers. In order to serve this URL to other clients, add the list of clients
to serve this URL to in the
iwtWirelessURLScraperProvider-clientPresentableTo attribute.
<iwt:Att name="iwtWirelessURLScraperProvider-url"
type="string"
desc="Default Content URL"
idx="a200"
userConfigurable="true">
<Val>http://www.iplanet.com</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Table 8-9 iwtWirelessURLScraperProvider Attributes
Attribute Type Description AcceptableValue
iwtWirelessURLScraperProvider-url
stringlist This attribute stores the default Content
URL.
URL_for_html
_clients
iwtWirelessURLScraperProvider-showAsLink
boolean This attribute displays the URL as link for
non-desktop browsers instead of scraping.
true or false
iwtWirelessURLScraperProvider-clientPresentableTo
stringlist This attribute stores the list of clients that
can use the default URL.
clientType
iwtWirelessURLScraperProvider-urlList
stringlist This attribute stores the list of URLs for
clients that can support the default URL.
clientType|UR
L
Wireless URLScraper Provider Attributes
Chapter 8 Attributes and Schemas 231
iwtWirelessURLScraperProvider-showAsLinkThe following is an example of the
iwtWirelessURLScraperProvider-showAsLink attribute. This attribute specifies
whether or not to display the URL as a link on a mobile device instead of scraping
and displaying the contents of the URL on the mobile device.
On a HTML or a cHTML client, the behaviour of the WirelessURLScraper is similar
to the iPlanet Portal Server URLScraper. However, on a WML client, the
WirelessURLScraper can display the contents of only the first card for WML pages,
if the URL contains more than one card.
Since a mobile device has a small amount of memory and display area and since
the scraped contents cannot have multiple cards, this attribute provides an option
to display a link instead of scraping the contents in the URL.
<iwt:Att name="iwtWirelessURLScraperProvider-showAsLink"
type="boolean"
desc="Display the URL as a link for non-desktop browsers"
idx="a206"
userConfigurable="true">
<Val>true</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
The WirelessURLScraper uses the link.template file in the filePath attribute
(defined for the clientType in iwtClient-clientTypes ) under either:
1. <template_dir>/[channelName_as_provided_in_Wizard]/<clientType>
Or
2. <template_dir>/iwtWirelessURLScraperprovider/<clientType>
It uses the link.template file it first encounters.
iwtWirelessURLScraperProvider-clientPresentableToThe following is an example of the
iwtWirelessURLScraperProvider-clientPresentableTo attribute. The default
content URL is used for serving content to HTML browsers. If this URL can also be
served to other HTML and non-HTML clients, add the clients in this attribute.This
Wireless URLScraper Provider Attributes
232 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
attribute stores the list of clients that can use the default content URL. If the value
of this attribute is null (or if no client is listed in this attribute), all clients can use
the default content URL. However, if this attribute contains some value (client),
then only the listed clients can use the default content URL.
<iwt:Att name="iwtWirelessURLScraperProvider-clientPresentableTo"
type="stringlist"
desc="Clients that can use default URL"
idx="a207"
userConfigurable="true">
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtWirelessURLScraperProvider-urlListThe following is an example of the iwtWirelessURLScraperProvider-urlList
attribute. The iwtWirelessURLScraperProvider-urlList attribute stores the
default URLs for all of the supported clientTypes. When a client makes a request,
the isPresentable() method looks-up the URL configured for the requesting
clientType. If a URL is found, the scraper will return true, or false otherwise.
<iwt:Att name="iwtWirelessURLScraperProvider-urlList"
type="stringlist"
desc="List of URLs for various devices"
idx="a205"
userConfigurable="true">
<Val>wml|http://wap.iplanet.com</Val>
<Val>wml|http://wap.sun.com</Val>
<Val>Nokia|http://wap.iplanet.com.nk</Val>
<Val>Nokia7110|http://wap.sun.com.nk7110</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Authentication Module Attributes
Chapter 8 Attributes and Schemas 233
The URLScraper uses the iwtClient-clientTypes attribute in the profile to
retrieve the URL most suitable for the client, based on the filePath for the particular
client. For example, if the request comes from a Nokia 7110 phone, the scraper
fetches the filePath from the iwtClient-clientTypes (such as
filePath=wml/Nokia/Nokia7110 ) and looks in the
iwtWirelessURLScraperProvider-urlList for the page most suitable for this
device. It looks for Nokia7110, followed by Nokia, and falls back to WML in case
no specific URL is available. Note that the search is case-sensitive.
Authentication Module AttributesThe attributes discussed in Table 8-10 reside in the profile component iwtAuth .
Table 8-10 iwtAuth Attributes
Attribute Type Description AcceptableValue
iwtAuth-clientDetectionClass
string This attribute stores the name of the class
implementing the
ClientDetectionInterface.
com.iplanet.po
rtalserver.clien
t.ClientDetecto
r
iwtAuth-clientDetectionEnabled
boolean This attribute determines whether or not
the authentication service will perform
Client Detection. By default, this attribute
is enabled.
true or false
iwtAuth-supportedAuthModules
stringlist This attribute stores the modules
supported by each supported clientType.
clientType|Su
pported_Auth
Modules
iwtAuth-loginWorkerClass
stringlist This attribute stores the loginWorkerClass
for HTML clients.
default|com.ip
lanet.portalser
ver.auth.server
.HTMLLoginW
orker
iwtAuth-loginWorkerClasses
stringlist This attribute identifies which clientType
should use which loginWorker class to
generate the authentication pages.
clientType|Lo
ginWorkerClas
sPackage
Authentication Module Attributes
234 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtAuth-clientDetectionClassThe following is an example of the iwtAuth-clientDetectionClass attribute.
This attribute stores the name of the class implementing the client detection
interface. By default, com.iplanet.portalserver.client.ClientDetector is
the name of the client detection interface.
<iwt:Att name="iwtAuth-clientDetectionClass"
type="string"
desc="Client Detector Class"
idx="X-x28"
userConfigurable="false">
<Val>com.iplanet.portalserver.client.ClientDetector</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtAuth-clientDetectionEnabledThe following is an example of the iwtAuth-clientDetectionEnabled attribute.
This attribute indicates whether or not client detection is enabled for
authentication. That is, this indicates whether or not to detect the clientType
accessing the Mobile Access Pack server at the time of authenticating the client to
the server.
The clientType is determined before any content is returned to the requesting client
and the server looks up the contentType that the client accepts. Other components
also use the clientType value as an index in the Client Data to retrieve information
about the client accessing the server. By default, this is enabled.
<iwt:Att name="iwtAuth-clientDetectionEnabled"
type="boolean"
desc="Client Detection Enabled"
idx="X-x27"
userConfigurable="false">
<Val>true</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Authentication Module Attributes
Chapter 8 Attributes and Schemas 235
To determine the client type, the ClientDetectionInterface will:
• Determine the client type based on the request
• Send a HTTPServletRequest
• Return a String representing the clientType
• If there is an error retrieving the client data, throw a ClientDetectionException
iwtAuth-supportedAuthModulesThe following is an example of the iwtAuth-supportedAuthModules attribute.
This attribute stores the modules supported by a particular client as a string list
with each value in the list having the clientType and the modules it supports. This
is to enable the authentication service to identify which authentication modules are
supported by a particular client. Based on the stringlist stored in this attribute, the
authentication service displays only those module names which are supported by
the requesting client in the authentication menu for the client.
<iwt:Att name="iwtAuth-supportedAuthModules"
type="stringlist"
desc="Supported Auth Modules for Clients"
idx="X-x29"
userConfigurable="false">
<Val>default|Unix;Radius;Ldap</Val>
<Val>WML|Unix;Radius;Ldap</Val>
<Val>cHTML|Ldap</Val>
<Val>Nokia|Unix;SecureID</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
In the above example, the mobile client Nokia users are setup to use only UNIX
and SecureID for authentication. Hence, when a user authenticates using a Nokia,
the user is presented with an authentication menu that allows the user to log in
using UNIX or SecureID.
By default, LDAP is the only supported authentication module for mobile devices.
Authentication Module Attributes
236 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
iwtAuth-loginWorkerClassThe following is an example of the iwtAuth-LoginWorkerClass attribute. This
attribute stores the loginWorkerClassName for HTML clients only. By default,
com.iplanet.portalserver.auth.server.WirelessLoginWorker is the value
for this attribute.
<iwt:Att name="iwtAuth-loginWorkerClass"
desc="Client Specific Auth Page Generator Classes"
type="stringlist"
idx="X-x27"
userConfigurable="FALSE">
<Val>default|com.iplanet.portalserver.auth.server.WirelessLoginWorker</Val>
<Rperm>ADMIN</Rperm>
<Wperm>ADMIN</Wperm>
</iwt:Att>
iwtAuth-loginWorkerClassesThe following is an example of the iwtAuth-loginWorkerClasses attribute. This
attribute identifies which clientType must use which loginWorker class. This
attribute is a stringlist storing the clientType and the loginWorker class name
(clientType|loginWorkerClassName ) for the specified client. By default, no
values are defined in this attribute and the loginWorker class name is derived from
iwtAuth-loginWorkerClass attribute.
<iwt:Att name="iwtAuth-loginWorkerClasses"
type="stringlist”
desc="Pluggable Auth page generator classes for clients"
idx="X-x31"
userConfigurable="false">
NOTE The login worker class can be specific to a clientType and can serve
content for different clientTypes. For example, if the clientType is
WML, there can be a WmlLoginWorker class that can retrieve content
specific to WML clients. See iwtAuth-loginWorkerClass and
iwtAuth-loginWorkerClasses for more information.
Client Detection Module Attributes
Chapter 8 Attributes and Schemas 237
<Val>genericHTML|com.iplanet.portalserver.auth.server.HTMLLoginWorker</Val>
<Val>WML|com.iplanet.portalserver.auth.server.WirelessLoginWorker</Val>
<Val>cHTML|com.iplanet.portalserver.auth.server.WirelessLoginWorker</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
By default, this attribute uses the
com.iplanet.portalserver.auth.server.WirelessLoginWorker class as the
attribute value. The WirelessLoginWorker class also supports WML and cHTML
clients.
Client Detection Module AttributesThe attributes discussed in Table 8-11 reside in the profile component iwtClient .
iwtClient-defaultClientTypeThe following is an example of the iwtClient-defaultClientType attribute. This
attribute stores the clientType that is supported by default. The default clientType
supported by the Mobile Access Pack server is generic HTML.
<iwt:Att name="iwtClient-defaultClientType"
type="string"
desc="default Client Type"
idx="a101"
Table 8-11 iwtClient Attributes
Attribute Type Description AcceptableValue
iwtClient-defaultClientType
string This attributes stores the clientType
supported by default.
clientType
iwtClient-clientTypes stringlist This attribute stores some critical client
specific information for retrieving content
specific to the client.
name=value
Client Detection Module Attributes
238 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
userConfigurable="false">
<Val>genericHTML</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtClient-clientTypesThe following is an example of the iwtClient-clientTypes attribute.
<iwt:Att name="iwtClient-clientTypes"
type="stringlist"
desc="Client Types"
idx="a100"
userConfigurable="false">
<Val>clientType=genericHTML|userAgent=NeverWillMatchAUserAgent|contentType=text/html|fileIdentifier=html|filePath=html|genericHTML=true</Val>
<Val>clientType=WML|userAgent=UP|contentType=text/vnd.wap.wml|fileIdentifier=wml|filePath=wml/UP|counterName=C|escapeWML=true|lineLength=20|charsets=ISO-8859-1;UTF-8</Val>
<Val>clientType=cHTML|userAgent=DoCo|contentType=text/html|fileIdentifier=chtml|filePath=chtml|escapeXML=true|lineLength=20|charsets=Shift_JIS</Val>
<Val>clientType=pana_p503i|contentType=text/html|fileIdentifier=chtml|filePath=chtml/pana_p503i|genericHTML=false|userAgent=P503i|escapeXML=true|lineLength=20|charsets=Shift_JIS</Val>
<Val>clientType=siemens_s35|contentType=text/vnd.wap.wml|fileIdentifier=wml|filePath=wml/UP|genericHTML=false|userAgent=SIE-S35|counterName=C|escapeWML=true|lineLength=20|charsets=UTF-8;ISO-8859-1</Val>
<Val>clientType=nokia_7110|contentType=text/vnd.wap.wml|fileIdentifier=wml|filePath=wml/Nokia/Nokia_7110|genericHTML=false|userAgent=Nokia7110|counterName=C|escapeWML=true|lineLength=20|maxSize=2500|charsets=ISO-8859-1</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Client Detection Module Attributes
Chapter 8 Attributes and Schemas 239
This attribute is a string list with an embedded list of name=value pairs within
each list element. Each list element contains one or more or the following
information about the client:
• charset - The charset element contains a supported (semicolon delimited list of)
character sets for the corresponding client. The list specified here is displayed
in the Edit Options page (on the user’s desktop) for the corresponding client.
This property’s value must be specified when configuring the client.
• clientType - The client type can be stored in this attribute as an arbitrary string
(with a list of name=value pairs) uniquely identifying the client. This attribute
serves as an index to the rest of the Client Data. By default, the following
clients are supported:
• contentType - The contentType element contains the HTTP header value (such
as text, html, wml). It specifies the acceptable content type for the requesting
client. The contentType header is retrieved from the profile service and it can
specified as a forward slash delimited list of acceptable content types. For
fetching the contentType, the default clientType is used if client detection is
disabled. This property’s value must be specified when configuring the client.
• counterName - This is used to add a counter to the URL.
• escapeWML - This attribute is used by certain providers to handle content that
contains special characters. This is a boolean attribute. If set to true, the special
characters discussed below are escaped. The special characters that will be
escaped within the provider content are:
clientType Supported Clients
WML Openwave browsers using WML
cHTML DoCoMo phones using cHTML
nokia_7110 Nokia 7110 phone using WML
pana_p503i Panasonic P503i phones using cHTML
siemens_s35 Siemens S35 phone using WML
Description Symbol Named Entity
Dollar $ $$
Apostrophe ‘ '
Client Detection Module Attributes
240 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
• escapeXML : This attribute is used by certain providers to handle content that
contains special characters. This is a boolean attribute. If set to true, the special
characters listed below are escaped. The special characters that will be escaped
within the provider content are:
• fileIdentifier - The fileIdentifier element indicates the supported file types for
the specified client.
• filePath - The filePath element indicates the path to the client specific data files
(such as templates and JSP files). Template and JSP files reside in
sub-directories based on the desktop type, locale, and component (see “File
Lookup Mechanism,” on page 18 for more information). For client specific file
lookup, the search is based on the client’s filePath attribute specified here. This
property’s value must be specified when configuring the client.
• genericHTML - This attribute specifies whether or not the client accepts
standard HTML.
• ignoreHostHeader - This attribute makes the desktop ignore the host header.
This is particularly useful when the host sends a HTTP/1.0 header.
• lineLength -This specifies the number of characters that may appear on a
single line of the device’s display area.
Quote " "
Ampersand & &
Less Than < <
Greater Than > >
Description Symbol Named Entity
Quote " "
Ampersand & &
Less Than < <
Greater Than > >
Description Symbol Named Entity
Desktop Attributes
Chapter 8 Attributes and Schemas 241
• maxSize - This is used to constrain the output size of the
WirelessFrontProvider. It specifies the approximate number of bytes to send to
the mobile device. The WirelessFrontProvider filters out the content restricting
it to the maxSize limit specified here.
• userAgent - The userAgent attribute stores a search string or filter. It is used to
compare or match against the client’s HTTP user agent header to determine the
clientType. That is, the client detection module iterates over the supported list
of clientTypes, comparing their userAgent against the user agent header of the
client accessing the server. This property’s value must be specified when
configuring the client.
Desktop AttributesThe attributes discussed in reside in the profile component iwtDesktop .
iwtDesktop-clientAllProvidersThe following is an example of iwtDesktop-clientAllProviders attribute. This
attribute stores a list of available channels for each supported client. This attribute
is used to determine which channels are available to a given clientType.
<iwt:Att name="iwtDesktop-clientAllProviders"
type="stringlist"
Table 8-12 iwtDesktop Attributes
Attribute Type Description AcceptableValue
iwtDesktop-clientAllProviders
stringlist This attribute indicates the list of
providers supported for the specified
client.
clientType|cha
nnel1;channel2
iwtDesktop-clientUserSelectedProviders
stringlist This attribute indicates the list of
providers from the list of supported
providers that are made available to the
client.
clientType|cha
nnel1;channel2
iwtDesktop-clientChannelListModules
stringlist This attribute stores the channel list
module for each supported client.
clientType|co
m.iplanet.porta
lserver.desktop
.util.channellist
.ClientChannel
List
Desktop Attributes
242 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
desc="Client Specific Available Providers"
idx="X-x109"
userConfigurable="true">
<Val>nokia_7110|iwtUserInfoProvider;iwtXMLProvider;iwtWirelessBookmarkProviderWML;iwtWirelessPersonalNoteProvider;iwtPostitProvider;iwtCalendarProvider;iwtMailProvider;iwtAddressBookProvider</Val>
<Val>siemens_s35|iwtUserInfoProvider;iwtXMLProvider;iwtWirelessBookmarkProviderWML;iwtWirelessPersonalNoteProvider;iwtPostitProvider;iwtCalendarProvider;iwtMailProvider;iwtAddressBookProvider</Val>
<Val>pana_p503i|iwtUserInfoProvider;iwtXMLProvider;iwtWirelessBookmarkProvidercHTML;iwtWirelessPersonalNoteProvider;iwtPostitProvider;iwtCalendarProvider;iwtMailProvider;iwtAddressBookProvider</Val>
<Val>WML|iwtUserInfoProvider;iwtXMLProvider;iwtWirelessBookmarkProviderWML;iwtWirelessPersonalNoteProvider;iwtPostitProvider;iwtCalendarProvider;iwtMailProvider;iwtAddressBookProvider</Val>
<Val>cHTML|iwtUserInfoProvider;iwtXMLProvider;iwtWirelessBookmarkProvidercHTML;iwtWirelessPersonalNoteProvider;iwtPostitProvider;iwtCalendarProvider;iwtMailProvider;iwtAddressBookProvider</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
<Rperm>OWNER</Rperm>
</iwt:Att>
iwtDesktop-clientUserSelectedProvidersThe following is an example of the iwtDesktop-clientUserSelectedProviders
attribute. This attribute stores a list of selected channels for each supported client.
This attribute is used to determine which channels the user has selected to show up
on a given client. If no channel is selected, the value of this attribute corresponding
to the given clientType is removed from the profile.
<iwt:Att name="iwtDesktop-clientUserSelectedProviders"
type="stringlist"
desc="Client Specific Selected Providers"
idx="X-x110"
userConfigurable="true">
<Val>nokia_7110|iwtUserInfoProvider</Val>
<Val>siemens_s35|iwtUserInfoProvider</Val>
Desktop Attributes
Chapter 8 Attributes and Schemas 243
<Val>pana_p503i|iwtUserInfoProvider</Val>
<Val>WML|iwtUserInfoProvider</Val>
<Val>cHTML|iwtUserInfoProvider</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
iwtDesktop-clientChannelListModulesThe following is an example of the iwtDesktop-clientChannelListModules
attribute. The iPlanet Portal Server channel list module provides a mechanism to
store and retrieve multiple lists of selected and available channels.
The client channel list module extends the support for separate available and
selected lists for each supported clientType. This allows users to specify what
channels to display on their devices.
This attribute stores the client specific channel list modules to enable selection of
channel by each user for each one of the devices setup for them.
<iwt:Att name="iwtDesktop-clientChannelListModules"
type="stringlist"
desc="Client Specific Channel List Modules"
idx="X-x111"
userConfigurable="true">
<Val>nokia_7110|com.iplanet.portalserver.desktop.util.channellist.ClientChannelList</Val>
<Val>siemens_s35|com.iplanet.portalserver.desktop.util.channellist.ClientChannelList</Val>
<Val>pana_p503i|com.iplanet.portalserver.desktop.util.channellist.ClientChannelList</Val>
<Val>WML|com.iplanet.portalserver.desktop.util.channellist.ClientChannelList</Val>
<Val>cHTML|com.iplanet.portalserver.desktop.util.channellist.ClientChannelList</Val>
<Wperm>ADMIN</Wperm>
<Rperm>ADMIN</Rperm>
</iwt:Att>
Desktop Attributes
244 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
245
Appendix A
API Descriptions
This appendix discusses the:
• Client Data API
• Client Detection API
• Client Help API
• Provider APIs
Use the information in this appendix to understand the default implementation of
these APIs. For customizing and extending these APIs, see also Appendix B,
“Sample Tasks.”
Client DataThe Client Data stores client specific information for the Mobile Access Pack server.
When a client contacts the Mobile Access Pack server, the server’s Client Detection
module examines the HTTP request of the client and matches it against the server’s
Client Data objects. Once a suitable match is found for the client’s HTTP header in
the Client Data, the Client Detection module returns a unique identifier
(clientType) for the given HTTP header from the Client Data. This clientType value
is used to retrieve specific properties about the client from the corresponding
elements in the Client Data object. The clientType value is then stored in the
Session Service for subsequent use by other parts of the system.
Client Data objects store various properties about the client. The Client.java API
(in package com.iplanet.portalserver.client ) provides common access to the
Client Data stored in the profile service (refer to the javadocs for more information
on the Client.java API).
Client Data
246 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The Client Java APIThe Mobile Access Pack server uses the following algorithm in its client data
parsing interface. It:
1. Gets a client instance for a specific clientType. If client instance for the specific
clientType is not found, it gets a client instance for the default clientType.
The default clientType is stored in the iwtClient-defaultClientType
attribute.
2. Returns an iterator of Client Data objects for all known clientTypes.
3. Gets the name of the clientType from the Client Data for this client instance.
4. Gets the Client Data value for the specified key.
Null is returned if the key does not exist or if the key value is null.
5. Returns a set of property names for this Client Data instance.
In the profile server, information about each supported client is stored as values of
an attribute. This attribute, iwtClient-clientTypes , contains a list of supported
clientTypes. In the default installation, support for the following clients are
included:
Each listed clientType contains a set of properties which store information about
the corresponding client. For detailed information on these properties, see
“iwtClient-clientTypes,” on page 238.
Client Java APIpublic class Client {
static public Client getInstance(String clientType) {
/*
* Get a Client instance for a specific client type.
clientType Supported Clients
WML Openwave browsers using WML
cHTML DoCoMo phones using cHTML
nokia_7110 Nokia 7110 phone using WML
pana_p503i Panasonic P503i phone using cHTML
siemens_s35 Siemens S35 phone using WML
Client Data
Appendix A API Descriptions 247
* @param clientType - The client type
* @return - The Client instance corresponding to the clientType.
* @exception - ClientException is thrown when clientType is null
or when the requested clientType does not exist.
*/
}
static public Client getDefaultInstance() {
/*
* Get a Client instance for the default client type
* @return - The Client instance corresponding to the default
client type.
*/
}
static public Iterator getAllInstances() {
/*
* @return - Iterator of Client objects for all known client types
*/
}
public String getClientType() {
/*
* Gets the name of the client type for the data in this client
instance.
* @return - Name of the client type
*/
}
public String getProperty(String name) {
/*
* Gets the client property for the specified key
* @param name - The key for the client property to be returned.
* @return - The client property.
* @exception - ClientException is thrown when the requested key
Client Detection
248 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
is not found or when null or empty string is passed as key.
*/
}
public Set getPropertyNames() {
/*
* @return The set of property names for this client data
instance.
*/
}
public void profileChanged(ProfileEvent event) {
/*
* @see
com.iplanet.portalserver.profile.ProfileListener#profileChanged
*/
}
}
Sample Client Data ImplementationFor a sample implementation of the Client API in a wireless provider, see
“Implementing the Client Data API,” on page 276.
Client DetectionThe Mobile Access Pack Client Detection module examines the HTTP header from
the client’s request and matches it against the server’s Client Data objects. By
default, the Client Detection module only considers the client’s userAgent HTTP
header to determine the clientType. Once a suitable match is found for the client’s
userAgent HTTP header in the Client Data, the Client Detection Module returns
the unique identifier (clientType) for the given userAgent HTTP header from the
Client Data object.
By default, client detection is achieved by the client detector object that:
1. Parses data from the HttpServletRequest of the requesting client
2. Performs a method of matching based on the stored clientTypes and their
corresponding userAgents.
Client Detection
Appendix A API Descriptions 249
The Default Client Detection InterfaceThe Mobile Access Pack server uses the following algorithm in its client detection
interface:
public interface ClientDetectionInterface {
/*
* Detects the client type based on the request
* @param request HttpServletRequest
* @return a string representing the clientType
* @exception - ClientDetectionException if there is an error
retrieving the client data.
*/
The Mobile Access Pack server uses the following algorithm to set the clientType:
public String getClientType(HttpServletRequest request) throwsClientDetectionException{
/*
* Get userAgent from the HttpServletRequest
* Get Iterator of known clientTypes from Client
* @param request - The calling object passes in the
HttpServletRequest
* If userAgent equals a known userAgent, then save the clientType
* If saved clientTypes > 1, look at length of filePath, return
clientType with longest filePath
* If clientType not found, return the default clientType
* @return - The string corresponding to the clientType
* @throws ClientDetectionException - Thrown when a default
clientType cannot be found
*/
}
The Mobile Access Pack server uses the following algorithm to compare the
HttpServletRequest userAgent with the userAgent stored for the requesting
clientType:
Client Detection
250 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
protected boolean userAgentCheck(String httpUA, StringclientUA){
/*
* @param httpUA - The HttpServletRequest user-agent
* @param clientUA - The Client userAgent
* @return true or false if they match
*/
}
}
The Mobile Access Pack server Client Detector object:
1. Gets the userAgent from the HttpServletRequest
2. Calls the Client.getAllInstances() method which returns a list of
supported clients.
3. Iterates through each client in the list and calls
Client.getProperty("userAgent") which returns the stored clientType’s
userAgent.
It looks for a partial match between the requestor’s userAgent and the client’s
userAgent that is stored in a hashtable with the clientType and the size of the
userAgent.
If there are multiple matches, the clientType with the longest userAgent is
returned since it assumes that the longer the userAgent is, the more precise it
is. If no userAgent in the hashtable match the requesting client’s userAgent,
then the default clientType is returned. This is achieved through a call to the
Client.getDefaultInstance().getProperty("clientType") .
Developing a Customized Client Detection ModuleWhen developing a customized client detection module, write a method that:
1. Takes the requesting client’s HTTP header value as a string.
2. Matches the HTTP header value against the stored Client Data objects.
The method can match the HTTP header value against any stored property of
the client. When matching, take into account the environment from which the
client is sending its request for an accurate match against the stored Client Data
objects.
3. Returns the clientType value from the Client Data for the matching HTTP
header value.
Client Help
Appendix A API Descriptions 251
See also “Customizing the Client Detection Interface,” on page 263 for detailed
instructions on creating a customized Client Detector and for modifying the
default Client Detector.
Client HelpClient specific help is provided by the WirelessFrontProvider . The
WirelessFrontProvider looks for the attribute iwtDesktop-clientHelpLinks
attribute. If this is found, then a string is returned to the calling method. The
[tag:front_help] , [tag:prov_help] , [tag:help_link] tag swapper tags are
used within the template files to make the link visible. If no client specific help is
found, then an empty string is substituted into the template.
For each provider providing help, there must be the following two template files in
each supported markup language (or for each supported clientType) in the
filepath:
• frontProvider.template - Displays the help link. In this file, the tag
[tag:front_help] is the tag that gets substituted with the help link.
• frontHelpLink.template - Contains the anchor tag around the URL that gets
produced.
That is,
1. The path to the URL is retrieved from the iwtDesktop-clientHelpLinks
attribute.
2. The path is placed inside of the markup in the frontHelpLink.template file.
3. Then the whole string is substituted into the frontProvider.template file.
Each provider uses the Provider API (PAPI) interface to find which methods are
called by the various desktop classes to create the desktop. The two methods,
hasHelp() and getHelp() , are used by the Mobile Access Pack server to display a
help link for each provider.
hasHelp() method/*
@return boolean - This method returns true or false depending onwhether or not it finds <channelName>-clientHelpLinks attribute inthe profile for the particular provider
*/
Provider APIs
252 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
getHelp() method/*
@return java.net.URL - This method returns the help URL thatcorresponds to the requesting clientType from the<channelName>-clientHelpLinks attribute
*/
Provider APIsThe APIs discussed in this section can be used by a provider to:
• Determine whether or not the requesting clientType is supported by the
provider
• Get the content for the client based on whether or not content for the client is
available
• Determine whether or not the channel (for the provider) is editable
Determining PresentabilityEach Provider defines its own logic to determine presentability to the desktop. For
example, presentability can be based on clientType, userAgent type, contentType,
charsets, or whether or not a given template is found for the requesting clientType.
For more information on isPresentabe , see “isPresentable() Method Added to
the Provider API” section in the iPlanet Portal Server 3.0 SP3a Release Notes.
isPresentable API/**
* Determines whether the provider is presentable
* Searches for the key genericHTML with the value true on the clientdata for the session’s client type and returns true
* If there is no genericHTML key, method will return true
* If the session’s client type is named genericHTML
* In both cases, the contentType for the session’s client type mustequal text/html in order for the method to return true
* @return boolean value dictating presentability
* @see com.iplanet.portalserver.providers.Provider#isPresentable
*/
Provider APIs
Appendix A API Descriptions 253
Sample ImplementationIn the following example, presentability is based on the boolean isPresentable .
The wireless provider determines presentability based on the client’s charsets
property.
This example includes:
• Retrieval of the client type from the Session
• Retrieval of the Client instance
• Retrieval of the Client property charsets
Presentability is based on the boolean isPresentable . It is defaulted to true in the
provider init() method.
private String clientType = null;
private String clientCharsets = null;
private String targetCharset = "ISO-2022-JP";
private boolean isPresentable;
public void init(String n, Session s) throws ProviderException {
super.init(n, s);
clientType = "";
clientCharsets = "";
isPresentable = true;
Client clientObj = null;
try {
clientType = s.getProperty("ips.clientType");
clientObj = Client.getInstance(clientType);
clientCharsets = clientObj.getProperty("charsets");
} catch (SessionException se) {
throw new ProviderException("Unable to retrieve Session
client type");
} catch (ClientException ce) { }
// If the targetCharset is not in the clientCharsets list, then
// set Presentability to false. This means that channels based on
// this Provider will not be displayed.
Provider APIs
254 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
if (clientCharsets.indexOf(targetCharset) == -1) {
isPresentable = false;
}
}
Fetching ContentThe getContent() method can be used to determine availability of content for a
client. In the following example, the provider retrieves content based on the
requesting client’s userAgent property. The conditional logic is hardcoded in to the
Provider class.
Sample ImplementationThis example includes the:
• Retrieval of the client type from the Session
• Retrieval of the Client instance
• Retrieval of the Client property userAgent
Content returned is based on the value of the UserAgent and the known hard
coded user agent values in the class.
private String clientType = null;
private String clientUserAgent = null;
private static final String uaUpBrowser = "UP";
private static final String uaNokiaBrowser = "Nokia7110";
private static final String uaDoCoMoBrowser = "DoCo";
public void init(String n, Session s) throws ProviderException {
super.init(n, s);
clientType = "";
clientUserAgent = "";
Client clientObj = null;
try {
clientType = s.getProperty("ips.clientType");
clientObj = Client.getInstance(clientType);
clientUserAgent = clientObj.getProperty("userAgent");
Provider APIs
Appendix A API Descriptions 255
} catch (SessionException se) {
throw new ProviderException("Unable to retrieve Session
client type");
} catch (ClientException ce) { }
}
public StringBuffer getContent(Map m) throws ProviderException {
StringBuffer content = new StringBuffer("");
if ((clientUserAgent.equals(uaUpBrowser)) ||
(clientUserAgent.equals(uaNokiaBrowser))) {
content.append("<P>Hello<BR/> WML World<BR/></P>");
} else if (clientUserAgent.equals(uaDoCoMoBrowser)) {
content.append("<BR>Hello cHTML World<BR>");
} else {
content.append("<BR><B><I>Hello HTML World</I></B><BR>");
}
return content;
}
Determining EditabilityBy default, the Mobile Access Pack providers are only editable via the
genericHTML client. Each Mobile Access Pack provider overrides the
isEditable() method and based on the clientType, they will return false. If the
clientType is genericHTML, then it will invoke the super.isEditable() method.
Sample Implementationpublic boolean isEditable() {
if (isGenericHTML)
return super.isEditable();
return false;
}
The isGenericHTML can be retrieved via:
private String clientType = null;
private boolean isGenericHTML;
Provider APIs
256 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
public void init(String n, Session s) throws ProviderException {
super.init(n, s);
clientType = "";
isGenericHTML = false;
Client clientObj = null;
try {
clientType = s.getProperty("ips.clientType");
clientObj = Client.getInstance(clientType);
isGenericHTML = Boolean.valueOf(clientObj.getProperty
("genericHTML")).booleanValue();
} catch (SessionException se) {
throw new ProviderException("Unable to retrieve Session
client type");
} catch (ClientException ce) { }
}
257
Appendix B
Sample Tasks
The various sections in this appendix include sample tasks for:
• Configuring the Attributes
• Customizing the Templates
• Adding a New ClientType
• Customizing the Client Detection Interface
• Creating Help Links
• Making a Provider Client Aware
• Implementing the Client Data API
Use these sample configuration scenarios to set up and customize your Mobile
Access Pack server. Note that many of the tasks discussed in this chapter can be
performed from the administration console and for more information on
performing these tasks from the administration console, please refer to the Mobile
Access Pack Administration Guide.
Configuring the AttributesThis section discusses how to modify existing component attributes and how to
add new attributes to a component.
Modifying the AttributesThis section discusses how to modify attributes in the component XML file. To
modify the attributes:
1. Log in to the machine running the Mobile Access Pack server and become
superuser.
Configuring the Attributes
258 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
2. Enter:
# < iPS_install_base >/SUNWips/bin/ipsadmin get component<component_name > > < filename >
Here, replace:
❍ iPS_install_base with the installed location of the iPlanet Portal Server
❍ component_name with the name of the profile component to customize. For
example, replace component_name with iwtMailProvider to customize the
mail channel.
❍ filename with the name of the file to redirect the output to
3. Open the file and edit the attributes in the file containing the component
attributes.
This is the file to which the ipsadmin command output was directed to.
4. Save and close the file.
5. Enter:
# < iPS_install_base >/SUNWips/bin/ipsadmin change component<component_name > < filename >
Here, replace:
❍ iPS_install_base with the installed location of the iPlanet Portal Server.
❍ component_name with the name of the component that was customized.
❍ filename with the name of the file that contains the modified attribute
values.
6. Restart the server.
Adding an AttributeTo add an attribute to a Mobile Access Pack server component:
1. Log in to the machine running the Mobile Access Pack server and become
superuser.
2. Enter:
# < iPS_install_base >/SUNWips/bin/ipsadmin delete component<component_name >
Here, replace:
Customizing the Templates
Appendix B Sample Tasks 259
❍ iPS_install_base with the installed location of the iPlanet Portal Server
❍ component_name with the name of the profile component to update. For
example, replace component_name with iwtClient .
This removes the current portal profile for the component.
3. Open the component XML file in /etc/opt/SUNWips/xml directory and add
the new attribute to this file.
For backup purposes, make a copy of the original XML file before adding the
new attribute. For example, enter:
# cp /etc/opt/SUNWips/xml/iwtClient.xml OldiwtClient.xml
4. Import the newly updated component XML file in to the portal profile settings.
For example, to import, enter:
# < iPS_install_base >/SUNWips/bin/ipsadmin -import<component_name >.xml
Here, replace:
❍ iPS_install_base with the installed location of the iPlanet Portal Server
❍ component_name with the name of the profile component. For example,
replace component_name with iwtClient .
5. Restart the server.
Customizing the TemplatesWhen modifying template files, please follow the following recommendations:
1. Log in to the Mobile Access Pack server and become superuser.
2. Create a directory similar to the default directory in
/etc/opt/SUNWips/desktop/default . For example:
a. Change directories to /etc/opt/SUNWips/desktop/default .
b. Enter:
# mkdir NewDesktop
3. Copy files from the default directory in
/etc/opt/SUNWips/desktop/default over to the new directory. For
example, enter:
Adding a New ClientType
260 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
# cp -R default/* NewDesktop
Although you can copy all the files under the default directory, we
recommend you only copy files you wish to change and/or customize over to
the NewDesktop directory. When copying files, use the same directory
hierarchy to the template files.
4. Modify the copied files in the new directory.
Do not modify files under the default directory.
5. Modify the iwtDesktop-type attribute. That is, enter the path to the directory
that contains the customized desktop templates in this attribute. For example,
specify the path to the NewDesktop .
The path must be relative to /etc/opt/SUNWips/desktop . If the server cannot
find the required files under the directory you specify here, it will default to
the files in the default directory.
6. Restart the server.
Adding a New ClientTypeThe Mobile Access Pack server includes support for generic HTML, cHTML, and
WML clients. In order to extend support for other markup languages (or
clientTypes), for example, XYZ markup language, refer to the sample XYZ
configuration scenario in this section.
For information on adding a clientType from the administration console, please see
Chapter 3 in the Mobile Access Pack Administration Guide. From the command
line:
1. Log in to the Mobile Access Pack server machine and become super user.
2. Change directories to /etc/opt/SUNWips .
Develop the appropriate templates to translate the content produced by the
Mobile Access Pack server providers for display on an xyz client.
Configuring Authentication for XYZ Clients:Assuming that XYZ clients are not a derivative of WML or cHTML:
NOTE Do not modify the original template files in the default directory
as this will break uninstall and/or upgrade.
Adding a New ClientType
Appendix B Sample Tasks 261
a. Change directories to auth/default and create a directory for XYZ. That
is, enter:
# cd auth/default
# mkdir xyz
b. Copy files from either html , wml, or chtml directory to the xyz directory.
That is, enter:
# cd xyz
# cp -R ../chtml/* .
Do not modify or change the name of the files copied from the chtml
directory.
c. Modify and save the xyz template files to support XYZ clients.
See “Authentication Template Files,” on page 21 for more information on
template files in this directory.
d. Specify the supported authentication modules for the XYZ clients. That is:
From the Administration Console:
I. Log in to the administration console and select Manage Platform
Settings.
II. Select Authentication and Show Advanced Settings.
III. Specify the supported authentication modules for XYZ clients under
Supported Auth Modules for Clients.
For example, enter xyz|Ldap and select Add.
IV. Select Submit.
From the command line, incorporate the supported authentication
modules for XYZ clients in the iwtAuth-supportedAuthModules attribute
using the ipsadmin command.
See Chapter 8, “Attributes and Schemas” for more information on
modifying this attribute.
NOTE If the XYZ client is a derivative of cHTML or WML, create the xyz
directory under WML or cHTML (accordingly) and copy only the
files you wish to customize for the XYZ clientType into the xyz
directory.
Adding a New ClientType
262 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
e. Specify the loginWorkerClass for XYZ clients. That is, modify the
iwtAuth-loginWorkerClasses attribute value to include the newly added
clientType. See iwtAuth-loginWorkerClasses for more information.
See Chapter 8, “Attributes and Schemas” for more information on this
attribute.
Configuring Channels for XYZ clients:Do not modify files in the /etc/opt/SUNWips/desktop/< default > directory. See
“Modifying the Attributes,” on page 257 for more information.
a. Change directories to desktop/< NewDesktop >/ . That is, enter:
# cd /etc/opt/SUNWips/< NewDesktop >
b. Create a XYZ directory under the provider directory.
For each provider content that will be delivered to the XYZ client, create a
subdirectory for the XYZ client under that provider directory. For
example, to provide mail channel on the XYZ client:
I. Change directories to the mail provider directory. Enter:
# cd iwtMailProvider
II. Create a directory for XYZ clients here. Enter:
# mkdir xyz
III. Copy files from html, chtml, or wml directory over to the xyz
directory. For example, enter:
# cd xyz
# cp -R ../chtml/* .
IV. Modify and save the template files to support clients that use the XYZ
markup language.
Refer to Chapter 5, “Application JSPs” and Chapter 4, “Content
Provider Template Files” for more information on these template files.
3. Modify the iwtClient-clientTypes attribute to define device characteristics
of XYZ clients.
See “Client Detection Module Attributes,” on page 237 and modify this
attribute accordingly. For example, to modify this attribute, enter:
Customizing the Client Detection Interface
Appendix B Sample Tasks 263
<VAL>clientType=XYZ|userAgent=XYZ|contentType=text/xyz|fileIdentifier=xyz|filePath=my_xyz|charset=ISO-8859-1;UTF-8</VAL>
This adds the XYZ clientType and includes important client specific
information to support the XYZ clients.
Enabling Content Delivery for XYZ Clients:In order to set up and deliver content via channels to the newly configured XYZ
client:
1. Log in to the Mobile Access Pack server machine and become super user.
2. Modify the iwtDesktop-clientAllProviders ,
iwtDesktop-clientUserSelectedProviders , and
iwtDesktop-clientChannelListModules attributes. To modify, see
“Configuring the Attributes,” on page 257 for more information. See also
“Desktop Attributes,” on page 241 for information on:
❍ iwtDesktop-clientAllProviders and enter:
xyz|iwtUserInfoProvider;iwtXMLProvider;iwtPostitProvider
This indicates that a user information channel, an XML channel, and a
PostIt channel are supported for a xyz client.
❍ iwtDesktop-clientUserSelectedProviders and enter:
xyz|iwtUserInfoProvider
This makes the xyz client available to the end user from the Mobile Devices
page on their desktop.
❍ iwtDesktop-clientChannelListModules and enter:
xyz|com.iplanet.portalserver.desktop.util.channellist.ClientChannelList.
This adds the clientType to the Client Specific Channel List Module.
The xyz client is now displayed in the Mobile Devices page from the user’s desktop
page and it has access to all of the channels that were made available to it.
Customizing the Client Detection InterfaceThis section provides instructions for:
• Developing a Customized Client Detector
Customizing the Client Detection Interface
264 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
• Modifying the Default Client Detector
Developing a Customized Client DetectorClient detection can be achieved by creating a client detector object that will:
1. Parse data from the HTTPServletRequest of the requesting client
2. Perform some method of matching based on the stored clientTypes and their
corresponding properties
In order to develop such a client detector, the client detection class must:
• Implement an interface called ClientDetectionInterface.
• Contain a method called getClientType which will be passed to the
HTTPServletRequest from the requesting client.
The class can then look at the header information provided by the client in it’s
request, match it against the clientType and its device specific characteristics saved
in the Client Data, and return the clientType that it has received from the Client
Data object.
Sample Client Detection Interfacepublic class SampleCDM implements ClientDetectionInterface {
/*
* Detects the client type based on the Request
* @param request HttpServletRequest
* @return a String representing the clientType
* @exception ClientDetectionException if there is an errorretrieving the client data.
*/
public String getClientType(HttpServletRequest request) throws
ClientDetectionException{
}
public String HTTPheaderCheck(String HTTPheader){
}
}
See Appendix A, “API Descriptions” for detailed information on the Mobile Access
Pack server client detection interface. After developing the client detector class:
Customizing the Client Detection Interface
Appendix B Sample Tasks 265
1. Change the profile settings to enable client detection using the newly
developed class. To change:
a. Modify the iwtAuth-clientDetectionEnabled attribute value.
See “iwtAuth-clientDetectionEnabled,” on page 234 and modify this
attribute value by referring to “Configuring the Attributes,” on page 257.
b. Modify the iwtAuth-clientDetectionClass attribute to use the newly
developed client detector class.
See “iwtAuth-clientDetectionClass,” on page 234 for more information on
this attribute and modify this attribute value by referring to “Configuring
the Attributes,” on page 257.
2. Ensure that the class is placed in the webserver’s classpath.
3. Restart the server.
Modifying the Default Client DetectorBy default, the Mobile Access Pack client detection module performs a substring
matching to match the requesting client’s HTTP header value (or userAgent)
against the Client Data objects. To change the module to use regular expression
matching:
1. Write a class that makes use of the ClientDetectionInterface.
public class SampleCDM implements ClientDetectionInterface {
public String getClientType (HttpServletRequest req) throws
ClientDetectionException{
// get the user-agent from the HttpServletRequest
String clientType = userAgentCheck(String user-agent);
if ((clientType.equals("")) || (clientType == null))
return
Client.getDefaultInstance().getProperty("clientType");
else
return clientType;
}
public String userAgentCheck(String userAgent){
// Implement the regular expression checking within this
Creating Help Links
266 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
// method
// return the clientType if it matches, empty String if it
// does not match
}
}
2. Ensure that the class is placed in the webserver’s classpath
3. Login to the Administration Console and select Manage Platform Settings.
4. Select Authentication and select Show Advanced Settings.
5. Ensure that Client Detection is enabled.
6. Add the customized Client Detection class into the Client Detector class
attribute.
7. Restart the server.
Creating Help LinksIn order to provide assistance with content to the mobile device users, the Mobile
Access Pack server provides a mechanism to display help for the user’s home page
and for each channel in the appropriate markup language.
Enabling Help Content Delivery on a Mobile DeviceThis section discusses how to deliver help content to a mobile device user.
Each provider uses the Provider API (PAPI) interface to find which methods are
called by the various desktop classes to create the desktop. The two methods,
hasHelp() and getHelp() , are used by the Mobile Access Pack server to display a
help link for each provider. See “Client Help,” on page 251 for more information
on these methods.
When configuring the help link for a channel:
1. Create the hasHelp() and getHelp() methods for each supported provider.
Use the sample methods below when writing these methods.
The Mobile Access Pack server providers include these methods in the class
file. Develop only the help content for the Mobile Access Pack server providers
and proceed to Step 2. The sample methods discussed here are only for
providers who do not have the help mechanism built into them.
Creating Help Links
Appendix B Sample Tasks 267
Sample hasHelp() methodThe hasHelp() method must return the boolean value of true or false depending
on whether or not the attribute iwtComponent-clientHelpLinks is found in the
profile for the component.
public class WirelessSampleProvider() extends SampleProvider{
public boolean hasHelp(){
Vector clientLinks = getListProperty("iwtSampleProvider",
"clientHelpLinks", null);
if (clientHelpLinks == null){
return false;
}
for (Enumeration e = clientHelpLinks.elements();
e.hasMoreElements();){
if ((String)e.nextElement() == clientType){
return true;
}
}
return false;
}
}
Sample getHelp() methodThe getHelp() method must return the URL that corresponds to the specified
clientType.
public class SampleProvider() extends ProfileProviderAdapter{
public boolean getHelp(){
Vector clientLinks = getListProperty("iwtSampleProvider",
"clientHelpLinks", null);
if (clientHelpLinks == null){
return false;
}
for (Enumeration e = clientHelpLinks.elements();
e.hasMoreElements();){
Creating Help Links
268 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
String link = (String)e.nextElement();
String url = "";
if (link.indexOf(clientType) > -1){
StringTokenizer tok = new StringTokenizer(link, "|");
String temp = tok.nextToken();
if (temp.equals(clientType)){
url = tok.nextToken();
}
}
}
String userLocale = getStringProperty("iwtUser", "locale",
"en_US");
String localizedUrl = "/docs/" + userLocale+ "/online_help/"
+ url;
String proto = SystemProperties.get("ips.server.protocol");
String host = SystemProperties.get("ips.server.hostname");
String port = SystemProperties.get("ips.server.port");
URL help = null;
try{
help = new URL(proto, host, Integer.parseInt(port),
localizedUrl);
} catch (MalformedURLException mue){
debug.error("Unable to create help link");
help = null;
}
return help;
}
}
2. Add the clientHelpLinks attribute (see <channelName>-clientHelpLinks
for more information) to the profile for the component. To add, refer to
“Configuring the Attributes,” on page 257 for more information.
Making a Provider Client Aware
Appendix B Sample Tasks 269
3. Restart the server.
Help is now made available in the user’s mobile device home page under the
Options selection.
Developing and Storing the Help FilesDevelop help content for all supported clientTypes and their channels and store
the files under<iPS_install_base >/SUNWips/public_html/docs/< locale >/online_help.
Making a Provider Client AwareThis section discusses how to make a provider serve content to multiple
clientTypes (such as cHTML and WML). In order to service multiple clients, a
provider must become aware of the type of client requesting its service; that is, a
provider must become client aware. Use the sample set up scenario in this section
when making a provider client aware.
The sample HelloWorld3 Provider (HelloWorld3Provider ) in
(<iPS_install_base >/SUNWips/sample/desktop/classes/com/iplanet/porta
lserver/providers/helloworld3 ) is the provider used in our example here.
In this example:
Content DeliveryThe WirelessHelloWorld3Provider uses template files to display its content and
to determine its presentability. That is, if template for a specific clientType is
available, the WirelessHelloWorld3Provider will support display of content on
that clientType.
PackageThe WirelessHelloWorld3Provider resides in the same package as the other
iPlanet Portal Server providers:
package com.iplanet.portalserver.providers.helloworld3;
InheritanceInheritance provides the provider with the functionality of the Provider API
(PAPI). The WirelessHelloWorld3Provider inherits from the existing
HelloWorld3Provider provider.
public class WirelessHelloWorld3Provider extends HelloWorld3Provider
Making a Provider Client Aware
270 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Class VariablesThe WirelessHelloWorld3Provider contains the following class variables and
includes a variable for the one generic content template that is used in the
getContent() method.
private static final String contentTemplate = "display.template";
private String clientType = null;
private boolean isGenericHTML;
private boolean isPresentable;
Init Methodpublic void init(String n, Session s) throws ProviderException
ClientTypeClientType refers to the list of clients (such as HTML, cHTML, and/or WML)
supported by the provider. Retrieval of the clientType value stored in the session is
necessary to determine the value of the isGenericHTML attribute. This attribute is
used to determine whether or not to invoke the superclass method.
clientType = "";
isGenericHTML = false;
try {
clientType = s.getProperty("ips.clientType");
isGenericHTML = (Client.getInstance(clientType).
getProperty("genericHTML")).equals("true");
} catch (SessionException se) {
throw new ProviderException("Unable to retrieve Session client
type");
} catch (ClientException ce) {}
PresentabilityPresentability refers to determining whether or not to service the client based on
whether or not the requesting clientType is supported by the provider. That is, the
WirelessHelloWorld3Provider is presentable if a template is found for the
requesting clientType.
Presentability, in this example, is based on the following logic:
* If the content template is found, then the channel is presentableto the client.
Making a Provider Client Aware
Appendix B Sample Tasks 271
Or,
* If isGenericHTML is true, then the superclass method will be used,and the client is assumed to be presentable.
isPresentable = true;
StringBuffer template = null;
if (!isGenericHTML) {
try {
template = getTemplate(contentTemplate);
} catch (ProviderException e) {
isPresentable = false;
}
if (template == null) {
isPresentable = false;
}
}
Content RetrievalContent retrieval is based on the getContent() method.
public StringBuffer getContent(Map m) throws ProviderException
First, check to see if the client is a generic HTML client, defined by the
isGenericHTML attribute. If the boolean value is true, then invoke the superclass
getContent() method.
if (isGenericHTML)
return super.getContent(m);
If the value of the isGenericHTML variable is false, then retrieve the client specific
content template. The getTemplate() method will use the client’s filePath
attribute in the Client Data to locate the template.
StringBuffer content = getTemplate(contentTemplate);
return content;
The following will determine if the provider is presentable:
public boolean isPresentable() {
return isPresentable;
}
Making a Provider Client Aware
272 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
The following method, required as defined by the Provider interface, provides the
provider with a mechanism to indicate whether or not it is editable from a
particular clientType. If this method returns true, then there must be a client aware
getEdit() method.
/*
* Determine if the provider is editable
* @return boolean
*/
public boolean isEditable() {
if (isGenericHTML)
return super.isEditable();
return false;
}
InstallationIt is assumed that the existing iwtHelloWorld3Provider component has been
installed on the system.
Sample iwtHelloWorld3Provider Template FilesCreate the client specific template files for this provider. The template files are
typically located in /etc/opt/SUNWips/desktop/default. In order to set up the
template files, enter:
# mkdir iwtHelloWorld3Provider
# mkdir /iwtHelloWorld3Provider/wml
# touch /iwtHelloWorld3Provider/wml/display.template
# mkdir /iwtHelloWorld3Provider/chtml
# touch /iwtHelloWorld3Provider/chtml/display.template
The display.template file contains something similar to the following:
# cat ./iwtHelloWorld3Provider/wml/display.template
<p>
Wireless Hello World #3!
</p>
# cat ./iwtHelloWorld3Provider/chtml/display.template
Wireless Hello World #3!
Making a Provider Client Aware
Appendix B Sample Tasks 273
<br>
Setup1. Log in to the Mobile Access Pack server administration console and select
Manage Domains.
2. Select the domain and expand Applications.
3. Select Desktop and select iwtHelloWorld3Provider from the list of Available
Channels.
4. Select the Edit Channel button to display the profile settings for the provider.
5. Change the Provider Class Name to
com.iplanet.portalserver.providers.helloworld3.WirelessHelloWorl
d3Provider and select Submit.
This will enable use of the new class that provides the client awareness.
6. Select Show Advanced Options and modify the Client Specific Available
Providers for the clients supported by this provider. For Example,
WML|iwtHelloWorld3Provider
cHTML|iwtHelloWorld3Provider
7. Select Submit.
Sample WirelessHelloWorld3Provider Class FileCreate the WirelessHelloWorld3Provider class file or modify a copy of the
HelloWorld3Provider class file iniPS_install_base/SUNWips/sample/desktop/classes/com/iplanet/portalserver/providers/helloworld3 directory.
package com.iplanet.portalserver.providers.helloworld3;
import java.util.*;
import com.iplanet.portalserver.client.Client;
import com.iplanet.portalserver.client.ClientException;
importcom.iplanet.portalserver.providers.helloworld3.HelloWorld3Provider;
import com.iplanet.portalserver.providers.ProfileProviderAdapter;
import com.iplanet.portalserver.providers.ProviderException;
import com.iplanet.portalserver.session.Session;
import com.iplanet.portalserver.session.SessionID;
Making a Provider Client Aware
274 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
import com.iplanet.portalserver.session.SessionException;
/*
The following example shows how to use the existing HelloWorld3Provider to
create a new Mobile Access Pack provider that is client aware.
*/
public class WirelessHelloWorld3Provider extendsHelloWorld3Provider{
private static final String contentTemplate = "display.template";
private String clientType = null;
private boolean isGenericHTML;
private boolean isPresentable;
/*
* Constructor
*/
public WirelessHelloWorld3Provider() {}
/*
* Initialize the provider
* Presentability of the provider to the desktop is based on theclient type and content template retrieval
* @param n Component name
* @param s Session
* @exception ProviderException
*/
public void init(String n, Session s) throws ProviderException {
super.init(n, s);
clientType = "";
isGenericHTML = false;
isPresentable = true;
try {
clientType = s.getProperty("ips.clientType");
isGenericHTML = (Client.getInstance(clientType).
Making a Provider Client Aware
Appendix B Sample Tasks 275
getProperty("genericHTML")).equals("true");
} catch (SessionException se) {
throw new ProviderException("Unable to retrieve Session
client type");
} catch (ClientException ce) {}
/*
* Determine presentability.
* if (content template found), then the channel is presentable
* if genericHTML is true, then use parent methods for html markupand do not check for the template.
*/
StringBuffer template = null;
if (!isGenericHTML) {
try {
template = getTemplate(contentTemplate);
} catch (ProviderException e) {
isPresentable = false;
}
if (template == null) {
isPresentable = false;
}
}
/*
* Get content for the client.
* @param m
* @return StringBuffer of the provider content.
* @exception ProviderException
*/
public StringBuffer getContent(Map m) throws ProviderException {
if (isGenericHTML) {
return super.getContent(m);
Implementing the Client Data API
276 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
}
StringBuffer content = getTemplate(contentTemplate);
return content;
}
/*
* Determine if the provider is editable
* @return boolean
*/
public boolean isEditable() {
if (isGenericHTML) {
return super.isEditable();
}
return false;
}
/*
* Determine if the provider is presentable
* @return boolean
*/
public boolean isPresentable() {
return isPresentable;
}
}
Implementing the Client Data APIIn order to access the Client Data and retrieve any Client Data for the device
accessing the desktop, within the Provider, develop a method to:
1. Retrieve the clientType string value from the Session using the
ips.clientType property.
2. Retrieve the client instance using the clientType value retrieved from the
Session.
Implementing the Client Data API
Appendix B Sample Tasks 277
The client instance can be used to access the client’s properties in the Client Data
via the Client API. For more information, see “Client Data,” on page 245.
Initializing a Provider with the Init MethodThe following is an example usage of the Client API that relies on the init method
defined in the Provider API (PAPI).
com.iplanet.portalserver.providers
Class ProfileProviderAdapterjava.lang.Object
|
+--com.iplanet.portalserver.providers.ProviderAdapter
|
+--com.iplanet.portalserver.providers.ProfileProviderAdapter
initpublic void init(java.lang.String n, Session s)
throws ProviderException
This initializes the provider. If additional initialization is required by the provider,
this method can be overriden. However, the overriding init() call must always
have super.init() as the first statement executed.
Parameters:n - The unique indentifying name for this provider.
s - The user’s session.
Example:A following is an example implementation of this method in a non-wireless
provider:
public void init(String n, Session s) throws ProviderException {
super.init(n, s);
}
Implementing the Client Data API
278 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Using the Session API to Retrieve the Client TypeIn order to make a provider client aware, retrieve the clientType from the Session.
This clientType represents the type of client accessing the desktop. The clientType
value is used as an index to retrieve appropriate Client Data objects which is
subsequently used to access the client’s file path and device specfic template files
using the file lookup mechanism.
com.iplanet.portalserver.session
Class Sessionjava.lang.Object
|
+--com.iplanet.portalserver.session.Session
Use the getProperty() method to retrieve the clientType. Use the
ips.clientType property name and retrieve the clientType value stored in the
Session. The following example retrieves the clientType value within the
Provider’s init() method.
/*
* Gets the property stored in this session.
* @param name The property name.
* @return The property value in String format.
* @exception A SessionException is thrown if the session reached itsmaximum
* session time, or the session was destroyed, or there was an errorduring
* communication with session service.
*/
public String getProperty(String name) throws SessionException
Example:private String clientType = null;
public void init(String n, Session s) throws ProviderException {
super.init(n, s);
clientType = "";
try {
clientType = s.getProperty("ips.clientType");
Implementing the Client Data API
Appendix B Sample Tasks 279
} catch (SessionException se) {
throw new ProviderException("Unable to retrieve Session
client type");
}
}
The provider can also be made to use the inherited PAPI getSession() method to
retrieve the Session object. This object is set by the super.init(n, s) . So, in the
above example, replace:
clientType = s.getProperty("ips.clientType");
with:
clientType = getSession().getProperty("ips.clientType");
Using the Client APIAfter retrieving the clientType from the Session, use it to retrieve the client
instance.
com.iplanet.portalserver.client
Class Client
java.lang.Object
|
+--java.util.Observable
|
+--com.iplanet.portalserver.client.Client
getInstancepublic static Client getInstance(String clientType) throwsClientException { }
The following example includes the retrieval of the clientType from the Session.
private String clientType = null;
public void init(String n, Session s) throws ProviderException {
super.init(n, s);
clientType = "";
Client clientObj = null;
try {
Implementing the Client Data API
280 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
clientType = s.getProperty("ips.clientType");
clientObj = Client.getInstance(clientType);
} catch (SessionException se) {
throw new ProviderException("Unable to retrieve Session
client type");
} catch (ClientException ce) { }
}
getPropertyAfter establishing the client instance, use the Client getProperty() method to
retrieve data or properties from the Client Data objects.
public String getProperty(String name) throws ClientException { }
The following example includes the:
• Retrieval of the client type from the Session
• Retrieval of the Client instance
• Retrieval of the genericHTML property value from the Client Data and setting
it to a boolean
private String clientType = null;
private boolean isGenericHTML = null;
public void init(String n, Session s) throws ProviderException {
super.init(n, s);
clientType = "";
Client clientObj = null;
isGenericHTML = false;
try {
clientType = s.getProperty("ips.clientType");
clientObj = Client.getInstance(clientType);
isGenericHTML = Boolean.valueOf(clientObj.
getProperty("genericHTML")).booleanValue();
} catch (SessionException se) {
throw new ProviderException("Unable to retrieve Session
client type");
Implementing the Client Data API
Appendix B Sample Tasks 281
} catch (ClientException ce) { }
}
getDefaultInstanceUse the Client API getDefaultInstance() method to retrieve the client instance
corresponding to the default clientType.
public static Client getDefaultInstance() { }
Client clientObj = Client.getDefaultInstance();
getClientTypeUse the Client API getClientType() method to retrieve the clientType string
value for the current client instance.
public String getClientType() { }
The following example retrieves the default client instance and checks to see if the
value of the variable clientType corresponds to the current client instance.
// the variable clientType has been assigned previously
if (Client.getDefaultInstance().getClientType().equals(clientType)){
// do something
}
getAllInstancesUse the Client API getAllInstances() method to retrieve an iterator of Client
Data objects for all known client types.
Iterator knownClients = Client.getAllInstances();
Client client = null;
while (knownClients.hasNext()) {
try {
client = (Client)knownClients.next();
String clientName = client.getProperty("clientType");
String clientUA = client.getProperty("userAgent");
// do something with the value
System.out.println("Client=" + clientName);
System.out.println("UserAgent=" + clientUA);
} catch (ClientException ce) { }
Implementing the Client Data API
282 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
}
getPropertyNamesUse the Client API getPropertyNames() method to retrieve a set of property
names for the Client instance
public Set getPropertyNames() { }
The following example retrieves all the client instances and all the property names
for each client.
Iterator knownClients = Client.getAllInstances();
Client client = null;
HashSet clientProps = null;
while (knownClients.hasNext()) {
try {
client = (Client)knownClients.next();
clientProps = new HashSet(client.getPropertyNames());
String clientName = client.getProperty("clientType");
for (Iterator it=clientProps.iterator(); it.hasNext();) {
System.out.println("clientProps->" + clientName + "->"
+ it.next());
}
} catch (Exception e) { }
}
profileChangedpublic void profileChanged(ProfileEvent event) { }
283
Index
AAddress Book Provider
Attributes 214
clientURL attribute 216
displayEntries attribute 217
IMAPPassword attribute 223
IMAPServerName attribute 222
IMAPUserId attribute 222
Introduction 50
jspAbNumLines attribute 225
LDAPAdminId attribute 220
LDAPAdminPassword attribute 221
ldapConnPoolMax attribute 224
ldapConnPoolStart attribute 223
ldapOpTimeout attribute 224
LDAPport attribute 220
LDAPSearchBase attribute 221
LDAPServerName attribute 219
maxEntries attribute 219
numEntries attribute 218
sortBy attribute 218
sortOrder attribute 217
Tag Swapper tags 179
Template Files 49
Address Book Tag Library
add tag 159
context tag 156
delete tag 160
entries tag 164
entry tag 162
fetch tag 157
get tag 166
Introduction 156
modify tag 161
set tag 168
APIs
Client Java API 246, 248, 276
Introduction 245
Applications
iPlanet Calendar Server 60
iPlanet Messaging Server 67
Personal Address Book 78
Attributes
adding 258
backgroundColor attribute 187
calendarServerName attribute 199
calendarServerPort attribute 199
calendarUserName attribute 198
calendarUserPassword attribute 198
changeUserInfo attribute 210
clientAllProviders attribute 241
clientChannelListModules attribute 243
clientDetectionClass attribute 234
clientDetectionEnabled attribute 234
clientHelpLinks attribute 196
clientPort attribute 207
clientPresentableTo attribute 231
clientTypes attribute 238
clientURL attribute (for address book
provider) 216
clientURL attribute (for calendar provider) 201
clientURL attribute (for mail provider) 206
clientUserSelectedProviders attribute 242
column attribute 189
configuring 257
dayView attribute 200
284 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
defaultClientType attribute 237
description attribute 187
displayEntries attribute 216
displayHeaders attribute 208
editType attribute 190
for Address Book Provider 214
for Calendar Provider 197
for Desktop 241
for HTML channels 185
for JAXP Jar 229
for Mail Provider 204
for the Authentication Module 233
for Wireless Bookmarks Provider 225
for Wireless URL Scraper Provider 230
for XML Provider 227
hasBorder attribute 194
hasFrame attribute 191
hasHelp attribute 188
helpLink attribute 188
IMAPPassword attribute 211, 223
IMAPServerName attribute 210, 222
IMAPUserId attribute 211, 222
Introduction 185
isDetachable attribute 193
isDetached attribute 194
isEditable attribute 191
isMinimizable attribute 192
isMinimized attribute 193
isMovable attribute 192
isRemovable attribute 193
jaxpJars attribute 229
jspAbNumLines attribute 225
jspDescLength attribute 202
jspEventNumLines attribute 204
jspFromLength attribute 212
jspInboxNumLines attribute 212
jspLocationLength attribute 202
jspMsgNumLines attribute 214
jspSubjectLength attribute 213
jspSummaryLength attribute 203
LDAPAdminId attribute 220
LDAPAdminPassword attribute 221
ldapConnPoolMax attribute 224
ldapConnPoolStart attribute 223
ldapOpTimeout attribute 224
LDAPport attribute 220
LDAPSearchBase attribute 221
LDAPServerName attribute 219
LoginWorkerClass attribute 236
loginWorkerClasses attribute 236
maxEntries attribute 219
modifying 257
msgCopyInSent attribute 206
numberHeaders attribute 208
numEntries attribute 218
predefinedReplies attribute 209
refreshTime attribute 196
row attribute 189
showAsLink attribute 231
signature attribute 209
sortBy attribute 218
sortOrder attribute 207, 217
supportedAuthModules attribute 235
targets attribute (for cHTML clients) 226
targets attribute (for WML clients) 226
title attribute 195
url attribute 228, 230
urlList attribute 232
weekView attribute 200
width attribute 190
xslCache attribute 227
xslFileName attribute 228
Authentication
clientDetectionClass attribute 234
clientDetectionEnabled attribute 234
configuring 260
Introduction 21
loginWorkerClass attribute 236
loginWorkerClasses attribute 236
Mechanism 21
Module Attributes 233
supportedAuthModules attribute 235
Template Files 21
BBookmarks Provider
Attributes 225
Introduction 17, 41
Tag Swapper Tags 183
targets attribute (for cHTML clients) 226
targets attribute (for WML clients) 226
Index 285
Template Files 56
CCalendar Provider
Attributes 197
calendarServerName attribute 199
calendarServerPort attribute 199
calendarUserName attribute 198
calendarUserPassword attribute 198
clientURL attribute 201
dayView attribute 201
Introduction 42
jspDescLength attribute 202
jspEventNumLines attribute 204
jspLocationLength attribute 202
jspSummaryLength attribute 203
Tag Swapper Tags 174
Template Files 42
weekView attribute 200
Calendar Tag Library
context tag 119
dateformat tag 124
dateroll tag 126
datetime tag 127
delete tag 123
event tag 129
events tag 131
fetch tag 120
get tag 133
Introduction 119
set tag 134
store tag 121
charset 239
cHTML
Desktop Content Provider Template Files 36
Desktop Front Provider Template Files 28
Desktop Layout Provider Template Files 38
Client Awareness 16
Client Configuration Provider
Add or Remove Mobile Devices Page Template
Files 31
Configure Mobile Devices Page Template
Files 29
Introduction 29
Template Files 29
Client Data
elements 239
Introduction 16, 17, 245, 248
Client Detection
clientTypes attribute 238
customizing 263
defaultClientType attribute 237
Introduction 245, 248
Introductione 16
Module Attributes 237
Client Help
developing 266
Client Java API 246
ClientType 260
clientType 239, 245, 248
Content Provider
cHTML Template Files 36
HTML Template Files 33
Introduction 32
Nokia Template Files 35
WML Template Files 35
contentType 239
counterName 239
DDesktop
Client Configuration Provider 29
clientAllProviders attribute 241
clientChannelListModules attribute 243
clientHelpLinks attribute 251
clientUserSelectedProviders attribute 242
Content Provider 32
Front Provider 25
Layout Provider 36
Options Provider 39
Provider Tag Swapper Tags 171
Template Files 25
286 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
EescapeWML 239
escapeXML 240
FfileIdentifier 240
filePath 240
Front Provider
cHTML Template Files 28
HTML Template Files 26
Introduction 25
Nokia Template Files 27
Template Files 25
WML Template Files 27
GgenericHTML 240
getAllInstances() 247, 281
getClientType() 247, 249, 281
getContent() 254, 270
getDefaultInstance() 247, 250, 281
getHelp() 251, 267
getInstance() 246
getProperty() 247, 250, 253, 280
getPropertyNames() 248, 282
HhasHelp() 251, 267
HTML
Channel Attributes 185
Desktop Add or Remove Mobile Devices Page
Template Files 31
Desktop Configure Mobile Devices Page
Template Files 29
Desktop Content Provider Template Files 33
Desktop Front Provider Template Files 26
Desktop Layout Provider Template Files 37
Desktop Options Provider Template Files 40
IignoreHostHeader 240
iPlanet Calendar Server
Client User Interface 60
Introduction 17
JSP Tag Library 119
JSP Template Files 65
Sample Customizations 66
iPlanet Messaging Server
Client User Interface 67
Introduction 17
JSP Tag Library 135
JSP Template Files 75
Sample Customizations 76
isEditable() 255, 272, 276
isPresentable() 252, 253, 271, 276
JJAXP Jar
Attributes 229
jaxpJars attribute 229
JSP
Applications 18, 59
Tag Attribute Evaluation 89
Tag Libraries 19, 85
Tag Patterns 85
LLayout Provider
cHTML Template Files 38
HTML Template Files 37
Introduction 36
Nokia Template Files 38
Index 287
WML Template Files 38
lineLength 240
MMail Provider
Attributes 204
changeUserInfo attribute 210
clientPort attribute 207
clientURL attribute 206
displayHeaders attribute 208
IMAPPassword attribute 211
IMAPServerName attribute 210
IMAPUserId attribute 211
Introduction 46
jspFromLength attribute 212
jspInboxNumLines attribute 212
jspMsgNumLines attribute 214
jspSubjectLength attribute 213
msgCopyInSent attribute 206
numberHeaders attribute 209
predefinedReplies attribute 209
signature attribute 210
sortOrder attribute 207
Tag Swapper Tags 177
Template Files 46
Mail Tag Library
context tag 135
deletemessage tag 140
fetch tag 136
folder tag 141
folders tag 142
get tag 154
Introduction 135
line tag 149
lines tag 150
message tag 144
messages tag 147
presetmsg tag 152
presetmsgs tag 152
sendmessage tag 139
set tag 155
maxSize 241
Mobile Access Pack
Applications (see Wireless Applications) 18
Attributes 185
Authentication Mechanism 21
Client Data Objects 245
Content Providers (see Wireless Content
Providers) 17
Desktop (see Wireless Desktop) 17
File Lookup Mechanism 18
Introduction 15
Overview 15
NNokia
Desktop Content Provider Template Files 35
Desktop Front Provider Template Files 27, 28
Desktop Layout Provider Template Files 38
OOptions Provider
Introduction 39
PPersonal Address Book
Client User Interface 78
Introduction 17
JSP Tag Library 156
JSP Template Files 81
Sample Customizations 82
Personal Notes Provider
Introduction 17, 41
Tag Swapper Tags 181
Template Files 52
Post-It Notes Provider
Introduction 17, 41
Tag Swapper Tags 182
Template Files 54
profileChanged() 248, 282
288 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001
Providers
Address Book Provider 49
Calendar Provider 42
Desktop Client Configuration Provider 29
Desktop Content Provider 32
Desktop Front Provider 25
Desktop Layout Provider 36
Desktop Options Provider 39
Mail Provider 46
User Information Provider 17
Wireless Bookmarks Provider 41
Wireless Bookmarks Providers 17
Wireless Personal Notes Provider 17, 41
Wireless Post-It Notes Provider 17, 41
Wireless URL Scraper Provider 17, 41
Wireless User Information Provider 17, 41
XML provider 17
TTag Libraries
Introduction 19, 85
iPlanet Calendar Server JSP Tag Library 119
iPlanet Messaging Server JSP Tag Library 135
JSP Tag Patterns 85
Personal Address Book JSP Tag Library 156
Utilities Tag Library 94
Tag Swapper Tags
for Address Book Provider 179
for Calendar Provider 174
for Mail Provider 177
for the Desktop 171
for User Information Provider 183
for Wireless Bookmarks Provider 183
for Wireless Personal Note Provider 181
for Wireless PostIt Note Provider 182
for Wireless URL Scraper Provider 182
Introduction 171
Tags
Address Book Provider Tag Swapper Tags 179
Calendar Provider Tag Swapper Tags 174
Desktop Tag Swapper Tags 171
Introduction 16
JSP bean tag 86
JSP context tag 85
JSP get tag 86
JSP set tag 86
JSP Tag Attribute Evaluation 89
JSP Tags 85
Mail Provider Tag Swapper Tags 177
Post-It Note Provider Tag Swapper Tags 182
Tag Swapper Tags 171
User Information Provider Tag Swapper
Tags 183
Wireless Bookmarks Provider Tag Swapper
Tags 183
Wireless Personal Notes Provider Tag Swapper
Tags 181
Wireless URL Scraper Provider Tag Swapper
Tags 182
Template Files
see Templates 21
Templates
Address Book Provider Template Files 49
Authentication Template Files 21
Calendar Provider Template Files 42
customizing 259
Desktop Client Configuration Provider Template
Files 29
Desktop Content Provider Template Files 32
Desktop Front Provider Template Files 25
Desktop Layout Provider Template Files 36
Desktop Options Provider Template Files 39
Desktop Template Files 25
Introduction 16
iPlanet Calendar Server JSP Template Files 65
iPlanet Messaging Server JSP Template Files 75
JSP Template Files 81
Mail Provider Template Files 46
User Information Provider Template Files 55
Wireless Bookmarks Provider Template Files 56
Wireless Personal Notes Provider Template
Files 52
Wireless Post-It Notes Provider Template
Files 54
Wireless URL Scraper Provider Template Files 54
typographic conventions 14
Index 289
UURL Scraper Provider
Attributes 230
clientPresentableTo attribute 232
Introduction 17, 41
showAsLink attribute 231
Tag Swapper Tags 182
Template Files 54
url attribute 230
urlList attribute 232
User Information Provider
Introduction 17, 41
Tag Swapper Tags 183
Template Files 55
userAgent 241
Utilities Tag Library
attr tag 96
bean tag 102
beans tag 100
catalog tag 112
content tag 114
context tag 94
copy tag 106
edit tag 115
forward tag 117
get tag 103
if tag 107
ifnot tag 108
include tag 118
Introduction 94
link tag 95
list tag 110
msg tag 113
parm tag 99
session tag 110
set tag 104
url tag 97
WWireless
Applications 15, 18
Bookmarks Provider 17
Bookmarks Providers 41
Content Providers 17, 41
Desktop 17
Desktop Front Provider 25
Personal Notes Provider 17, 41
Post-It Notes Provider 17, 41
URL Scraper Provider 17, 41
User Information Provider 41
XML Provider 17
WML
Desktop Content Provider Template Files 35
Desktop Front Provider Template Files 27
Desktop Layout Provider Template Files 38
XXML Provider
Attributes 227
Introduction 17
url attribute 228
xslCache attribute 227
xslFileName attribute 228
290 iPlanet Portal Server: Mobile Access Pack Programmer’s Guide • November 2001