public Insert ( int index, |
||
index | int | |
value | ||
리턴 | void |
public void Constructor0_Deny_Unrestricted () { CodeParameterDeclarationExpressionCollection coll = new CodeParameterDeclarationExpressionCollection (); Assert.AreEqual (0, coll.Add (cpde), "Add"); Assert.AreSame (cpde, coll[0], "this[int]"); coll.CopyTo (array, 0); coll.AddRange (array); coll.AddRange (coll); Assert.IsTrue (coll.Contains (cpde), "Contains"); Assert.AreEqual (0, coll.IndexOf (cpde), "IndexOf"); coll.Insert (0, cpde); coll.Remove (cpde); }
public void Insert_Null () { CodeParameterDeclarationExpressionCollection coll = new CodeParameterDeclarationExpressionCollection (); coll.Insert (0, (CodeParameterDeclarationExpression) null); }
public void Insert () { CodeParameterDeclarationExpression param1 = new CodeParameterDeclarationExpression (); CodeParameterDeclarationExpression param2 = new CodeParameterDeclarationExpression (); CodeParameterDeclarationExpressionCollection coll = new CodeParameterDeclarationExpressionCollection (); coll.Add (param1); Assert.AreEqual (1, coll.Count, "#1"); Assert.AreEqual (0, coll.IndexOf (param1), "#2"); coll.Insert (0, param2); Assert.AreEqual (2, coll.Count, "#3"); Assert.AreEqual (1, coll.IndexOf (param1), "#4"); Assert.AreEqual (0, coll.IndexOf (param2), "#5"); }