JSP string operation problem 1

xiaoxiao2021-03-06  41

String Detailsub1 = "" ", detailssub2 =" ""; "

INT POS_1 = 0, POS_2 = 0;

INT i = 0;

While (True)

{

POS_1 = detail.indexof ("<");

IF (pOS_1> = 0)

{

Detailsub1 = detail.substring (0, (pOS_1));

POS_2 = detail.indexof (">");

Detailsub2 = detail.substring (pOS_1, POS_2 1);

/ * if (pOS_2> = 0)

{

Detailsub2 = detail.substring (pOS_1, POS_2 1);

Detail = detail.substring (pOS_2 1);

}

Else

{

Detailsub2 = detail.substring (pOS_1);

DETAIL = "";

}

* /

Detail = detail.substring (pOS_2 1);

DetailConvert = DETAILSUB1 DETAILSUB2;

}

Else

{

DetailConvert = detail;

Break;

}

// i check will not have a dead cycle

IF (i > 100)

{

Break;

}

}

Detail = DetailConvert; // detail;

转载请注明原文地址:https://www.9cbs.com/read-86491.html

New Post(0)