特定の単語を含む csv 内の特定の行を (検索を使用して UI で行うように) 検索できるかどうかを知りたかったのです。opencsv はこの機能を提供しますか?
そうでない場合、csv ファイルを検索する最良の方法は何ですか。
いいえ、そうではありませんが、フィールドを単純に繰り返すことができます
CSVReader reader = new CSVReader(new FileReader("yourfile.csv"));
String [] nextLine;
String searchWord = ".*\\d+.*"; // field contains integer?
while ((nextLine = reader.readNext()) != null) {
for (String field: nextLine) {
if (field.matches(searchWord)) {
// matched word...
}
}
}