{"action":"created","issue":{"url":"https://api.github.com/repos/mygreen/super-csv-annotation/issues/34","repository_url":"https://api.github.com/repos/mygreen/super-csv-annotation","labels_url":"https://api.github.com/repos/mygreen/super-csv-annotation/issues/34/labels{/name}","comments_url":"https://api.github.com/repos/mygreen/super-csv-annotation/issues/34/comments","events_url":"https://api.github.com/repos/mygreen/super-csv-annotation/issues/34/events","html_url":"https://github.com/mygreen/super-csv-annotation/issues/34","id":330948723,"node_id":"MDU6SXNzdWUzMzA5NDg3MjM=","number":34,"title":"CsvRegexReplaceを使用した部分一致の置換が行えない","user":{"login":"shikazuki","id":19152176,"node_id":"MDQ6VXNlcjE5MTUyMTc2","avatar_url":"https://avatars2.githubusercontent.com/u/19152176?v=4","gravatar_id":"","url":"https://api.github.com/users/shikazuki","html_url":"https://github.com/shikazuki","followers_url":"https://api.github.com/users/shikazuki/followers","following_url":"https://api.github.com/users/shikazuki/following{/other_user}","gists_url":"https://api.github.com/users/shikazuki/gists{/gist_id}","starred_url":"https://api.github.com/users/shikazuki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shikazuki/subscriptions","organizations_url":"https://api.github.com/users/shikazuki/orgs","repos_url":"https://api.github.com/users/shikazuki/repos","events_url":"https://api.github.com/users/shikazuki/events{/privacy}","received_events_url":"https://api.github.com/users/shikazuki/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-06-10T07:53:24Z","updated_at":"2018-07-08T04:39:18Z","closed_at":null,"author_association":"NONE","body":"## 概要\r\nCsvRegexReplaceのアノテーションを使用して正規表現に該当する任意の文字列を複数置換することができません。\r\n\r\n## 修正案\r\nhttps://github.com/mygreen/super-csv-annotation/blob/026ddd555993129231be94485533777ce52a1841/src/main/java/com/github/mygreen/supercsv/cellprocessor/conversion/RegexReplace.java#L77-L83\r\n\r\n`matcher.matches()`を使用すると完全一致の比較になってしまいます。\r\n部分一致させて`matcher.replacheAll()`を呼ぶ場合、`matcher.find()`が適切かと思います。\r\n\r\nまたは、CsvRegexReplaceはCsvRegexReplaceFirstとして、CsvRegexReplaceAllとして作成したほうが良いでしょうか？\r\n"},"comment":{"url":"https://api.github.com/repos/mygreen/super-csv-annotation/issues/comments/403261840","html_url":"https://github.com/mygreen/super-csv-annotation/issues/34#issuecomment-403261840","issue_url":"https://api.github.com/repos/mygreen/super-csv-annotation/issues/34","id":403261840,"node_id":"MDEyOklzc3VlQ29tbWVudDQwMzI2MTg0MA==","user":{"login":"mygreen","id":3822048,"node_id":"MDQ6VXNlcjM4MjIwNDg=","avatar_url":"https://avatars2.githubusercontent.com/u/3822048?v=4","gravatar_id":"","url":"https://api.github.com/users/mygreen","html_url":"https://github.com/mygreen","followers_url":"https://api.github.com/users/mygreen/followers","following_url":"https://api.github.com/users/mygreen/following{/other_user}","gists_url":"https://api.github.com/users/mygreen/gists{/gist_id}","starred_url":"https://api.github.com/users/mygreen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mygreen/subscriptions","organizations_url":"https://api.github.com/users/mygreen/orgs","repos_url":"https://api.github.com/users/mygreen/repos","events_url":"https://api.github.com/users/mygreen/events{/privacy}","received_events_url":"https://api.github.com/users/mygreen/received_events","type":"User","site_admin":false},"created_at":"2018-07-08T04:39:18Z","updated_at":"2018-07-08T04:39:18Z","author_association":"OWNER","body":"2種類用意するならば、アノテーションの属性で設定を切り替えられるようにした方がいい気がします。\r\n\r\n- ``@CsvRegexpReplace(method=MatchMethod.All)`` - 今までの全体一致\r\n- ``@CsvRegexpReplace(method=MatchMethod.Partial)`` - 部分一致\r\n"}}
{"actor":{"display_login":"mygreen"}}