亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? element.java

?? wap瀏覽器 日程安排 Rss 棋牌游戲
?? JAVA
字號:
/* Copyright (c) 2002,2003, Stefan Haustein, Oberhausen, Rhld., Germany * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or * sell copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The  above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS * IN THE SOFTWARE. */package org.kxml2.kdom;import java.io.*;import java.util.*;import org.xmlpull.v1.*;/**  * In order to create an element, please use the createElement method * instead of invoking the constructor directly. The right place to * add user defined initialization code is the init method. */public class Element extends Node {    protected String namespace;    protected String name;    protected Vector attributes;    protected Node parent;    protected Vector prefixes;    public Element() {    }    /**      * called when all properties are set, but before children     * are parsed. Please do not use setParent for initialization     * code any longer. */    public void init() {    }    /**      * removes all children and attributes */    public void clear() {        attributes = null;        children = null;    }    /**      * Forwards creation request to parent if any, otherwise     * calls super.createElement. */    public Element createElement(        String namespace,        String name) {         return (this.parent == null)            ? super.createElement(namespace, name)            : this.parent.createElement(namespace, name);    }    /**      * Returns the number of attributes of this element. */    public int getAttributeCount() {        return attributes == null ? 0 : attributes.size ();    }	public String getAttributeNamespace (int index) {		return ((String []) attributes.elementAt (index)) [0];	}/*	public String getAttributePrefix (int index) {		return ((String []) attributes.elementAt (index)) [1];	}*/		public String getAttributeName (int index) {		return ((String []) attributes.elementAt (index)) [1];	}		public String getAttributeValue (int index) {		return ((String []) attributes.elementAt (index)) [2];	}			public String getAttributeValue (String namespace, String name) {		for (int i = 0; i < getAttributeCount (); i++) {			if (name.equals (getAttributeName (i)) 				&& (namespace == null || namespace.equals (getAttributeNamespace(i)))) {				return getAttributeValue (i);			}		}								return null;				}    /**      * Returns the root node, determined by ascending to the      * all parents un of the root element. */    public Node getRoot() {        Element current = this;                while (current.parent != null) {            if (!(current.parent instanceof Element)) return current.parent;            current = (Element) current.parent;        }                return current;    }    /**      * returns the (local) name of the element */    public String getName() {        return name;    }    /**      * returns the namespace of the element */    public String getNamespace() {        return namespace;    }    /**      * returns the namespace for the given prefix */        public String getNamespaceUri (String prefix) {    	int cnt = getNamespaceCount ();		for (int i = 0; i < cnt; i++) {			if (prefix == getNamespacePrefix (i) ||				(prefix != null && prefix.equals (getNamespacePrefix (i))))				return getNamespaceUri (i);			}		return parent instanceof Element ? ((Element) parent).getNamespaceUri (prefix) : null;    }	/**      * returns the number of declared namespaces, NOT including	 * parent elements */	public int getNamespaceCount () {		return (prefixes == null ? 0 : prefixes.size ());	}	public String getNamespacePrefix (int i) {		return ((String []) prefixes.elementAt (i)) [0];	}	public String getNamespaceUri (int i) {		return ((String []) prefixes.elementAt (i)) [1];	}    /**      * Returns the parent node of this element */    public Node getParent() {        return parent;    }    /*      * Returns the parent element if available, null otherwise     public Element getParentElement() {        return (parent instanceof Element)            ? ((Element) parent)            : null;    }*/    /**      * Builds the child elements from the given Parser. By overwriting      * parse, an element can take complete control over parsing its      * subtree. */    public void parse(XmlPullParser parser)        throws IOException, XmlPullParserException {        for (int i = parser.getNamespaceCount (parser.getDepth () - 1);        	i < parser.getNamespaceCount (parser.getDepth ()); i++) {        	setPrefix (parser.getNamespacePrefix (i), parser.getNamespaceUri(i));        }                        for (int i = 0; i < parser.getAttributeCount (); i++) 	        setAttribute (parser.getAttributeNamespace (i),//	        			  parser.getAttributePrefix (i),	        			  parser.getAttributeName (i),	        			  parser.getAttributeValue (i));        //        if (prefixMap == null) throw new RuntimeException ("!!");        init();		if (parser.isEmptyElementTag()) 			parser.nextToken ();		else {			parser.nextToken ();	        super.parse(parser);        	if (getChildCount() == 0)            	addChild(IGNORABLE_WHITESPACE, "");		}		        parser.require(            XmlPullParser.END_TAG,            getNamespace(),            getName());                    parser.nextToken ();    }    /**      * Sets the given attribute; a value of null removes the attribute */	public void setAttribute (String namespace, String name, String value) {		if (attributes == null) 			attributes = new Vector ();		if (namespace == null) 			namespace = "";		        for (int i = attributes.size()-1; i >=0; i--){            String[] attribut = (String[]) attributes.elementAt(i);            if (attribut[0].equals(namespace) &&				attribut[1].equals(name)){									if (value == null) {	                attributes.removeElementAt(i);				}				else {					attribut[2] = value;				}	            return; 			}        }		attributes.addElement 			(new String [] {namespace, name, value});	}	/**      * Sets the given prefix; a namespace value of null removess the 	 * prefix */	public void setPrefix (String prefix, String namespace) {		if (prefixes == null) prefixes = new Vector ();		prefixes.addElement (new String [] {prefix, namespace});			}    /**      * sets the name of the element */    public void setName(String name) {        this.name = name;    }    /**      * sets the namespace of the element. Please note: For no     * namespace, please use Xml.NO_NAMESPACE, null is not a legal     * value. Currently, null is converted to Xml.NO_NAMESPACE, but     * future versions may throw an exception. */    public void setNamespace(String namespace) {        if (namespace == null)         	throw new NullPointerException ("Use \"\" for empty namespace");        this.namespace = namespace;    }    /**      * Sets the Parent of this element. Automatically called from the     * add method.  Please use with care, you can simply     * create inconsitencies in the document tree structure using     * this method!  */    protected void setParent(Node parent) {        this.parent = parent;    }    /**      * Writes this element and all children to the given XmlWriter. */    public void write(XmlSerializer writer)        throws IOException {		if (prefixes != null) {			for (int i = 0; i < prefixes.size (); i++) {				writer.setPrefix (getNamespacePrefix (i), getNamespaceUri (i));			}		}        writer.startTag(            getNamespace(),            getName());        int len = getAttributeCount();        for (int i = 0; i < len; i++) {            writer.attribute(                getAttributeNamespace(i),                getAttributeName(i),                getAttributeValue(i));        }        writeChildren(writer);        writer.endTag(getNamespace (), getName ());    }}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
夜夜操天天操亚洲| 欧美电影免费观看高清完整版在线| 在线观看视频一区二区| 欧美日韩一卡二卡| 久久老女人爱爱| 亚洲免费三区一区二区| 视频一区二区不卡| 国产福利一区二区| 欧洲一区二区av| www国产精品av| 亚洲蜜臀av乱码久久精品蜜桃| 污片在线观看一区二区| 成人性生交大片| 欧美三级电影网站| 国产日韩精品一区二区三区在线| 亚洲精品综合在线| 久久99国产精品免费| av午夜精品一区二区三区| 91精品国产免费| 综合久久久久综合| 韩国精品免费视频| 欧美午夜精品免费| 国产亚洲欧洲997久久综合| 亚洲一区在线视频观看| 国产高清成人在线| 日韩限制级电影在线观看| 综合激情成人伊人| 激情综合色丁香一区二区| 欧美亚洲图片小说| 国产精品乱码人人做人人爱 | 97国产精品videossex| 91精品综合久久久久久| 国产精品女同一区二区三区| 亚洲成人在线免费| 99久久久精品| 国产三级精品三级| 奇米影视在线99精品| 日本韩国欧美在线| 中文字幕第一区第二区| 久久精品国产999大香线蕉| 欧美性xxxxxxxx| 国产精品国产馆在线真实露脸| 精品一区二区三区影院在线午夜| 在线观看91视频| 亚洲三级免费观看| 成人理论电影网| 久久综合色之久久综合| 日本不卡的三区四区五区| 91精品1区2区| 综合激情成人伊人| 99久久精品国产观看| 国产日本欧洲亚洲| 国产一区二区三区综合| 日韩精品中文字幕在线不卡尤物| 亚洲图片欧美一区| 欧美性videosxxxxx| 亚洲九九爱视频| 97久久超碰国产精品| 中文字幕一区日韩精品欧美| 国产精品性做久久久久久| 久久综合久久综合久久综合| 日韩成人精品视频| 欧美丰满一区二区免费视频| 亚洲风情在线资源站| 精品婷婷伊人一区三区三| 亚洲网友自拍偷拍| 欧美日韩高清一区| 日本亚洲最大的色成网站www| 911精品产国品一二三产区| 亚洲国产精品一区二区久久恐怖片 | 欧美日韩亚洲另类| 亚洲一区二区三区视频在线| 91热门视频在线观看| 中文字幕亚洲综合久久菠萝蜜| 国产不卡视频一区二区三区| 国产欧美视频一区二区三区| 国产成a人无v码亚洲福利| 欧美国产日韩一二三区| 成人18视频在线播放| ...xxx性欧美| 在线一区二区三区四区五区| 亚洲亚洲人成综合网络| 欧美日韩国产小视频在线观看| 天堂蜜桃91精品| 精品国产一区二区三区忘忧草| 久久97超碰色| 国产女人18毛片水真多成人如厕| 国产69精品久久777的优势| 国产精品福利一区| 欧美在线视频你懂得| 婷婷综合久久一区二区三区| 日韩欧美一二区| 国产成人免费高清| 亚洲综合网站在线观看| 91精品欧美一区二区三区综合在| 蜜乳av一区二区三区| 欧美经典一区二区| 91免费在线视频观看| 亚洲午夜国产一区99re久久| 69av一区二区三区| 福利电影一区二区| 一区二区三区中文在线观看| 欧美精品精品一区| 国产真实乱偷精品视频免| 中文字幕在线观看不卡视频| 欧美一级一级性生活免费录像| 国产一区二区三区| 亚洲色图20p| 欧美一区二区三级| 丰满少妇久久久久久久| 亚洲一二三级电影| 久久久精品免费免费| 色综合久久88色综合天天免费| 婷婷中文字幕一区三区| 日本一区二区三区高清不卡| 在线观看免费视频综合| 久久99精品久久久久久动态图| 国产精品乱码一区二三区小蝌蚪| 在线成人免费观看| 精品国精品自拍自在线| 成人h精品动漫一区二区三区| 亚洲第一会所有码转帖| 久久久午夜电影| 精品视频色一区| 国产91在线|亚洲| 日韩影院精彩在线| 综合久久久久久| 久久久亚洲高清| 91麻豆精品国产91久久久久久久久| 成人在线视频一区| 免费观看日韩av| 亚洲欧美视频在线观看视频| 精品人伦一区二区色婷婷| 91福利视频网站| 国产91在线观看丝袜| 免费的国产精品| 亚洲制服丝袜在线| 中文字幕第一区综合| 精品欧美久久久| 欧美日韩在线观看一区二区 | 国产精品国产三级国产普通话蜜臀| 欧美在线播放高清精品| 国产91对白在线观看九色| 裸体歌舞表演一区二区| 亚洲一区二区av电影| 国产精品久久久久精k8| 精品乱码亚洲一区二区不卡| 欧美日产国产精品| 91极品视觉盛宴| 成人国产一区二区三区精品| 国产在线一区观看| 免费成人在线网站| 日韩精品亚洲专区| 亚洲午夜久久久久中文字幕久| 亚洲国产精品成人综合| 久久综合色婷婷| 精品国产电影一区二区| 日韩一区二区电影网| 欧美日韩国产高清一区| 在线观看国产日韩| 色先锋资源久久综合| 成人av免费观看| 国产成人8x视频一区二区 | 国产精品免费久久久久| 久久久不卡网国产精品一区| 欧美大片在线观看一区二区| 69堂亚洲精品首页| 欧美高清www午色夜在线视频| 欧美日精品一区视频| 色婷婷综合五月| 91麻豆免费看| 色综合久久综合网| 99久久综合国产精品| 成人免费看片app下载| 福利视频网站一区二区三区| 国产精品自在欧美一区| 国模套图日韩精品一区二区 | 国产三级一区二区| 国产亚洲美州欧州综合国| 久久嫩草精品久久久久| 久久综合资源网| 久久久久久久久久久电影| 久久久久久电影| 国产欧美视频一区二区| 国产精品久99| 亚洲欧美日韩在线| 亚洲在线视频免费观看| 亚洲一区二区欧美激情| 日韩电影一二三区| 蜜桃av一区二区三区电影| 韩国午夜理伦三级不卡影院| 国产精品影视网| 成人av在线观| 91行情网站电视在线观看高清版| 91精品办公室少妇高潮对白| 欧美精品vⅰdeose4hd| 日韩一区二区中文字幕| 亚洲精品一区二区三区香蕉| 国产亚洲精品7777| 国产精品国产三级国产aⅴ中文|