first this line genrates an array of string lists:
private List FileList;
and a list does not need a size, its optional.
maybe you wanted to write:
private List<string> FileList = new List<string>();
private bool invalidate = true;
public void Evaluate(int SpreadMax)
{
if (this.invalidate)
{
FileList.Clear();
}
}
or as array of string lists:
private List<string>[]() FileList;
private bool invalidate = true;
public void Evaluate(int SpreadMax)
{
if (this.invalidate)
{
FileList = new List<string>[FInput.SliceCount](FInput.SliceCount);
}
}
but it might be more easy to manage as a list of lists:
private List<List<string>> FileList = new List<List<string>>();
private bool invalidate = true;
public void Evaluate(int SpreadMax)
{
if (this.invalidate)
{
FileList.Clear();
//add the sub lists somehow
FileList.Add(new List<string>());
...
}
}
a list also handles an array internally but i find it is more convenient to use and the performance is about the same, even faster in cases because the list code does intelligent memory handling of the internal array…