Skip to content

Commit

Permalink
Merge pull request #4136 from Evangelink/CA2269-codefix
Browse files Browse the repository at this point in the history
CA2249: Rename code fix title
  • Loading branch information
mavasani authored Sep 7, 2020
2 parents 694d2ac + d1da13d commit 08d6c27
Show file tree
Hide file tree
Showing 15 changed files with 70 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1479,4 +1479,7 @@
<data name="PlatformCompatibilityCheckSupportedOsMessage" xml:space="preserve">
<value>'{0}' is supported on '{1}'</value>
</data>
<data name="PreferStringContainsOverIndexOfCodeFixTitle" xml:space="preserve">
<value>Replace with 'string.Contains'</value>
</data>
</root>
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@ public sealed override async Task RegisterCodeFixesAsync(CodeFixContext context)

context.RegisterCodeFix(
CodeAction.Create(
title: MicrosoftNetCoreAnalyzersResources.PreferStringContainsOverIndexOfTitle,
title: MicrosoftNetCoreAnalyzersResources.PreferStringContainsOverIndexOfCodeFixTitle,
createChangedDocument: c => ReplaceBinaryOperationWithContains(doc, instanceOperation.Syntax, invocationOperation.Arguments, binaryOperation, c),
equivalenceKey: MicrosoftNetCoreAnalyzersResources.PreferStringContainsOverIndexOfTitle),
equivalenceKey: MicrosoftNetCoreAnalyzersResources.PreferStringContainsOverIndexOfCodeFixTitle),
context.Diagnostics);
return;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">Pro ReadAsync a WriteAsync upřednostňovat přetížení založená na Memory</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">Volání metody string.IndexOf, kde se pomocí výsledku kontroluje přítomnost nebo nepřítomnost podřetězce, se dá nahradit metodou string.Contains.</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">Für "ReadAsync" und "WriteAsync" auf "Memory" basierende Überladungen bevorzugen</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">string.IndexOf-Aufrufe zur Überprüfung des Ergebnisses auf das Vorhandensein/Fehlen einer Teilzeichenfolge können durch "string.Contains" ersetzt werden.</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">Elija preferentemente las sobrecargas basadas en "Memory" para "ReadAsync" y "WriteAsync".</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">Las llamadas a "string.IndexOf" donde el resultado se usa para comprobar la presencia o ausencia de una subcadena pueden reemplazarse por "string.Contains".</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">Préférer les surcharges basées sur 'Memory' pour 'ReadAsync' et 'WriteAsync'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">Les appels à 'string.IndexOf' où le résultat est utilisé pour vérifier la présence/l'absence d'une sous-chaîne peuvent être remplacés par 'string.Contains'</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">Preferire gli overload basati su 'Memory' per 'ReadAsync' e 'WriteAsync'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">Le chiamate a 'string.IndexOf' in cui il risultato viene usato per verificare la presenza/assenza di una sottostringa possono essere sostituite da 'string.Contains'</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">'ReadAsync' および 'WriteAsync' で 'Memory' ベースのオーバーロードを優先的に使用する</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">部分文字列が存在するかどうかを確認するために結果を使用する 'string.IndexOf' の呼び出しは、'string.Contains' で置き換えることができます</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">'ReadAsync' 및 'WriteAsync'에 '메모리' 기반 오버로드 사용</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">결과가 하위 문자열의 존재 여부를 확인하는 데 사용되는 'string.IndexOf' 호출은 'string.Contains'로 바꿀 수 있습니다.</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1588,6 +1588,11 @@
<target state="translated">Preferuj „przeciążanie oparte na elemencie „Memory” dla elementów „ReadAsync” i „WriteAsync”</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">Wywołania elementu „string.IndexOf”, w przypadku których wynik jest używany do sprawdzania obecności/nieobecności podciągu, mogą zostać zastąpione przez wyrażenie „string.Contains”</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">Prefira as sobrecargas baseadas em 'Memória' para 'ReadAsync' e 'WriteAsync'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">As chamadas para 'string.IndexOf' nas quais o resultado é usado para verificar a presença ou a ausência de uma substring podem ser substituídas por 'string.Contains'</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">Старайтесь использовать перегрузки на основе памяти для "ReadAsync" и "WriteAsync"</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">Вызовы "string.IndexOf", в которых результат используется для проверки наличия или отсутствия подстроки, можно заменить на "string.Contains"</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">'ReadAsync' ve 'WriteAsync' için 'Memory' tabanlı aşırı yüklemeleri tercih et</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">Sonucu, bir alt dizenin varlığını/yokluğunu denetlemek için kullanılan 'string.IndexOf' çağrıları 'string.Contains' ile değiştirilebilir</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">对于 "ReadAsync" 和 "WriteAsync",首选基于内存的重载</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">如果结果用于检查是否存在/缺少子字符串,对 "string.IndexOf" 的调用可替换为对 "string.Contains" 的调用</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@
<target state="translated">建議針對 'ReadAsync' 和 'WriteAsync' 使用採用 'Memory' 的多載</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfCodeFixTitle">
<source>Replace with 'string.Contains'</source>
<target state="new">Replace with 'string.Contains'</target>
<note />
</trans-unit>
<trans-unit id="PreferStringContainsOverIndexOfDescription">
<source>Calls to 'string.IndexOf' where the result is used to check for the presence/absence of a substring can be replaced by 'string.Contains'.</source>
<target state="needs-review-translation">呼叫 'String.IndexOf' 的結果,將用於確認有無子字串可由 'String.Contains' 取代</target>
Expand Down

0 comments on commit 08d6c27

Please sign in to comment.