How to check null condition for the boolean variable
<p>I have a class as shown </p>

<pre><code>package com;

public class Person {
boolean registered;

public boolean isRegistered() {
    return registered;
}

public void setRegistered(boolean registered) {
    this.registered = registered;
}
}
</code></pre>

<p>The Data to Person Object will be set based on the Data present in DB . 
The problem is that for older records the registered filed is not present . </p>

<p>so i how can i test if the filed is present or not ??</p>

<p>package com;</p>

<pre><code>public class Test {

    public static void main(String args[]) {
        Person per = new Person();

        if (per.isRegistered()) {

        }
    }

}
</code></pre>

<p>How can i check if the per.isRegistered() field is present or not for that Person Object  ??</p>
