using Sagitec.Model;
using Sagitec.Rules.Core.Instance.Attributes;
using Sagitec.Rules.Core.Interface;
using Sagitec.Rules.Interface.Context;
using System.Collections.Generic;
namespace Sagitec.Interface
{
/// <summary>
/// Defines methods for generating the adhoc report and loading its schema.
/// </summary>
[GlobalSingletonInstance]
public interface IInstanceAdhocReportHelper: ICoreInstance
{
/// <summary>
/// Initializes the execution context.
/// </summary>
/// <param name="aobjExecutionContext">An object of the type IExecutionContext which needs to be initialized. </param>
void InitializeContext(IExecutionContext aobjExecutionContext);
/// <summary>
/// Generates the adhoc report.
/// </summary>
/// <param name="alngReportId">The Id of the adhoc report created on Xelence which needs to be generated. </param>
/// <param name="aaintUserSerialId">The Id of the user for which the adhoc report needs to be generated. </param>
/// <param name="aintAdHocReportSerialId">The Id of the adhoc report created on application which needs to be generated. </param>
/// <param name="astrAdhocReportName">The name of the adhoc report that needs to be generated on the application side. </param>
/// <param name="lobjAdHocReportJson">A JSON object that defines the type and layout of the adhoc report. </param>
/// <returns>True, if the adhoc report is successfully generated; otherwise, false. </returns>
bool GenerateAdhocReportFile(long alngReportId, int aaintUserSerialId, int aintAdHocReportSerialId, string astrAdhocReportName, IentBase lobjAdHocReportJson);
/// <summary>
/// Loads the schema for the adhoc report.
/// </summary>
/// <param name="alngReportId">The Id of the adhoc report for which the schema needs to be loaded. </param>
/// <returns>A list containing the schema of the adhoc report. </returns>
List<utlSchemaColumn> LoadAdhocReportSchema(long alngReportId);
}
}
#Rules