Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 73: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 74: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 75: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 76: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 77: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 78: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
package com.example.compxml; import java.io.IOException; import org.xmlpull.v1.XmlPullParserException; import android.app.Activity; import android.content.res.XmlResourceParser; import android.os.Bundle; import android.util.Log; import android.widget.TextView; public class CompXML extends Activity { private static final String TAG = "CompXML"; /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // Create a new TextView that we can accumulate and display our parsed data to. TextView tv = new TextView(this); tv.setText(""); try { // Get the Android-specific compiled XML parser. XmlResourceParser xrp = this.getResources().getXml(R.xml.test); while (xrp.getEventType() != XmlResourceParser.END_DOCUMENT) { if (xrp.getEventType() == XmlResourceParser.START_TAG) { String s = xrp.getName(); if (s.equals("pictag")) { // Get the resource id; this will be retrieved //as a resolved hex value. int resid = xrp.getAttributeResourceValue(null, "id", 0); tv.append("Attribute id has value " + Integer.toHexString(resid) + " from tag " + s + "\n"); // Get our custom string attribute. String sn = xrp.getAttributeValue(null, "mystr"); tv.append("Attribute mystr has value " + sn + " from tag " + s + "\n"); // Get our custom int attribute. int i = xrp.getAttributeIntValue(null, "myint", 0); tv.append("Attribute myint has value " + i + " from tag " + s + "\n\n"); } else if (s.equals("artag")) { // Get the resource id; this will be retrieved //as a resolved hex value. int resid = xrp.getAttributeResourceValue(null, "id", 0); tv.append("Attribute id has value " + Integer.toHexString(resid) + " from tag " + s + "\n"); // Get our custom string attribute String sn = xrp.getAttributeValue(null, "mystr"); tv.append("Attribute mystr has value " + sn + " from tag " + s + "\n"); // Get our custom float attribute. float f = xrp.getAttributeFloatValue(null, "myfloat", 0); tv.append("Attribute myfloat has value " + f + " from tag " + s + "\n\n"); } else if (s.equals("plaintag")) { // Get the element tag name here; the value is // gotten on the next TEXT event. tv.append("Tag " + s + " has value "); } } else if (xrp.getEventType() == XmlResourceParser.END_TAG) { ; } else if (xrp.getEventType() == XmlResourceParser.TEXT) { // Get our value from the plaintag element. // Since this is a value and not an // attribute, we retrieve it with the // generic .getText(). String s1 = xrp.getText(); tv.append(s1 + "\n\n"); } xrp.next(); } xrp.close(); } catch (XmlPullParserException xppe) { Log.e(TAG, "Failure of .getEventType or .next, probably bad file format"); xppe.toString(); } catch (IOException ioe) { Log.e(TAG, "Unable to read resource file"); ioe.printStackTrace(); } // Display our accumulated string, containing the XML data we just parsed. setContentView(tv); } }