Bug 131577 Script Access to Factory/Presentation Mode
There is no easy way from within BIRT scripting to access whether a report is in factoryMode or presentationMode. The ExecutionContext object on the ReportContextImpl class has this information, but it is not available through scripting. I wonder if it makes sense to just expose the ExecutionContext and let the developer get the ExecutionContext or work from there, or if it is better to maintain an abstraction layer off of the ExecutionContext with all of the functionality wrapped off. To me it is more useful to divide the script functions into some that are basic and fully supported and others that are in the category of Kung-Fu scripting where the developer has to have a relatively high level of experience. So if we decide this is a basic function, we expose the factory mode in the IReportContext interface. If it is deemed to be Kung-Fu scripting, then we just expose a handle to the ExecutionContext and let developers figure it themselves. Thoughts?
engine/org.eclipse.birt.report.engine/src/org/eclipse/birt/report/engine/api/impl/GetParameterDefinitionTask.java
return;
			}
			catch ( BirtException ex )
			{
				ex.printStackTrace( );
			}
		}
		dataCache.put( parameterGroup.getName( ), null );
	}
	/**
	 * The second step to work with the cascading parameters. Get the selection
	 * choices for a parameter in the cascading group. The parameter to work on
	 * is the parameter on the next level in the parameter cascading hierarchy.
	 * For the "parameter to work on", please see the following example. Assume
	 * we have a cascading parameter group as Country - State - City. If user
	 * specified an empty array in groupKeyValues (meaning user doesn't have any
	 * parameter value), the parameter to work on will be the first level which
	 * is Country in this case. If user specified groupKeyValues as
	 * Object[]{"USA"} (meaning user has set the value of the top level), the
	 * parameter to work on will be the second level which is State in "USA" in
	 * this case. If user specified groupKeyValues as Object[]{"USA", "CA"}
	 * (meaning user has set the values of the top and the second level), the
	 * parameter to work on will be the third level which is City in "USA, CA"
	 * in this case.
	 * 
	 * @param parameterGroupName -
	 *            the cascading parameter group name
	 * @param groupKeyValues -
	 *            the array of known parameter values (see the example above)
	 * @return the selection list of the parameter to work on