using Consulenza.ReportCommon; namespace Consulenza.ReportWriter.Business { /// /// Facade pattern against RendererPDF and ReportEnvironment: /// It bounds ReportEnvironment and RendererPDF to serve representational members (Y, X, Template Pdf and so on ...) /// for sections drawing methods. /// Sealed keyword prevents inheritance and constrains this istance to a primitive instantiation process. /// public sealed class RendererFacade : RendererPDF { /// /// Constructor that bounds with ReportEnvironment and FrameClassMapperManager. /// /// public RendererFacade(ReportEnvironment environment) : base(environment) { } } /// /// Facade pattern: /// Gets ReportEnvironment and DataModel and bounds them to RendererPDF. /// Sealed prevents inheritance and constrains to a primitive instantiation process: /// It's impossible to obtain new instantiations of RendererFacade and ReportEnvironment types /// from current EnvironmentFacade istance. /// public sealed class EnvironmentFacade { public Consulenza.DataServices.DatiSeiUnico datiSeiUnico; private readonly RendererFacade _rendererFacade; private readonly ReportEnvironment _reportEnvironment; /// /// Get RendererFacade property. /// public RendererFacade RendererFacade { get { return _rendererFacade; } } /// /// Get ReportEnvironment property /// public ReportEnvironment ReportEnvironment { get { return _reportEnvironment; } } /// /// Constructor: bounds ReportEnvironment and DataModel to serve internal RendererFacade, ReportEnvironment and FrameClassMapperManager istances. /// /// public EnvironmentFacade(ReportEnvironment environment) { _rendererFacade = new RendererFacade(environment); _reportEnvironment = environment; } } /// /// Classe che espone alla RendererPDF le proprietà del Chapter. /// public sealed class ChapterFacade { /// /// Bool che indica se il capitolo deve essere ripetuto in tutte le pagine quando c'è un salto pagina. /// public bool RepeatOnEachPage { get; set; } } }