doneparsing
語法:result:=callobject(object,"doneparsing")
說明:如果xml字符串解析完畢則返回true。
getattributename
語法:result:=callobject(object,"getattributename",ichild,"xmlnode")
說明:返回指定節點的某一屬性名。節點號由參數xmlnode指定,屬性號由參數ichild指定。
getattributevaluebyindex
語法:result:=callobject(object,"getattributevaluebyindex",ivalue,"xmlnode")
說明:根據屬性號,返回指定節點的某一屬性的值。節點號由參數xmlnode指定,屬性號由參數ivalue指定。
getattributevaluebyname
語法:result:=callobject(object,"getattributevaluebyname","attributename","xmlnode")
說明:根據屬性名稱,返回指定節點的某一屬性的值。節點號由參數xmlnode指定,屬性名稱由參數attributename指定。
getchild
語法:result:=callobject(object,"getchild",ichild,"xmlnode")
說明:返回指定xml節點的子節點。例如,第1個結點的第5個子節點表示為“1,5”。xml節點由參數xmlnode指定,根節點對應于0或“0”,子節點序號由參數ichild指定。
getcount
語法:result:=callobject(object,"getcount","objecttype","xmlnode")
說明:返回指定xml節點的子節點或屬性的數量。節點號由參數xmlnode指定。參數objecttype取值為“#attribute”時,該方法返回屬性的數量;取值為“#child”時,該方法返回子節點的數量。
geterror
語法:result:=callobject(object,"geterror")
說明:返回xml字符串解析過程中出現的錯誤。
getname
語法:result:=callobject(object,"getname","xmlnode")
說明:返回指定xml節點的名稱。節點號由參數xmlnode指定。
gettext
語法:result:=callobject(object,"gettext","xmlnode")
說明:如果指定xml節點的類型為text,則返回該節點的內容。節點號由參數xmlnode指定。
gettype
語法:result:=callobject(object,"gettype","xmlnode")
說明:返回指定xml節點的類型,可能的返回值是element或text。節點號由參數xmlnode指定。
ignorewhitespace
語法:result:=callobject(object,"ignorewhitespace",ignore)
說明:設置是否忽略元素開始標記與結束標記之間的空白字符(例如,回車,換行,tab或空格)。參數ignore可以為true或false。默認的設置為true。
makelist
語法:result:=callobject(object,"makelist")
說明:將xml字符串轉換為authorware列表。
newobject
語法:object:=newobject("xmlparser")
說明:創建一個新的xmlparser xtra對象。
parsefile
語法:result:=callobject(object,"parsefile","file")
說明:對指定url地址處的xml文檔進行解析,參數file用于指定url地址??梢酝ㄟ^doneparsing方法檢測解析過程是否結束,通過parsemore方法來強制讀取和解析更多的數據。
parsemore
語法:result:=callobject(object,"parsemore")
說明:解析更多的xml文檔。
parsestring
語法:result:=callobject(object,"parsestring",data)
說明:對xml字符串進行解析。參數"data"就是xml字符串。
新聞熱點
疑難解答