com.sun.identity.liberty.ws.paos
Class  PAOSHeader
java.lang.Object
  |
  +--com.sun.identity.liberty.ws.paos.PAOSHeader
- public class PAOSHeader- extends java.lang.Object
The PAOSHeader class is used by a web application
 on HTTP server side to parse a PAOS header in an HTTP request
 from the user agent side. This header is used by the User Agent
 as a PAOS server to publish which services are available, which
 PAOS versions are supported, etc..
 An example PAOS header looks like the following:
 
 PAOS: ver="ver1","ver2",ext="ext1","ext2";"service1","opt11",
           "opt12";"service2","opt21","opt22"
 
 This class has methods for obtaining all the parts inside such
 a header.
| Constructor Summary | 
| PAOSHeader(javax.servlet.http.HttpServletRequest req)This constructor accepts an
 HttpServletRequestand tries to parse thePAOSheader string if there is one
 inside. | 
| PAOSHeader(java.lang.String paosHeaderString)This constructor accepts a
 PAOSheader string and tries to
 parse it. | 
 
| Method Summary | 
|  java.util.Iterator | getExtensions()Returns the list of extensions as
 Strings. | 
|  java.util.HashMap | getServicesAndOptions()Returns a
 HashMapcontaining the services and
 corresponding options. | 
|  java.util.Iterator | getVersions()Returns the list of versions as
 Strings. | 
 
| Methods inherited from class java.lang.Object | 
| equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
PAOSHeader
public PAOSHeader(javax.servlet.http.HttpServletRequest req)
           throws PAOSException
- This constructor accepts an HttpServletRequestand tries to parse thePAOSheader string if there is one
 inside.
- 
- Parameters:
- req- the incoming HTTP request which is supposed
            to contain the- PAOSheader.
- Throws:
- PAOSException- if there are any parsing errors because
            the- PAOSheader is not there at all or
            because its content is not compliant to the- PAOSspecifications.
 
PAOSHeader
public PAOSHeader(java.lang.String paosHeaderString)
           throws PAOSException
- This constructor accepts a PAOSheader string and tries to
 parse it.
- 
- Parameters:
- paosHeaderString- the- PAOSheader string which
        supposedly contains information on available services, etc..
- Throws:
- PAOSException- if there are any parsing error because the- PAOSheader is invalid.
 
getVersions
public java.util.Iterator getVersions()
- Returns the list of versions as Strings.
- 
- Returns:
- the list of versions as Strings.
 
getExtensions
public java.util.Iterator getExtensions()
- Returns the list of extensions as Strings.
- 
- Returns:
- the list of extensions as Strings.
 
getServicesAndOptions
public java.util.HashMap getServicesAndOptions()
- Returns a HashMapcontaining the services and
 corresponding options.
- 
- Returns:
- a HashMapwith each key being a service represented
         as aString, and with each value being aSetof the corresponding options represented
         asStrings
 
Copyright 2005 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.