aboutsummaryrefslogtreecommitdiffstats
path: root/teal-src
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2022-10-17 15:13:04 +0200
committerKim Alvefur <zash@zash.se>2022-10-17 15:13:04 +0200
commitaa8f7d1533ae86e6832a5a1ec506d58dee213d36 (patch)
tree4124557bfb540a5cfab83f20a8de7767c2c10aaf /teal-src
parentfdf61a38cfa273c4781dbe578647638106cb7b52 (diff)
downloadprosody-aa8f7d1533ae86e6832a5a1ec506d58dee213d36.tar.gz
prosody-aa8f7d1533ae86e6832a5a1ec506d58dee213d36.zip
util.stanza: Add new methods to Teal interface specification
at_top: 21217f7e82b9 get_child_with_attr: 39164ea2ab9e get_child_attr: e8934ce6ea0f add_error: 5f182bccf33f
Diffstat (limited to 'teal-src')
-rw-r--r--teal-src/util/stanza.d.tl5
1 files changed, 5 insertions, 0 deletions
diff --git a/teal-src/util/stanza.d.tl b/teal-src/util/stanza.d.tl
index 1f565b88..e1ab2105 100644
--- a/teal-src/util/stanza.d.tl
+++ b/teal-src/util/stanza.d.tl
@@ -49,6 +49,7 @@ local record lib
tag : function ( stanza_t, string, { string : string } ) : stanza_t
text : function ( stanza_t, string ) : stanza_t
up : function ( stanza_t ) : stanza_t
+ at_top : function ( stanza_t ) : boolean
reset : function ( stanza_t ) : stanza_t
add_direct_child : function ( stanza_t, stanza_t )
add_child : function ( stanza_t, stanza_t )
@@ -57,6 +58,8 @@ local record lib
get_child : function ( stanza_t, string, string ) : stanza_t
get_text : function ( stanza_t ) : string
get_child_text : function ( stanza_t, string, string ) : string
+ get_child_attr : function ( stanza_t, string, string ) : string
+ get_child_with_attr : function ( stanza_t, string, string, string, function (string) : boolean ) : string
child_with_name : function ( stanza_t, string, string ) : stanza_t
child_with_ns : function ( stanza_t, string, string ) : stanza_t
children : function ( stanza_t ) : children_iter, stanza_t, integer
@@ -68,7 +71,9 @@ local record lib
pretty_print : function ( stanza_t ) : string
pretty_top_tag : function ( stanza_t ) : string
+ -- FIXME Represent util.error support
get_error : function ( stanza_t ) : stanza_error_type, stanza_error_condition, string, stanza_t
+ add_error : function ( stanza_t, stanza_error_type, stanza_error_condition, string, string )
indent : function ( stanza_t, integer, string ) : stanza_t
end