cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From krishna behara <>
Subject validating string input
Date Wed, 01 Jul 2009 08:50:23 GMT

i need to validate String attributes before or as they are unmarshalled and set on the final
that they are part of.
for instance consider the following class, i would like to do some input validation on "name"
before setName is called and the value is set, and do the same thing for Integer. With JAXWS
with Aegis databinding i was able to accomplish this by creating a new AegisContext and inserting
a new type mapping for a string. I am trying to do achieve the same thing but with JAXRS (which
is using JAXB).

thanks for any help on this.

public class Person {
    String name;
    String language;
    Integer age;

    public Integer getAge() {
        return age;

    public void setAge(Integer age) {
         this.age = age;
    public String getName() {
        return name;
    public void setName(String name) { = name;
    public String getLanguage() {
        return language;
    public void setLanguage(String language) {
        this.language = language;

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message