tigase.jaxmpp.core.client

## Class JID

- java.lang.Object
- - tigase.jaxmpp.core.client.JID

- All Implemented Interfaces:
    Comparable<JID>

      public class JID
      extends Object
      implements Comparable<JID>

  XMPP entity address form `<localpart@domainpart/resourcepart>`

- - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `compareTo(JID o)`
    `boolean` | `equals(Object obj)`
    `BareJID` | `getBareJid()` Returns bare JID part (`<localpart@domainpart>`) from full JID.
    `String` | `getDomain()` Return domainpart.
    `String` | `getLocalpart()` Return localpart.
    `String` | `getResource()` Return resource.
    `int` | `hashCode()`
    `static JID` | `jidInstance(BareJID bareJid)` Creates intance of `JID` from `BareJID`.
    `static JID` | `jidInstance(BareJID bareJid, String p_resource)` Creates intance of `JID`.
    `static JID` | `jidInstance(String jid)` Creates intance of `JID`.
    `static JID` | `jidInstance(String localpart, String domain)` Creates intance of `JID`.
    `static JID` | `jidInstance(String localpart, String domain, String resource)` Creates intance of `JID`.
    `String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Method Detail

    - #### jidInstance

          public static JID jidInstance(BareJID bareJid)

      Creates intance of `JID` from `BareJID`.
      Parameters:
        `bareJid` - bare JID
      Returns:
        full JID. Resource is `null`.

    - #### jidInstance

          public static JID jidInstance(BareJID bareJid,
                                        String p_resource)

      Creates intance of `JID`.
      Parameters:
        `bareJid` - bare JID
        `p_resource` - resource
      Returns:
        full JID

    - #### jidInstance

          public static JID jidInstance(String jid)

      Creates intance of `JID`.
      Parameters:
        `jid` - string contains JID
      Returns:
        full JID.

    - #### jidInstance

          public static JID jidInstance(String localpart,
                                        String domain)

      Creates intance of `JID`.
      Parameters:
        `localpart` - localpart
        `domain` - domainpart
      Returns:
        full JID.Resource is `null`.

    - #### jidInstance

          public static JID jidInstance(String localpart,
                                        String domain,
                                        String resource)

      Creates intance of `JID`.
      Parameters:
        `localpart` - localpart
        `domain` - domainpart
        `resource` - resource
      Returns:
        full JID.

    - #### compareTo

          public int compareTo(JID o)

      Specified by:
        `compareTo` in interface `Comparable<JID>`

    - #### equals

          public boolean equals(Object obj)

      Overrides:
        `equals` in class `Object`

    - #### getBareJid

          public BareJID getBareJid()

      Returns bare JID part (`<localpart@domainpart>`) from full JID.
      Returns:
        bare JID

    - #### getDomain

          public String getDomain()

      Return domainpart.
      Returns:
        domainpart

    - #### getLocalpart

          public String getLocalpart()

      Return localpart.
      Returns:
        localpart

    - #### getResource

          public String getResource()

      Return resource.
      Returns:
        resource

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

Copyright © 2006–2019 Tigase. All rights reserved.