mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2024-11-24 15:22:07 +01:00
Add StanzaView.hasExtension(Class<? extends ExtensionElement>)
This commit is contained in:
parent
5380e5705f
commit
8d432e2303
1 changed files with 5 additions and 1 deletions
|
@ -1,6 +1,6 @@
|
|||
/**
|
||||
*
|
||||
* Copyright 2019 Florian Schmaus
|
||||
* Copyright 2019-2020 Florian Schmaus
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -67,6 +67,10 @@ public interface StanzaView extends XmlLangElement {
|
|||
return getExtension(qname) != null;
|
||||
}
|
||||
|
||||
default boolean hasExtension(Class<? extends ExtensionElement> extensionElementClass) {
|
||||
return getExtension(extensionElementClass) != null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a extension element with the given namespace exists.
|
||||
*
|
||||
|
|
Loading…
Reference in a new issue