Contains

IMathElementCollection.Contains méthode

Détermine si la collection contient une valeur spécifique.

public bool Contains(IMathElement item)
ParamètreTypeDescription
itemIMathElementL’objet à localiser dans la collection.

Valeur de retour

true si item est trouvé dans la collection ; sinon, false.

Exemples

Exemple:

[C#]
IMathElementCollection collection = new MathBlock(new MathematicalText("x"));
MathematicalText plusElement = new MathematicalText("+");
collection.Add(plusElement);
collection.Add(new MathRadical(new MathematicalText("x"), new MathematicalText("3")));
bool contains = collection.Contains(plusElement);

Voir aussi