Monovi.UETDS 1.0.1

Monovi.UETDS is an aplication which includes UETDS services.

Install-Package Monovi.UETDS -Version 1.0.1
dotnet add package Monovi.UETDS --version 1.0.1
<PackageReference Include="Monovi.UETDS" Version="1.0.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Monovi.UETDS --version 1.0.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Monovi.UETDS

MonoviUETDS is a C# class library for dealing with UETDS (Ulaştırma Elektronik Takip ve Denetim Sistemi) services.

Installation

Click the link to download package or
run the following command from Package Manager Console.

Install-Package Monovi.UETDS -Version x.y.z

Usage

Use a DI container to register the application. In this section, used AutoFac DI container for an example.

Register to container

Identification information must be entered for test and live services while registering the application. UETDSHandler's constructor consist of testCredentials and liveCredentials parameters which is UETDSCredentialBase type.

builder.RegisterType<UETDSHandler>()
                .WithParameter("testCredentials", new UETDSServiceCredential
                {
                    Username = ConfigurationManager.AppSettings["uetdsTestUsername"],
                    Password = ConfigurationManager.AppSettings["uetdsTestPassword"]
                })
                .WithParameter("liveCredentials", new UETDSServiceCredential
                {
                    Username = ConfigurationManager.AppSettings["uetdsLiveUsername"],
                    Password = ConfigurationManager.AppSettings["uetdsLivePassword"]
                })
                .Keyed<IUETDSHandler>("keyName");

Resolve

The Application includes a UETDS validator to validate informations before send it to the UETDS service.
You can use this validator. Validation results is inherited from UETDSValidationResultBase type. So this results includes IsValid and ErrorList properties.

IUETDSHandler _keyNameHandler = EngineContext.Current.Resolve<IUETDSHandler>("keyName");
IUETDSValidator _validator = _keyNameHandler.GetValidator();
UETDSValidationResultBase _loadInfoValidationResult = _validator.ValidateLoadInfo(IVerifiable loadInfo);
UETDSValidationResultBase  _vehicleInfoValidationResult = _validator.ValidateVehicleInfo(IVerifiable vehicleInfo);

Notify the information to service

UETDSHandler class provides you test or live clients. You can handle UETDS processes to using this client methods.

IUETDSHandler _keyNameHandler = EngineContext.Current.Resolve<IUETDSHandler>("keyName");
UETDSClientBase _testClient = _keyNameHandler.GetService().GetTestClient();
UETDSCancelTypeResponse _uetdsCancelTypeResponse = _testClient.GetCancelTypes();
UETDSClientBase _liveClient = _keyNameHandler.GetService().GetLiveClient();
UETDSLoadNotificationDetailResponse _uetdsLoadNotificationDetailResponse = _liveClient.GetLoadNotificationDetail(loadNotificationId: 1232133424);

public partial class UETDSVehicleModel : IVerifiable, ISerializableObject
{
    public string Plate1 { get; set; }
    public bool IsPlate1Private { get; set; }
    public string Plate2 { get; set; }
    public bool IsPlate2Private { get; set; }
    public string Driver1IdentityNumber { get; set; }
    public string Driver2IdentityNumber { get; set; }
    public TransportationTypeCode TransportationTypeCode { get; set; }
}

public partial class UETDSLoadInfoModel : IVerifiable, ISerializableObject
{
    public string FirmLoadNumber { get; set; }
    public string SenderTaxNumber { get; set; }
    public string SenderCompanyName { get; set; }
    public string ReceiverTaxNumber { get; set; }
    public string ReceiverCompanyName { get; set; }
    public string LoadingCountryCode { get; set; }
    public int LoadingCityCode { get; set; }
    public int LoadingTownCode { get; set; }
    public string UnloadingCountryCode { get; set; }
    public int UnloadingCityCode { get; set; }
    public int UnloadingTownCode { get; set; }
    public DateTime LoadingDate { get; set; }
    public DateTime LoadingTime { get; set; }
    public DateTime UnloadingDate { get; set; }
    public DateTime UnloadingTime { get; set; }
    public LoadType LoadType { get; set; }
    public LoadUnit LoadUnit { get; set; }
    public string LoadQuantity { get; set; }
    public decimal TransportationCost { get; set; }
    public string UNNumber { get; set; }
    public HazardousMaterialTransportationType? HazardousMaterialTransportationType { get; set; }
    public string OtherDescription { get; set; }
}

UETDSNewLoadNotificationResponse _newLoadNotificationResponse = _liveClient().NotifyNewLoad(uetdsVehicleModel, uetdsLoadInfoModelList);


Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update the package as appropriate.

License

--

Monovi.UETDS

MonoviUETDS is a C# class library for dealing with UETDS (Ulaştırma Elektronik Takip ve Denetim Sistemi) services.

Installation

Click the link to download package or
run the following command from Package Manager Console.

Install-Package Monovi.UETDS -Version x.y.z

Usage

Use a DI container to register the application. In this section, used AutoFac DI container for an example.

Register to container

Identification information must be entered for test and live services while registering the application. UETDSHandler's constructor consist of testCredentials and liveCredentials parameters which is UETDSCredentialBase type.

builder.RegisterType<UETDSHandler>()
                .WithParameter("testCredentials", new UETDSServiceCredential
                {
                    Username = ConfigurationManager.AppSettings["uetdsTestUsername"],
                    Password = ConfigurationManager.AppSettings["uetdsTestPassword"]
                })
                .WithParameter("liveCredentials", new UETDSServiceCredential
                {
                    Username = ConfigurationManager.AppSettings["uetdsLiveUsername"],
                    Password = ConfigurationManager.AppSettings["uetdsLivePassword"]
                })
                .Keyed<IUETDSHandler>("keyName");

Resolve

The Application includes a UETDS validator to validate informations before send it to the UETDS service.
You can use this validator. Validation results is inherited from UETDSValidationResultBase type. So this results includes IsValid and ErrorList properties.

IUETDSHandler _keyNameHandler = EngineContext.Current.Resolve<IUETDSHandler>("keyName");
IUETDSValidator _validator = _keyNameHandler.GetValidator();
UETDSValidationResultBase _loadInfoValidationResult = _validator.ValidateLoadInfo(IVerifiable loadInfo);
UETDSValidationResultBase  _vehicleInfoValidationResult = _validator.ValidateVehicleInfo(IVerifiable vehicleInfo);

Notify the information to service

UETDSHandler class provides you test or live clients. You can handle UETDS processes to using this client methods.

IUETDSHandler _keyNameHandler = EngineContext.Current.Resolve<IUETDSHandler>("keyName");
UETDSClientBase _testClient = _keyNameHandler.GetService().GetTestClient();
UETDSCancelTypeResponse _uetdsCancelTypeResponse = _testClient.GetCancelTypes();
UETDSClientBase _liveClient = _keyNameHandler.GetService().GetLiveClient();
UETDSLoadNotificationDetailResponse _uetdsLoadNotificationDetailResponse = _liveClient.GetLoadNotificationDetail(loadNotificationId: 1232133424);

public partial class UETDSVehicleModel : IVerifiable, ISerializableObject
{
    public string Plate1 { get; set; }
    public bool IsPlate1Private { get; set; }
    public string Plate2 { get; set; }
    public bool IsPlate2Private { get; set; }
    public string Driver1IdentityNumber { get; set; }
    public string Driver2IdentityNumber { get; set; }
    public TransportationTypeCode TransportationTypeCode { get; set; }
}

public partial class UETDSLoadInfoModel : IVerifiable, ISerializableObject
{
    public string FirmLoadNumber { get; set; }
    public string SenderTaxNumber { get; set; }
    public string SenderCompanyName { get; set; }
    public string ReceiverTaxNumber { get; set; }
    public string ReceiverCompanyName { get; set; }
    public string LoadingCountryCode { get; set; }
    public int LoadingCityCode { get; set; }
    public int LoadingTownCode { get; set; }
    public string UnloadingCountryCode { get; set; }
    public int UnloadingCityCode { get; set; }
    public int UnloadingTownCode { get; set; }
    public DateTime LoadingDate { get; set; }
    public DateTime LoadingTime { get; set; }
    public DateTime UnloadingDate { get; set; }
    public DateTime UnloadingTime { get; set; }
    public LoadType LoadType { get; set; }
    public LoadUnit LoadUnit { get; set; }
    public string LoadQuantity { get; set; }
    public decimal TransportationCost { get; set; }
    public string UNNumber { get; set; }
    public HazardousMaterialTransportationType? HazardousMaterialTransportationType { get; set; }
    public string OtherDescription { get; set; }
}

UETDSNewLoadNotificationResponse _newLoadNotificationResponse = _liveClient().NotifyNewLoad(uetdsVehicleModel, uetdsLoadInfoModelList);


Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update the package as appropriate.

License

--

Release Notes

Add README.md file.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version History

Version Downloads Last updated
1.0.1 137 6/24/2020
1.0.0 77 6/24/2020