If I have something like the code below as a constructor, is there a simple, shorthand way to do all the instance variable initializations in one line if all their names are the same as the parameter names?
private Quiz(int id, String name, int creatorId, Date timeCreated,
int categoryId, boolean randomOrder, boolean multiPage,
boolean immediateCorrection, boolean allowPractice) {
this.id = id;
this.name = name;
this.creatorId = creatorId;
this.timeCreated = timeCreated;
this.categoryId = categoryId;
this.randomOrder = randomOrder;
this.multiPage = multiPage;
this.immediateCorrection = immediateCorrection;
this.allowPractice = allowPractice;
}