daily update on 20240226 by nitload youmu
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using StgSharp.Graphics;
|
||||
|
||||
using System;
|
||||
using System.Collections;
|
||||
|
||||
@@ -24,7 +25,7 @@ namespace StgSharp
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The first memeber of this linkec list.
|
||||
/// The first memeber of this linkec list.
|
||||
/// Set value to this property will reset the first node.
|
||||
/// </summary>
|
||||
public T First
|
||||
@@ -32,14 +33,14 @@ namespace StgSharp
|
||||
get { return _hook._next._value; }
|
||||
/*
|
||||
* This setter is ued to reset the First node,
|
||||
* be careful when use this setter to avoid
|
||||
* be careful when use this setter to avoid
|
||||
* unexpected risk of this List lose all nodes.
|
||||
*/
|
||||
private set { _hook._next = default; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The last memeber of this linkec list.
|
||||
/// The last memeber of this linkec list.
|
||||
/// Set value to this property will reset the first node.
|
||||
/// </summary>
|
||||
public T Tail
|
||||
@@ -47,7 +48,7 @@ namespace StgSharp
|
||||
get { return _hook._previous._value; }
|
||||
/*
|
||||
* This setter is ued to reset the Last node,
|
||||
* be careful when use this setter to avoid
|
||||
* be careful when use this setter to avoid
|
||||
* unexpected risk of this List lose all nodes.
|
||||
*/
|
||||
private set { _hook._previous = default; }
|
||||
@@ -75,7 +76,6 @@ namespace StgSharp
|
||||
node.Previous = _hook.Previous;
|
||||
_hook._previous._next = node;
|
||||
_hook._previous = node;
|
||||
|
||||
}
|
||||
count++;
|
||||
}
|
||||
@@ -177,7 +177,6 @@ namespace StgSharp
|
||||
do
|
||||
{
|
||||
enumerator = enumerator._next;
|
||||
Console.WriteLine(enumerator.Value.ToString());
|
||||
} while (!enumerator.Value.Equals(value)
|
||||
|| enumerator == _hook);
|
||||
|
||||
@@ -188,13 +187,16 @@ namespace StgSharp
|
||||
|
||||
return enumerator;
|
||||
}
|
||||
|
||||
/**/
|
||||
|
||||
internal struct LinkedListEnumrator<T> : IEnumerator
|
||||
{
|
||||
private LinkedList<T> _target;
|
||||
private T _value;
|
||||
LinkedListNode<T> enumerator;
|
||||
private LinkedListNode<T> enumerator;
|
||||
private uint index = 0;
|
||||
|
||||
public LinkedListEnumrator(LinkedList<T> target)
|
||||
{
|
||||
_target = target;
|
||||
@@ -241,6 +243,7 @@ namespace StgSharp
|
||||
enumerator = _target._hook;
|
||||
}
|
||||
}
|
||||
|
||||
/**/
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user