SubConfigEditViewBean.java revision 44533057912ac5c4bca52935b8fbc8e6d59d0671
/**
* 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: SubConfigEditViewBean.java,v 1.2 2008/06/25 05:43:17 qcheng Exp $
*
* Portions Copyrighted 2015 ForgeRock AS.
*/
public class SubConfigEditViewBean extends DynamicRequestViewBean {
public static final String DEFAULT_DISPLAY_URL =
private CCPageTitleModel ptModel;
private AMPropertySheetModel propertySheetModel;
private boolean init;
private boolean submitCycle;
private boolean populatedSubConfigTable;
protected String serviceName;
/**
* Creates a view to prompt user for services to be added to realm.
*/
public SubConfigEditViewBean() {
super("SubConfigEdit");
}
protected void initialize() {
if (!init) {
this.serviceName = serviceName;
super.initialize();
init = true;
}
}
}
protected void registerChildren() {
super.registerChildren();
ptModel.registerChildren(this);
}
if (!populatedSubConfigTable &&
) {
populatedSubConfigTable = true;
if (model.hasGlobalSubSchema()) {
}
}
} else {
}
return view;
}
boolean firstEntry = true;
if (firstEntry) {
firstEntry = false;
} else {
}
}
}
}
}
private void createPageTitleModel() {
ptModel = new CCPageTitleModel(
}
private void createPropertyModel() {
try {
} catch (AMConsoleException e) {
e.getMessage());
}
}
protected AMModel getModelInternal() {
try {
} catch (AMConsoleException e) {
//
}
return model;
}
throws ModelControlException {
super.beginDisplay(event);
if (!submitCycle) {
try {
// If this is a dynamic request the UI is set with unsaved attribute values
if (dynamicRequest) {
} else {
}
} catch (AMConsoleException a) {
"message.warning", "noproperties.message");
}
}
if (model.hasGlobalSubSchema()){
if (!submitCycle) {
}
if (createable.isEmpty()) {
}
}
}
private String getParentId() {
}
/**
* Handles cancel request.
*
* @param event Request invocation event
*/
}
/**
* Handles reset request.
*
* @param event Request invocation event
*/
forwardTo();
}
private void backToProfileViewBean() {
backTrail();
}
/**
* Handles next button request.
*
* @param event Request invocation event.
*/
throws ModelControlException {
submitCycle = true;
try {
} catch (AMConsoleException e) {
e.getMessage());
forwardTo();
}
}
/**
* Adds sub configuration.
*
* @param event Request Invocation Event.
*/
public void handleTblSubConfigButtonAddRequest(
) {
if (!createable.isEmpty()) {
} else {
SubConfigAddViewBean.class);
}
} else {
forwardTo();
}
}
private void addViewBeanClassToPageSession() {
}
}
/**
* Deletes sub configuration.
*
* @param event Request Invocation Event.
* @throws ModelControlException if table model cannot be restored.
*/
public void handleTblSubConfigButtonDeleteRequest(
) throws ModelControlException {
submitCycle = true;
}
try {
"subconfig.message.deleted");
} else {
"subconfig.message.deleted.pural");
}
} catch (AMConsoleException e) {
e.getMessage());
}
submitCycle = false;
forwardTo();
}
/**
* Handles edit sub configuration request.
*
* @param event Request Invocation Event.
*/
ArrayList subConfigNames = (ArrayList)getPageSessionAttribute(AMServiceProfile.PG_SESSION_SUB_CONFIG_IDS);
if (subConfigNames == null) {
subConfigNames = new ArrayList();
}
}
protected String getBreadCrumbDisplayName() {
return "breadcrumbs.services.subconfig.edit";
}
protected boolean startPageTrail() {
return false;
}
try {
} catch (SSOException e) {
} catch (SMSException e) {
} catch (InstantiationException e) {
} catch (IllegalAccessException e) {
}
forwardTo();
}
// Not used in this class
}
try {
} catch (AMConsoleException e) {
} catch (ModelControlException e) {
}
return Collections.emptyMap();
}
}