code: public boolean supportsAccountCreation() throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
          // TODO: Replace this body with isSupported() and possible deprecate this method.
  
          // Check if we already know that the server supports creating new accounts
          if (accountCreationSupported) {
              return true;
          }
          // No information is known yet (e.g. no stream feature was received from the server
          // indicating that it supports creating new accounts) so send an IQ packet as a way
          // to discover if this feature is supported
          if (info == null) {
              getRegistrationInfo();
              accountCreationSupported = info.getType() != IQ.Type.error;
          }
          return accountCreationSupported;
      }
docs: Returns true if the server supports creating new accounts. Many servers require
  that you not be currently authenticated when creating new accounts, so the safest
  behavior is to only create new accounts before having logged in to a server.
  
  @return true if the server support creating new accounts.
  @throws XMPPErrorException
  @throws NoResponseException
  @throws NotConnectedException
  @throws InterruptedException