public virtual ApiWorkerResponseModel MapBOToModel(
            BOWorker boWorker)
        {
            var model = new ApiWorkerResponseModel();

            model.SetProperties(boWorker.Id, boWorker.CommunicationStyle, boWorker.Fingerprint, boWorker.IsDisabled, boWorker.JSON, boWorker.MachinePolicyId, boWorker.Name, boWorker.RelatedDocumentIds, boWorker.Thumbprint, boWorker.WorkerPoolIds);

            return(model);
        }
Exemple #2
0
        public virtual BOWorker MapEFToBO(
            Worker ef)
        {
            var bo = new BOWorker();

            bo.SetProperties(
                ef.Id,
                ef.CommunicationStyle,
                ef.Fingerprint,
                ef.IsDisabled,
                ef.JSON,
                ef.MachinePolicyId,
                ef.Name,
                ef.RelatedDocumentIds,
                ef.Thumbprint,
                ef.WorkerPoolIds);
            return(bo);
        }
Exemple #3
0
        public virtual Worker MapBOToEF(
            BOWorker bo)
        {
            Worker efWorker = new Worker();

            efWorker.SetProperties(
                bo.CommunicationStyle,
                bo.Fingerprint,
                bo.Id,
                bo.IsDisabled,
                bo.JSON,
                bo.MachinePolicyId,
                bo.Name,
                bo.RelatedDocumentIds,
                bo.Thumbprint,
                bo.WorkerPoolIds);
            return(efWorker);
        }
        public virtual BOWorker MapModelToBO(
            string id,
            ApiWorkerRequestModel model
            )
        {
            BOWorker boWorker = new BOWorker();

            boWorker.SetProperties(
                id,
                model.CommunicationStyle,
                model.Fingerprint,
                model.IsDisabled,
                model.JSON,
                model.MachinePolicyId,
                model.Name,
                model.RelatedDocumentIds,
                model.Thumbprint,
                model.WorkerPoolIds);
            return(boWorker);
        }