Table of Contents

Method Replace

Namespace
Gamelogic.Words
Assembly
Gamelogic.Words.dll

Replace(string, string)

Returns a new string in which all occurrences of a specified letter in this instance are replaced with another specified letter.

public Word Replace(string oldLetter, string newLetter)

Parameters

oldLetter string

The letter to be replaced.

newLetter string

The Unicode letter to replace all occurrences of oldLetter.

Returns

Word

Replace(Word, Word)

Returns a new string in which all occurrences of a specified word in the current instance are replaced with another specified word.

public Word Replace(Word oldWord, Word newWord)

Parameters

oldWord Word

The word to be replaced.

newWord Word

The Unicode letter to replace all occurrences of oldWord.

Returns

Word

A word that is equivalent to the current word except that all instances of oldWord are replaced with newWord. If oldValue is not found in the current instance, the method returns the current instance unchanged.