this thread is similar to the other thread i posted - its not a duplicate
i wanted to start this new one as a fresh one and not to make things complicated.
so here it goes
i have made objects, found an object and wish to assign the found object (mentee) to an existing "experienced" object (mentor)
i have made a method in the Mentor Class to addMentee(Programmer aMentee)
it also has an arraylist (the Mentor class has it)
what i wanna know is how exactly do I attach a Mentor to a Mentee from the Main class where all the checking is happening (like age check, prog lang check etc...)
and also how would I make a constructor for the Mentor class if we are dealing with object passing (not object creation)
Mentor.java:37: cannot resolve symbol
symbol : class Mentee
location: class Mentor
public Mentor(Mentee mentee)
^
Mentor.java:114: cannot resolve symbol
symbol : class Mentee
location: class Mentor
private Mentee mentee;
^
Mentor.java:38: cannot resolve symbol
symbol : constructor Programmer ()
location: class Programmer
{
^
3 errors
code for Mentor:
Code:
public Mentor(Mentee mentee)
{
this.mentee = mentee;
theMentorings = new ArrayList();
} // method: Mentor
//atribs
private Mentee mentee;
[edit]changed to Mentor mentee and works but then complains about the Programmer class :-/
Code:
Mentor.java:38: cannot resolve symbol
symbol : constructor Programmer ()
location: class Programmer
{
^
1 error