public void Populate(IRestRequest request)
        {
            var addressPopulator = new AddressPopulator(_address);
            addressPopulator.Populate(request);
            if (_addressInfo.Description != null) request.AddParameter("description", _addressInfo.Description);
            if (_addressInfo.MetaData != null)
            {
                var populator = new MetaDataPopulator(_addressInfo.MetaData);
                populator.Populate(request);
            }

            if (_addressInfo.Name != null) request.AddParameter("name", _addressInfo.Name);
            if (_addressInfo.Phone != null) request.AddParameter("phone", _addressInfo.Phone);
            if (_addressInfo.Email != null) request.AddParameter("email", _addressInfo.Email);
            if (_addressInfo.Company != null) request.AddParameter("company", _addressInfo.Company);
        }
        public void Populate(IRestRequest request)
        {
            var toPopulator = new TargetAddressPopulator(_letterDefinition.ToAddress, "to");
            var fromPopulator = new TargetAddressPopulator(_letterDefinition.FromAddress, "from");
            var filePopulator = new LobImageFilePopulator(_letterDefinition.File, "file");
            var dataPopulator = new DataPopulator(_letterDefinition.Data);
            var metadataPopulator = new MetaDataPopulator(_letterDefinition.MetaData);

            toPopulator.Populate(request);
            fromPopulator.Populate(request);
            filePopulator.Populate(request);
            dataPopulator.Populate(request);
            metadataPopulator.Populate(request);

            request.AddParameter("color", _letterDefinition.Color);
            request.AddParameter("description", _letterDefinition.Description);
            request.AddParameter("double_sided", _letterDefinition.DoubleSided);

            PopulateReturnEnvelope(request);
            PopulateAddressPlacement(request);
            PopulateExtraService(request);
        }