docs: @SuppressWarnings("unchecked")
      public <PE extends ExtensionElement> PE getExtension(String elementName, String namespace) {
          if (namespace == null) {
              return null;
          }
          String key = XmppStringUtils.generateKey(elementName, namespace);
          ExtensionElement packetExtension;
          synchronized (payload) {
              packetExtension = payload.getFirst(key);
          }
          if (packetExtension == null) {
              return null;
          }
          return (PE) packetExtension;
      }