How to get private fields from another class?
<p>I have a class called date:</p>

<pre><code>public class Date{
    private String monthAndDate;
    public Date(String inputMonthAndDate){
        monthAndDate = inputMonthAndDate;
    }
}
</code></pre>

<p>I have another class called Patient. Is it possible to get the syntax of monthAndDate from class Date and pass it to a private field in the class Patient? </p>

<p>Thank you.</p>
