添加“!”后,我无法找到解决以下工作的方法 在它的中间
<category>
<pattern>test</pattern>
<template>testing stuff.</template>
</category>
<category>
<pattern>gg</pattern>
<that> testing stuff </that>
<template>works</template>
</category>
上面的代码工作得很好,但是当你把它改成:
<category>
<pattern>test</pattern>
<template>testing! stuff.</template>
</category>
<category>
<pattern>gg</pattern>
<that> testing stuff </that>
<template>works</template>
</category>
它只是停止工作。
那我如何让第二段代码工作呢?机器人所说的必须包含这个“!” 在它的中间
编辑:
我通过执行以下操作找到了解决方法:
<category>
<pattern>test</pattern>
<template>testing! stuff.</template>
</category>
<category>
<pattern>gg</pattern>
<that> stuff </that>
<template>works</template>
</category>
它可以工作,因为在属性文件中它被配置为看到“!” 作为分线器,但似乎有点意外......有什么合适的方法来处理这个问题吗?