}
// access mode
InstanceContext instanceContext = invocation.getInstanceContext();
ParameterValidation.throwIllegalArgExceptionIfNull(instanceContext, "instance context");
AccessMode accessMode = instanceContext.getAccessMode();
ParameterValidation.throwIllegalArgExceptionIfNull(accessMode, "access mode");
if (debug)
{
log.debug("Portlet is requesting " + accessMode + " access mode");
}