xml标记值 - 大写更改为驼峰大小写

时间:2017-04-11 12:21:16

标签: regex notepad++

寻求帮助来转换标记值的大小。

    <folder><title>TestGrp01</title>
        <program><title>V-Test Name 01</title><rulename>AVL_KMPL_AQS_SW_YRT</rulename></program>
        <program><title>V-Test Name 02</title><rulename>KML_RTWE_WE_SQ</rulename></program>
    </folder>
    <folder><title>TestGrp02</title>
        <program><title>V-Test Name 11</title><rulename>DER_ADEF_GT_IK_KIU</rulename></program>
        <program><title>V-Test Name 12</title><rulename>SDFDF_WE_OK</rulename></program>
    </folder>       

我想将rulename标记内的值转换为驼峰大小写,如下所示。

AVL_KMPL_AQS_SW_YRT - &gt; Avl_Kmpl_Aqs_Sw_Yrt

KML_RTWE_WE_SQ - &gt; Kml_Rtwe_We_Sq

DER_ADEF_GT_IK_KIU - &gt; Der_Adef_Gt_Ik_Kiu

SDFDF_WE_OK - &gt; Sdfdf_We_Ok

所以最终输出如下。

    <folder><title>TestGrp01</title>
        <program><title>V-Test Name 01</title><rulename>Avl_Kmpl_Aqs_Sw_Yrt</rulename></program>
        <program><title>V-Test Name 02</title><rulename>Kml_Rtwe_We_Sq</rulename></program>
    </folder>
    <folder><title>TestGrp02</title>
        <program><title>V-Test Name 11</title><rulename>Der_Adef_Gt_Ik_Kiu</rulename></program>
        <program><title>V-Test Name 12</title><rulename>Sdfdf_We_Ok</rulename></program>
    </folder>   

0 个答案:

没有答案