package com.sample.client;  
  
import com.smartgwt.client.data.DataSource;
import com.smartgwt.client.data.fields.DataSourceTextField;  
  
public class ItemSupplyXmlDS2 extends DataSource {  
  
    private static ItemSupplyXmlDS2 instance = null;  
  
    public static ItemSupplyXmlDS2 getInstance() {  
        if (instance == null) {  
            instance = new ItemSupplyXmlDS2("supplyItemDS2");  
        }  
        return instance;  
    }  
  
    public ItemSupplyXmlDS2(String id) {
        setID(id);
        setRecordXPath("/List/employee");
        DataSourceTextField nameField = new DataSourceTextField("Phone", "Phone", 128);

        DataSourceTextField jobField = new DataSourceTextField("Phone11", "Phone11", 128);  
        jobField.setCanFilter(true);
        jobField.setCanEdit(true);

        setFields(nameField,jobField);

        setDataURL("sample/countryData2.xml");
        setClientOnly(true);
    }  
}  