# -*- coding: utf-8 -*-
path = r'F:\jiawen_workspace\ruiqiu-java\ruoyi-system\src\main\java\com\ruoyi\system\utils\ProcessOrderKnowledgeUtils.java'
with open(path, 'rb') as f:
    data = f.read()
text = data.decode('utf-8')
for i, line in enumerate(text.splitlines(), 1):
    interesting = False
    for ch in line:
        if ord(ch) > 127 or ch == '?':
            interesting = True
            break
    if interesting and any(k in line for k in ['parts.add', 'join', 'startsWith', 'return "', 'replace', 'contains', '/**']):
        print('LINE', i)
        print('REPR', repr(line))
        print('CHARS', [(c, hex(ord(c))) for c in line if ord(c) > 127 or c == '?'])
        print('---')
