현재 샘플 키보드 소스로 키보드를 하나 만들어보고 있습니다.

일단 xmlpullparser를 이용하여 qwerty.xml의 속성값을 가져왔는데요

가져온 속성값으로 해당 속성을 찾아내서 값을 변경한 후 xml파일을 저장하고 키보드에 적용 시키는 방법을 알 수가 없습니다;

값을 변경하는 법과 xml을 저장하고 키보드에 적용 시키는 법을 알고 싶습니다
package com.example.android.softkeyboard;
import android.inputmethodservice.*;
import android.os.Bundle;
import android.app.Activity;
import android.view.View;
import android.widget.TextView;
import android.widget.Toast;
import android.widget.Button;
import java.util.ArrayList;
import org.xmlpull.v1.XmlPullParser;
public class xmlpullparser extends Activity {
    Button btn;
    
 /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle icicle) {
        super.onCreate(icicle);
        setContentView(R.layout.main);
    }
    
    public void onResume()
    {
     super.onResume();
     
     btn = (Button)findViewById(R.id.Button01);
     
     btn.setOnClickListener(new View.OnClickListener() {
   
   public void onClick(View v) {
    // TODO Auto-generated method stub
   
    try
          {
           XmlPullParser xpp = getResources().getXml(R.xml.qwerty);
           
           String sTag;
           int eventType = xpp.getEventType();
           
           while (eventType != XmlPullParser.END_DOCUMENT)
           {
            switch(eventType)
            {
            case XmlPullParser.START_DOCUMENT:
             break;
             
            case XmlPullParser.END_DOCUMENT:
             break;
             
            case XmlPullParser.START_TAG:
             sTag = xpp.getName();
                       
             if(xpp.getName().equals("Key"))
             {
              xpp.getAttributeValue(0);
              
              if(xpp.getAttributeValue(0) == "1")
              {
               xpp.setProperty("android:Label", "ㄱ");
              }
             }
             break;
             
            case XmlPullParser.END_TAG:
             sTag = xpp.getName();
             break;
            
            case XmlPullParser.TEXT:
             break;
            }
            
            eventType = xpp.next();
           }
          }
          
          catch(Exception e)
          {
          }            
   }
  });
    }
}

qwerty.xml

<Keyboard xmlns:android="http://schemas.android.com/apk/res/android" android:keyWidth="25%p" android:horizontalGap="0px" android:verticalGap="0px" android:keyHeight="@dimen/key_height">
    <Row>
        <Key android:codes="1" android:keyLabel="q" android:keyEdgeFlags="left"/>
        <Key android:codes="2" android:keyLabel="i"/>
        <Key android:codes="3" android:keyLabel="o"/>
        <Key android:codes="4" android:keyLabel="p" android:keyEdgeFlags="right"/>
    </Row>
    
    <Row>
        <Key android:codes="5" android:keyLabel="a" android:keyEdgeFlags="left"/>
        <Key android:codes="6" android:keyLabel="j"/>
        <Key android:codes="7" android:keyLabel="k"/>
        <Key android:codes="8" android:keyLabel="l" android:keyEdgeFlags="right"/>
    </Row>
    
    <Row>
        <Key android:codes="9" android:keyLabel="z" android:keyEdgeFlags="left"/>
        <Key android:codes="10" android:keyLabel="x"/>
        <Key android:codes="11" android:keyLabel="c"/>
        <Key android:codes="12" android:keyLabel="v" android:keyEdgeFlags="right"/>
    </Row>
    
    <Row android:rowEdgeFlags="bottom">
        <Key android:codes="13" android:keyLabel="a" android:keyEdgeFlags="left"/>
        <Key android:codes="14" android:keyLabel="a"/>
        <Key android:codes="15" android:keyLabel="a"/>
        <Key android:codes="16" android:keyLabel="." android:keyEdgeFlags="right"/>
    </Row>
</Keyboard>