com.plumtree.portaluiinfrastructure.friendlyurl
Class FriendlyURLParser

java.lang.Object
  extended by com.plumtree.portaluiinfrastructure.friendlyurl.FriendlyURLParser
All Implemented Interfaces:
IFriendlyURLParser
Direct Known Subclasses:
APIFriendlyURLParser, CommunityFriendlyURLParser, DocumentFriendlyURLParser, KDFriendlyURLParser, MyPageFriendlyURLParser, RSSFriendlyURLParser, SearchFriendlyURLParser, UserFriendlyURLParser

public class FriendlyURLParser
extends java.lang.Object
implements IFriendlyURLParser

Generic Friendly URL parser capable of parsing the name of the object.

Author:
duang

Field Summary
protected  int m_nChildId
           
protected  int m_nObjectId
           
protected  java.lang.String m_strChildName
           
protected  java.lang.String m_strClassId
           
protected  java.lang.String m_strKeyword
           
protected  java.lang.String m_strObjectName
           
 
Constructor Summary
protected FriendlyURLParser()
          DCA - this is only here in case child classes doesn't want to call the constructor below
  FriendlyURLParser(java.lang.String strKeyword, java.lang.String strClassId, XPStringTokenizer stURLTokens)
           
 
Method Summary
 int GetChildId()
          Returns the child Id if one was parsed from the URL, 0 otherwise.
 java.lang.String GetChildName(boolean bDeNormalize)
          Returns the child name if one was parsed from the URL, null otherwise.
 java.lang.String GetClassId()
          Returns the class Id mapped to the keyword parsed from the URL.
 java.lang.String GetKeyword()
          Returns the keyword if one was parsed from the URL, null otherwise.
 int GetObjectId()
          Returns the object Id if one was parsed from the URL, 0 otherwise.
 java.lang.String GetObjectName(boolean bDeNormalize)
          Returns the object name if one was parsed from the URL, null otherwise.
 void SetClassId(java.lang.String strClassId)
          Sets the class Id mapped to the keyword parsed from the URL.
protected  java.lang.String URLDecode(java.lang.String strEncodedString)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_strKeyword

protected java.lang.String m_strKeyword

m_strClassId

protected java.lang.String m_strClassId

m_strObjectName

protected java.lang.String m_strObjectName

m_nObjectId

protected int m_nObjectId

m_strChildName

protected java.lang.String m_strChildName

m_nChildId

protected int m_nChildId
Constructor Detail

FriendlyURLParser

protected FriendlyURLParser()
DCA - this is only here in case child classes doesn't want to call the constructor below


FriendlyURLParser

public FriendlyURLParser(java.lang.String strKeyword,
                         java.lang.String strClassId,
                         XPStringTokenizer stURLTokens)
Method Detail

GetChildId

public int GetChildId()
Description copied from interface: IFriendlyURLParser
Returns the child Id if one was parsed from the URL, 0 otherwise.

Specified by:
GetChildId in interface IFriendlyURLParser
Returns:

GetClassId

public java.lang.String GetClassId()
Description copied from interface: IFriendlyURLParser
Returns the class Id mapped to the keyword parsed from the URL.

Specified by:
GetClassId in interface IFriendlyURLParser
Returns:

SetClassId

public void SetClassId(java.lang.String strClassId)
Description copied from interface: IFriendlyURLParser
Sets the class Id mapped to the keyword parsed from the URL.

Specified by:
SetClassId in interface IFriendlyURLParser

GetObjectId

public int GetObjectId()
Description copied from interface: IFriendlyURLParser
Returns the object Id if one was parsed from the URL, 0 otherwise.

Specified by:
GetObjectId in interface IFriendlyURLParser
Returns:

GetChildName

public java.lang.String GetChildName(boolean bDeNormalize)
Description copied from interface: IFriendlyURLParser
Returns the child name if one was parsed from the URL, null otherwise.

Specified by:
GetChildName in interface IFriendlyURLParser
Parameters:
bDeNormalize - Indicates whether the name should be denormalized before being returned
Returns:

GetKeyword

public java.lang.String GetKeyword()
Description copied from interface: IFriendlyURLParser
Returns the keyword if one was parsed from the URL, null otherwise.

Specified by:
GetKeyword in interface IFriendlyURLParser
Returns:

GetObjectName

public java.lang.String GetObjectName(boolean bDeNormalize)
Description copied from interface: IFriendlyURLParser
Returns the object name if one was parsed from the URL, null otherwise.

Specified by:
GetObjectName in interface IFriendlyURLParser
Parameters:
bDeNormalize - Indicates whether the name should be denormalized before being returned
Returns:

URLDecode

protected java.lang.String URLDecode(java.lang.String strEncodedString)



Copyright © 2002,2003,2004,2005 Plumtree Software, Inc., All Rights Reserved.