如何从下面的字符串中拆分多个引号

时间:2021-08-07 21:47:21

How I can split multiple quotation marks from this string? please help me, my project stuck here because of this.

如何从这个字符串中拆分多个引号?请帮助我,我的项目因此而停留在这里。

strLine1.trim().equalsIgnoreCase("Header Perceived Severity="":Friendly Name="":Alarm Type="":Specific Problems="":Event Date and Time="":Clearing Status="":Clearing Time="";");

1 个解决方案

#1


2  

You code won't comiple:

你的代码不会改编:

strLine1.trim().equalsIgnoreCase("Header Perceived Severity="":Friendly Name="":
    Alarm Type="":Specific Problems="":Event Date and Time="":
    Clearing Status="":Clearing Time="");
  1. missed the closing brackets in the end.
  2. 最后错过了结束括号。

  3. you need to escape quotations
  4. 你需要逃避报价

  5. add one more quotation in the end
  6. 最后再添加一个引号

.

strLine1.trim().equalsIgnoreCase("Header Perceived Severity=\"\":Friendly Name=\"\":
    Alarm Type=\"\":Specific Problems=\"\":Event Date and Time=\"\":
    Clearing Status=\"\":Clearing Time=\"\"");

#1


2  

You code won't comiple:

你的代码不会改编:

strLine1.trim().equalsIgnoreCase("Header Perceived Severity="":Friendly Name="":
    Alarm Type="":Specific Problems="":Event Date and Time="":
    Clearing Status="":Clearing Time="");
  1. missed the closing brackets in the end.
  2. 最后错过了结束括号。

  3. you need to escape quotations
  4. 你需要逃避报价

  5. add one more quotation in the end
  6. 最后再添加一个引号

.

strLine1.trim().equalsIgnoreCase("Header Perceived Severity=\"\":Friendly Name=\"\":
    Alarm Type=\"\":Specific Problems=\"\":Event Date and Time=\"\":
    Clearing Status=\"\":Clearing Time=\"\"");