gpt4 book ai didi

de.alpharogroup.address.book.service.api.ZipcodesService类的使用及代码示例

转载 作者:知者 更新时间:2024-03-13 10:33:57 27 4
gpt4 key购买 nike

本文整理了Java中de.alpharogroup.address.book.service.api.ZipcodesService类的一些代码示例,展示了ZipcodesService类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZipcodesService类的具体详情如下:
包路径:de.alpharogroup.address.book.service.api.ZipcodesService
类名称:ZipcodesService

ZipcodesService介绍

[英]The interface ZipcodesService.
[中]接口ZipCodes服务。

代码示例

代码示例来源:origin: de.alpharogroup/address-book-business

/**
 * {@inheritDoc}
 */
@Override
@Deprecated
public Map<Countries, List<Zipcodes>> getCountriesToZipcodesMap()
{
  if (this.countriesToZipcodesMap == null)
  {
    this.countriesToZipcodesMap = new LinkedHashMap<Countries, List<Zipcodes>>();
    List<Countries> countries = findAll();
    Collections.sort(countries, new Comparator<Countries>()
    {
      @Override
      public int compare(Countries o1, Countries o2)
      {
        return o1.getName().compareTo(o2.getName());
      }
    });
    for (Countries country : countries)
    {
      List<Zipcodes> zipcodes = zipcodesService.find(country);
      this.countriesToZipcodesMap.put(country, zipcodes);
    }
  }
  return this.countriesToZipcodesMap;
}

代码示例来源:origin: de.alpharogroup/address-book-domain

/**
 * {@inheritDoc}
 */
@Override
public Zipcode getZipcode(String zipcode, String city)
{
  return getMapper().toDomainObject(zipcodesService.getZipcode(zipcode, city));
}

代码示例来源:origin: de.alpharogroup/address-book-domain

/**
 * {@inheritDoc}
 */
@Override
public void deleteAllZipcodes()
{
  zipcodesService.deleteAllZipcodes();
}

代码示例来源:origin: de.alpharogroup/address-book-domain

/**
 * {@inheritDoc}
 */
@Override
public Zipcode findCityFromZipcode(Country country, String zipcode)
{
  return getMapper().toDomainObject(zipcodesService
    .findCityFromZipcode(getMapper().map(country, Countries.class), zipcode));
}

代码示例来源:origin: de.alpharogroup/address-book-domain

/**
 * {@inheritDoc}
 */
@Override
public boolean existsZipcode(String zipcode)
{
  return zipcodesService.existsZipcode(zipcode);
}

代码示例来源:origin: de.alpharogroup/address-book-domain

/**
 * {@inheritDoc}
 */
@Override
public List<Zipcode> findZipcodes(String zipcode)
{
  return getMapper().toDomainObjects(zipcodesService.findZipcodes(zipcode));
}

代码示例来源:origin: de.alpharogroup/address-book-domain

/**
 * {@inheritDoc}
 */
@Override
public List<Zipcode> findAll(Country country, String zipcode, String city)
{
  Countries c = getMapper().map(country, Countries.class);
  return getMapper().toDomainObjects(zipcodesService.findAll(c, zipcode, city));
}

代码示例来源:origin: de.alpharogroup/address-book-business

Zipcodes zipcode = getZipcodesService().findCityFromZipcode(country, zc);
if (zipcode != null)

代码示例来源:origin: de.alpharogroup/address-book-business

for (Countries country : countries)
  List<Zipcodes> zipcodes = zipcodesService.find(country);
  this.germanCountriesToZipcodesMap.put(country, zipcodes);

代码示例来源:origin: de.alpharogroup/address-book-business

Zipcodes zipcode = getZipcodesService().findCityFromZipcode(country,
  modelObject.getZipcode());
if (zipcode != null)

代码示例来源:origin: de.alpharogroup/address-book-business

/**
 * {@inheritDoc}
 */
@Override
public Addresses createAddress(final String street, final String streetnumber,
  final String addressComment, final String zipcode, final String city,
  final String federalstate)
{
  final Zipcodes zc = zipcodesService.getZipcode(zipcode, city);
  Federalstates federalstates;
  if (zc != null && zc.getCountry() != null)
  {
    federalstates = federalstatesService.findFederalstate(zc.getCountry(), federalstate);
  }
  else
  {
    federalstates = federalstatesService.findFederalstateFromIso3166A2code(federalstate);
  }
  final Addresses address = AddressBookFactory.getInstance().newAddresses(addressComment,
    federalstates, null, null, null, street, streetnumber, zc);
  return address;
}

代码示例来源:origin: de.alpharogroup/address-book-domain

/**
 * {@inheritDoc}
 */
@Override
public List<Zipcode> find(Country country)
{
  List<Zipcode> zcs = new ArrayList<>();
  if (country != null)
  {
    Countries countries = getMapper().map(country, Countries.class);
    return getMapper().toDomainObjects(zipcodesService.find(countries));
  }
  return zcs;
}

代码示例来源:origin: de.alpharogroup/address-book-business

/**
 * {@inheritDoc}
 */
@Override
public Addresses createAddress(final String street, final String streetnumber,
  final String addressComment, final String zipcode, final String city,
  final String federalstate, final String geohash, final java.math.BigDecimal latitude,
  final java.math.BigDecimal longitude)
{
  final Zipcodes zip = zipcodesService.getZipcode(zipcode, city);
  Federalstates federalstates;
  if (zip != null && zip.getCountry() != null)
  {
    federalstates = federalstatesService.findFederalstate(zip.getCountry(), federalstate);
  }
  else
  {
    federalstates = federalstatesService.findFederalstateFromIso3166A2code(federalstate);
  }
  final Addresses address = AddressBookFactory.getInstance().newAddresses(addressComment,
    federalstates, geohash, latitude, longitude, street, streetnumber, zip);
  return address;
}

代码示例来源:origin: de.alpharogroup/address-book-business

/**
 * {@inheritDoc}
 */
@Override
public List<KeyValuesPair<Countries, Zipcodes>> getCountriesToZipcodesList()
{
  if (this.countriesToZipcodesList == null)
  {
    this.countriesToZipcodesList = new ArrayList<>();
    List<Countries> countries = findAll();
    Collections.sort(countries, new Comparator<Countries>()
    {
      @Override
      public int compare(Countries o1, Countries o2)
      {
        return o1.getName().compareTo(o2.getName());
      }
    });
    for (Countries country : countries)
    {
      List<Zipcodes> zipcodes = zipcodesService.find(country);
      this.countriesToZipcodesList.add(KeyValuesPair.<Countries, Zipcodes> builder()
        .key(country).values(zipcodes).build());
    }
  }
  return this.countriesToZipcodesList;
}

代码示例来源:origin: de.alpharogroup/address-book-business

for (Countries country : countries)
  List<Zipcodes> zipcodes = zipcodesService.find(country);
  this.germanCountriesToZipcodesList.add(KeyValuesPair.<Countries, Zipcodes> builder()
    .key(country).values(zipcodes).build());

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com