1 16 17 package org.apache.jetspeed.modules.actions.controls; 18 19 import org.apache.turbine.modules.Action; 21 import org.apache.turbine.util.RunData; 22 23 import org.apache.jetspeed.services.logging.JetspeedLogFactoryService; 25 import org.apache.jetspeed.services.logging.JetspeedLogger; 26 import org.apache.jetspeed.services.rundata.JetspeedRunData; 27 import org.apache.jetspeed.om.profile.Entry; 28 29 39 public class Maximize extends Action 40 { 41 42 45 private static final JetspeedLogger logger = JetspeedLogFactoryService.getLogger(Maximize.class.getName()); 46 47 50 public void doPerform( RunData rundata ) throws Exception 51 { 52 if( rundata.getUser() == null) 54 { 55 return; 56 } 57 String peid = rundata.getParameters().getString("js_peid"); 59 if ( peid == null ) 60 { 61 return; 62 } 63 64 JetspeedRunData jdata = (JetspeedRunData)rundata; 66 67 Entry entry = jdata.getProfile().getDocument().getEntryById(peid); 69 if ( entry == null ) 70 { 71 logger.warn("Failed to get PEID (" + peid + ") entry for User (" 72 + rundata.getUser().getName() + ")"); 73 return; 74 } 75 76 jdata.getUser().setTemp("js_peid",peid); 78 79 } 80 } 81 | Popular Tags |