Package org.jmule.countrylocator

Examples of org.jmule.countrylocator.CountryLocator


    return getFlagAsIcon(country_code, flagSize);
  }
 
  public static URL getFlagAsURLByIP(Object inetAddress, FlagSize flagSize) {
    if( !CountryLocator.getInstance().isServiceDown() ) {
      CountryLocator country_locator = CountryLocator.getInstance();
      return   getFlagAsURL(country_locator.getCountryCode(inetAddress), flagSize);
    }
        return null
  }
View Full Code Here


    GridLayout server_info_layout = new GridLayout(2,false);
    server_info_layout.marginWidth = 0;
    server_info_layout.marginHeight = 0;
    server_info.setLayout(server_info_layout);
 
    CountryLocator country_locator = CountryLocator.getInstance();
    if (!country_locator.isServiceDown()) {
      label = new Label(server_info,SWT.NONE);
      Image flag = SWTImageRepository.getFlagByAddress(server.getAddress(),FlagSize.S18x25);
      label.setImage(flag);
      String country_name = country_locator.getCountryName(server.getAddress());
      String country_code = country_locator.getCountryCode(server.getAddress());
     
      if (country_name.equals(CountryLocator.COUNTRY_NAME_NOT_AVAILABLE))
        country_name = Localizer._("serverpropertieswindow.label.country.unknown_name");
      if (country_code.equals(CountryLocator.COUNTRY_CODE_NOT_AVAILABLE))
        country_code = Localizer._("serverpropertieswindow.label.country.unknown_code");
View Full Code Here

TOP

Related Classes of org.jmule.countrylocator.CountryLocator

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.