Perhaps I'm glossing over things.. correct me if I am:
If I look at this:
public void Print<L, E, I V>(VehicleFactory<L, E, I, V> factory)
where L : VehicleAssemblyLine<E, I, V>
where E : Engineer
where I : VehicleAssemblyLineInstructions
where V : Vehicle
{
Console.WriteLine($"Welcome to {factory.FactoryName}");
}
This looks like you want to host a variety of L, E, I and V instances. But the thing that really varies is the kind of Sedan.
If you abstract the thing that's similar yet varies, you'll end up with a less elaborate type signature and the class could look roughly like this:
public Factory<ISedan>
{
public AssemblyLine<ISedan> assemblyLine;
// the lead comes with the team
public EngineeringTeam<ISedan> engineers;
public ISedan Create(Instruction<ISedan> instruction)
{ /* ... */ }
}
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Perhaps I'm glossing over things.. correct me if I am:
If I look at this:
This looks like you want to host a variety of L, E, I and V instances. But the thing that really varies is the kind of Sedan.
If you abstract the thing that's similar yet varies, you'll end up with a less elaborate type signature and the class could look roughly like this: