using System;
using System.Collections.Generic;
namespace FastReport.Utils
{
///
/// Script security event arguments.
///
public class ScriptSecurityEventArgs : EventArgs
{
///
/// Gets the report language.
///
/// The report language.
public Language ReportLanguage
{
get
{
return Report.ScriptLanguage;
}
}
private Report _report;
///
/// Gets the report.
///
/// The report.
public Report Report
{
get
{
return _report;
}
}
private string _reportScript;
///
/// Gets the report script.
///
/// The report script.
public string ReportScript
{
get
{
return _reportScript;
}
}
private string[] _references;
///
/// Gets the references of script.
///
/// Script references
public string[] References
{
get
{
return _references;
}
}
private bool _isValid = true;
///
/// Gets or sets value if script is allowed to compile
///
/// true if is valid; otherwise, false.
public bool IsValid
{
get
{
return _isValid;
}
set
{
_isValid = value;
}
}
///
/// Initializes a new instance of the class.
///
/// Report.
/// Report's script.
/// Report's references.
public ScriptSecurityEventArgs(Report report, string script, string[] refs)
{
_report = report;
_reportScript = script;
_references = refs;
}
}
}