#creating an object based on a variable number of params

3 messages · Page 1 of 1 (latest)

hexed creek
#

Hi all,

I have a java class called FixtureEntry. It has 7 fields, one is mandatory and the rest are (in theory) optional. I've attached a picture and in the console you can see entries such as: 24-Mar-2023;Mixed A; Roussel B;. I want to programmatically create instances of FixtureEntry depending on the number of arguments (as a String like printed in the console) I pass to it. The order of the printed messages is always the same i.e. it always starts with a date followed by a team name etc. I'm not sure how to approach this.

Look forward to a response,
johnny

p.s. if you need more info or explanation i'm happy to help

leaden spearBOT
#

This post has been reserved for your question.

Hey @hexed creek! Please use /close or the Close Post button above when you're finished. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.

TIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here.