MMOJr.ESI.Standard
1.0.0
See the version list below for details.
dotnet add package MMOJr.ESI.Standard --version 1.0.0
NuGet\Install-Package MMOJr.ESI.Standard -Version 1.0.0
<PackageReference Include="MMOJr.ESI.Standard" Version="1.0.0" />
paket add MMOJr.ESI.Standard --version 1.0.0
#r "nuget: MMOJr.ESI.Standard, 1.0.0"
// Install MMOJr.ESI.Standard as a Cake Addin
#addin nuget:?package=MMOJr.ESI.Standard&version=1.0.0
// Install MMOJr.ESI.Standard as a Cake Tool
#tool nuget:?package=MMOJr.ESI.Standard&version=1.0.0
- Defining ESI
E S I (Execute Scope Instances), is an Object Oriented Programming Model, in a simple and effective way, that meets all 5 S O L I D Principles.
Currently we have the most common structures such as Business (Business), Repository (Data Repository) and Entity (Data Type). Where Business invokes Repository, coupling everything in a Business Method. The Controller in turn calls Business to exposure in APIs, etc ...
See how it looks with ESI:
- Business does not invoke Repository and vice versa. And you don't even need to, because the Controller is in charge of making this negotiation between the two layers;
- In the Controller you " join " the Business x Repository Layers, in a simple and well structured way, where each Instance added in the Space is available for other Controllers and other Scopes, so on;
- The Entity (Data Type) represented in the TData loaded in the ESIControllerBase is available and updated for each call of the ESIBusinessBase and ESIRepositoryBase Instances;
- The System is completely decoupled, as each Instance of Business and Repository Classes does and performs a single, very specific function;
We have the base classes:
- ESIBusinessBase <TData> - must implement the Abstract method protected void OnExecute (IESIConfigurationBusiness esiConfiguration);
- ESIRepositoryBase <TData> - must implement the Void Abstract Method OnExecute (IESIConfigurationRepository esiConfiguration);
- ESIGlobalBase <TData> - must contain methods with the void (IESIConfigurationBusiness esiConfiguration) and void (IESIConfigurationRepository) signatures;
- ESIContollerBase <TData> - must implement the Void OnExecute Abstract Method (IESIConfigurationController esiConfiguration).
- ESIBusinessBase<TData> example:
- DTPInfoData is TData
using MMOJr.ESI.Business.Generic; using MMOJr.ESI.Interface.Generic;
public class BUSInfoInstance : ESIBusinessBase<DTPInfoData>
{
public BUSInfoInstance()
{
}
protected override void OnExecute(IESIConfigurationBusiness<DTPInfoData> esiConfiguration)
{
esiConfiguration.Success = !string.IsNullOrEmpty(esiConfiguration.Data.DTPInfo.Instance);
esiConfiguration.OnFailure = (p) =>
{
esiConfiguration.Data.ListException.Add(new System.Exception("Instancia Inválida."));
};
}
}
- ESIRepositoryBase<TData> example:
- DTPInfoData is TData
using MMOJr.ESI.Interface.Generic; using MMOJr.ESI.Repository.Generic;
public class DBSInfoLoadAssembly : ESIRepositoryBase<DTPInfoData>
{
public DBSInfoLoadAssembly()
{
}
protected override void OnExecute(IESIConfigurationRepository<DTPInfoData> esiConfiguration)
{
esiConfiguration.Data.Assembly = Assembly.LoadFile(esiConfiguration.Data.DTPInfo.PathAssembly);
}
}
- ESIController<TData> example:
- DTPInfoData is TData
using MMOJr.ESI.Controller.Generic; using MMOJr.ESI.Interface.Generic;
public class CTLInfoListMethodModuleAssembly : ESIControllerBase<DTPInfoData>
{
public CTLInfoListMethodModuleAssembly(DTPInfo dtpInfo) : base(DTPInfoFactory.CreateInstanceInfoData(dtpInfo))
{
}
protected override void OnExecute(IESIConfigurationController<DTPInfoData> esiConfiguration)
{
esiConfiguration.LoadScope(instance =>
{
instance.AddBusiness<BUSInfoListExceptionClear>();
instance.AddBusiness<BUSInfoModuleAssembly>();
instance.AddBusiness<BUSInfoPath>();
instance.AddBusiness<BUSInfoNamespace>();
instance.AddBusiness<BUSInfoPathAssembly>();
instance.AddRepository<DBSInfoLoadAssembly>();
instance.AddBusiness<BUSInfoAssemblyExistEndScope>();
instance.AddRepository<DBSInfoMethodListByAssembly>();
instance.AddBusiness<BUSInfoListExceptionEndExecution>();
});
esiConfiguration.LoadScope(instance =>
{
instance.AddBusiness<BUSInfoListExceptionClear>();
instance.AddBusiness<BUSInfoModuleAssembly>();
instance.AddBusiness<BUSInfoNamespace>();
instance.AddBusiness<BUSInfoTypeName>();
instance.AddBusiness<BUSInfoListExceptionThrow>();
instance.AddRepository<DBSInfoLoadType>();
instance.AddBusiness<BUSInfoTypeExist>();
instance.AddBusiness<BUSInfoListExceptionThrow>();
instance.AddRepository<DBSInfoMethodListByType>();
instance.AddBusiness<BUSInfoListExceptionEndExecution>();
});
}
}
Call Controller:
public static IESIReturn<DTPInfoData> ListMethod(DTPInfo dtpInfo) { var esiReturn = default(IESIReturn<DTPInfoData>); using (var ctlInfo = new CTLInfoListMethodModuleAssembly(dtpInfo)) { esiReturn = ctlInfo.Execute(); } return (esiReturn); }
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
.NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- Microsoft.CSharp (>= 4.7.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
9.0.21 | 347 | 1/16/2023 |
9.0.20 | 325 | 1/16/2023 |
8.2.21 | 332 | 12/13/2022 |
8.2.20 | 307 | 12/13/2022 |
8.1.21 | 344 | 11/21/2022 |
8.1.20 | 320 | 11/21/2022 |
7.0.1 | 455 | 5/30/2022 |
6.0.1 | 467 | 3/13/2022 |
6.0.0 | 423 | 3/13/2022 |
5.0.1 | 367 | 8/16/2021 |
5.0.0 | 329 | 8/16/2021 |
4.2.1 | 400 | 5/6/2021 |
4.1.1 | 330 | 5/4/2021 |
3.1.1 | 368 | 4/7/2021 |
2.1.1 | 373 | 4/5/2021 |
1.0.0 | 368 | 3/30/2021 |