Code example for XmlPullParserException

0
                        + "> only supports string, integer, float, color, and boolean at " 
                        + attrs.getPositionDescription());
            } 
        } else { 
            sa.recycle();
            throw new XmlPullParserException("<" + tagName
                    + "> requires an holo:value attribute at " + attrs.getPositionDescription());
        } 
        sa.recycle();
    } 
 
    private static Intent parseIntent(Resources resources, XmlPullParser parser, AttributeSet attrs)
            throws XmlPullParserException, IOException { 
        Intent intent = new Intent();
        TypedArray sa = resources.obtainAttributes(attrs,
                R.styleable.Intent); 
        intent.setAction(sa.getString(R.styleable.Intent_android_action));
        String data = sa.getString(R.styleable.Intent_android_data);
        String mimeType = sa.getString(R.styleable.Intent_android_mimeType);
        intent.setDataAndType(data != null ? Uri.parse(data) : null, mimeType);
        String packageName = sa.getString(R.styleable.Intent_android_targetPackage);