I have the following structure in user.java
public class User(){
string fname;
string lname;
string email;
public User(){
this.fname = randomCharGenMethod();
this.lname = randomCharGenMethod();
this.email = randomCharGenMethod();
}
}
in another java class, I've created following objects.
static User user1 = new User();
static User user2 = new User();
when I'm going forward with the objects created, they both have same fname
, lname
, and email
.
Actually, I want them to have unique fname
,lname
and email
as they were generated from a string generating method