countryservice.java

来自「随书光盘:精通Sping 2.0 的随书源代码」· Java 代码 · 共 39 行

JAVA
39
字号
package org.springframework.samples.countries;

import java.util.List;
import java.util.Locale;

/**
 * @author Jean-Pierre Pawlak
 * @author Juergen Hoeller
 */
public interface CountryService {

	/**
	 * Provides the list of all ICountries in the given Locale.
	 * @param locale The Locale for which the records are intended
	 * @return The list of all countries in the given Locale
	 */
	List getAllCountries(Locale locale);

	/**
	 * Provides a list of ICountries in the given Locale with name and code
	 * starting with the corresponding parameters. A null or empty String 
	 * in the parameter is interpreted as no filtering on that parameter.
	 * @param name beginning of the name of the requested records
	 * @param code beginning of the code of the requested records
	 * @param locale the Locale for which the records are intended
	 * @return the list of Country objects matching with parameters in the given Locale
	 */
	List getFilteredCountries(String name, String code, Locale locale);

	/**
	 * Get a Country object following the parameters.
	 * @param code the code of the requested country
	 * @param locale the locale to use for searching the country
	 * @return the Country object corresponding on the parameters
	 */
	Country getCountry(String code, Locale locale);

}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?