Exemple #1
0
 private static void ImportStatusFromCrab(StreetName streetName, ImportStreetNameStatusFromCrab command)
 {
     streetName.ImportStatusFromCrab(
         command.StreetNameStatusId,
         command.StreetNameId,
         command.StreetNameStatus,
         command.LifeTime,
         command.Timestamp,
         command.Operator,
         command.Modification,
         command.Organisation);
 }
Exemple #2
0
 private static void ImportFromCrab(StreetName streetName, ImportStreetNameFromCrab command)
 {
     streetName.ImportFromCrab(
         command.StreetNameId,
         command.MunicipalityId,
         command.PrimaryStreetName,
         command.SecondaryStreetName,
         command.PrimaryTransStreetName,
         command.SecondaryTransStreetName,
         command.PrimaryLanguage,
         command.SecondaryLanguage,
         command.LifeTime,
         command.Timestamp,
         command.Operator,
         command.Modification,
         command.Organisation);
 }
Exemple #3
0
        private static async Task <Optional <StreetName> > GetOrRegisterStreetName(
            IStreetNames streetNames,
            StreetNameId streetNameId,
            MunicipalityId municipalityId,
            NisCode nisCode,
            CancellationToken ct)
        {
            var streetName = await streetNames.GetOptionalAsync(streetNameId, ct);

            if (streetName.HasValue)
            {
                return(streetName);
            }

            streetName = new Optional <StreetName>(
                StreetName.Register(
                    new StreetNameId(streetNameId),
                    new MunicipalityId(municipalityId),
                    nisCode));

            streetNames.Add(streetNameId, streetName.Value);

            return(streetName);
        }