如何将以下列表转换为 LINQ?其中 QueueDataSource 是 ArrayList。
switch (queue.QueueTypeID)
{
case (int)QueryType.DataEntry:
dataEntryQueue.QueueDataSource.Add(new
{
QueueID = queue.QueueID,
LinkText = queueName,
Uid = sentinel
});
break;
case (int)QueryType.Sort:
sortingQueue.QueueDataSource.Add(new
{
QueueID = queue.QueueID,
LinkText = queueName,
Uid = sentinel
});
break;
case (int)QueryType.CaseList:
myQueue.QueueDataSource.Add(new
{
QueueID = queue.QueueID,
LinkText = queueName,
Uid = sentinel
});
break;
}