List of usage examples for org.springframework.util Assert hasText
@Deprecated public static void hasText(@Nullable String text)
From source file:com.streamreduce.core.dao.UserDAO.java
public User findUser(String username) { Assert.hasText(username); return ds.createQuery(entityClazz).field("username") .equal(Pattern.compile("^\\Q" + username + "\\E$", Pattern.CASE_INSENSITIVE)).get(); }
From source file:com.chevrier.legiondao.entities.Customer.java
/** * Creates a new {@link Customer} from the given firstname and lastname. * // w w w. j a v a 2 s . co m * @param firstname must not be {@literal null} or empty. * @param lastname must not be {@literal null} or empty. */ public Customer(String firstname, String lastname) { Assert.hasText(firstname); Assert.hasText(lastname); this.firstname = firstname; this.lastname = lastname; }
From source file:se.vgregion.mobile.types.Printer.java
public Printer(String name, String help, String information, Set<PrinterQueue> queues) { Assert.hasText(name); Assert.hasText(help);/*w ww.j ava2 s . c om*/ Assert.hasText(information); this.id = UUID.randomUUID(); this.name = name; this.help = help; this.information = information; this.queues = queues; }
From source file:se.vgregion.urlservice.types.Owner.java
public Owner(String name) { Assert.hasText(name); this.id = UUID.randomUUID(); this.name = name; }
From source file:gemfire.practice.domain.Customer.java
/** * Creates a new {@link Customer} from the given parameters. * // w ww.j ava2 s.c o m * @param id the unique id; * @param emailAddress must not be {@literal null} or empty. * @param firstname must not be {@literal null} or empty. * @param lastname must not be {@literal null} or empty. */ Customer(Long id, EmailAddress emailAddress, String firstname, String lastname) { super(id); Assert.hasText(firstname); Assert.hasText(lastname); Assert.notNull(emailAddress); this.firstname = firstname; this.lastname = lastname; this.emailAddress = emailAddress; }
From source file:com.jatin.auto.imdg.domain.Customer.java
/** * Creates a new {@link Customer} from the given parameters. * @param id the unique id;/*from w w w .ja v a 2 s . co m*/ * @param emailAddress must not be {@literal null} or empty. * @param firstname must not be {@literal null} or empty. * @param lastname must not be {@literal null} or empty. */ public Customer(Long id, EmailAddress emailAddress, String firstname, String lastname) { super(id); Assert.hasText(firstname); Assert.hasText(lastname); Assert.notNull(emailAddress); this.firstname = firstname; this.lastname = lastname; this.emailAddress = emailAddress; }
From source file:com.jatin.auto.imdg.domain.Customer2.java
/** * Creates a new {@link Customer2} from the given parameters. * @param id the unique id;/*from www . java 2s. co m*/ * @param emailAddress must not be {@literal null} or empty. * @param firstname must not be {@literal null} or empty. * @param lastname must not be {@literal null} or empty. */ public Customer2(Long id, EmailAddress emailAddress, String firstname, String lastname) { super(id); Assert.hasText(firstname); Assert.hasText(lastname); Assert.notNull(emailAddress); this.firstname = firstname; this.lastname = lastname; this.emailAddress = emailAddress; }
From source file:com.hongqiang.shop.common.utils.FreeMarkers.java
@SuppressWarnings("unchecked") public static <T> T getParameter(String name, Class<T> type, Map<String, TemplateModel> params) throws TemplateModelException { Assert.hasText(name); Assert.notNull(type);/*from w ww.j a v a 2 s. c o m*/ Assert.notNull(params); TemplateModel localTemplateModel = (TemplateModel) params.get(name); if (localTemplateModel == null) return null; Object localObject = DeepUnwrap.unwrap(localTemplateModel); return (T) convertUtilsBean.convert(localObject, type); }
From source file:com.ellin.gf8.demo.model.Customer.java
/** * Creates a new {@link com.ellin.gf8.demo.model.Customer} from the given parameters. * @param id the unique id;//from ww w.j ava 2 s.com * @param emailAddress must not be {@literal null} or empty. * @param firstname must not be {@literal null} or empty. * @param lastname must not be {@literal null} or empty. */ public Customer(Long id, EmailAddress emailAddress, String firstname, String lastname) { Assert.hasText(firstname); Assert.hasText(lastname); Assert.notNull(emailAddress); this.firstname = firstname; this.lastname = lastname; this.emailAddress = emailAddress; this.id = id; }
From source file:com.miko.demo.birt.model.NCar.java
public NCar(String make, String model, String year) { Assert.hasText(make); Assert.hasText(model);/*w w w.j a v a 2s . co m*/ Assert.hasText(year); this.make = make; this.model = model; this.year = year; }