リファレンス hasAttribute()

hasAttribute()

要素が指定された属性を持っている場合は true を、持っていない場合は false を返します。

パラメータ name は、チェックする属性の名前を表す文字列です。

注意:属性の値を取得するには myXML.getString() または myXML.getNum() を使用してください。

実例

シンタックス

hasAttribute(name)

パラメーター

name
String:

チェックする属性の名前。

リターン

Boolean: 要素が属性を持っているかどうか。
This page is generated from the comments in src/io/p5.XML.js . Please feel free to edit it and submit a pull request!

関連するリファレンス