/**
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
*
* Copyright (c) 2007 Sun Microsystems Inc. All Rights Reserved
*
* The contents of this file are subject to the terms
* of the Common Development and Distribution License
* (the License). You may not use this file except in
* compliance with the License.
*
* You can obtain a copy of the License at
* See the License for the specific language governing
* permission and limitations under the License.
*
* When distributing Covered Code, include this CDDL
* Header Notice in each file and include the License file
* at opensso/legal/CDDLv1.0.txt.
* If applicable, add the following below the CDDL Header,
* with the fields enclosed by brackets [] replaced by
* your own identifying information:
* "Portions Copyrighted [year] [name of copyright owner]"
*
* $Id: PageTrail.java,v 1.2 2008/06/25 05:42:48 qcheng Exp $
*
*/
/*
* Portions Copyrighted [2011] [ForgeRock AS]
*/
/**
* This class captures a chain of markers where each marker contains information
* on the page session needed to activate view bean.
*/
public class PageTrail
implements Serializable
{
/**
* Default constructor that is required for serialization.
*/
public PageTrail() {
}
/**
* Creates a page trail.
*
* @param displayName Display Name.
* @param viewBeanClassName Class Name of View Bean.
* @param pageSessionAttributeValues Map of attribute name (String) to
* a value (Serializable).
*/
public PageTrail(
) {
}
/**
* Set trail.
*
* @param displayName Display Name.
* @param viewBeanClassName Class Name of View Bean.
* @param pageSessionAttributeValues Map of attribute name (String) to
* a value (Serializable).
*/
public void set(
) {
}
/**
* Swap the last item of trail.
*
* @param displayName Display Name.
* @param viewBeanClassName Class Name of View Bean.
* @param pageSessionAttributeValues Map of attribute name (String) to
* a value (Serializable).
*/
public void swap(
) {
}
/**
* Adds item to trail.
*
* @param displayName Display Name.
* @param viewBeanClassName Class Name of View Bean.
* @param pageSessionAttributeValues Map of attribute name (String) to
* a value (Serializable).
*/
public void add(
) {
}
}
}
/**
* Pops the last item in the list.
*
* @return the Marker of the second last item.
*/
try {
} catch (AMConsoleException e) {
// NO-OP
// This exception sbould not occur because checks are already
// done before calling backTo methid.
return null;
}
}
/**
* Discards items from a given index (exclusive) to the end.
*
* @param idx Index.
* @return the Marker for <code>idx</code>.
* @throws AMConsoleException if cannot be discard items in page trail.
*/
throws AMConsoleException
{
throw new AMConsoleException(
"cannot be discard items in page trail");
}
}
}
/**
* Returns a list of marker in this trail.
*
* @return a list of marker in this trail.
*/
return trail;
}
}
}
/**
* An item in a chain of bread crumb.
*/
public class Marker
implements Serializable
{
public Marker() {
}
public Marker(
) {
}
this.displayName = displayName;
this.viewBeanClassName = viewBeanClassName;
}
return displayName;
}
return viewBeanClassName;
}
return pageSessionAttributeValues;
}
return "\ndisplayName=" + displayName +
"\nviewBeanClassName=" + viewBeanClassName +
"\npageSessionAttributeValues=" + pageSessionAttributeValues;
}
}
}