Package org.jivesoftware.smackx.packet

Examples of org.jivesoftware.smackx.packet.MUCUser$Status


  private GetObjectExtendedResponse toGetObjectExtendedResponse(S3GetObjectResponse engineResponse) {
    GetObjectExtendedResponse response = new GetObjectExtendedResponse();
    int resultCode = engineResponse.getResultCode();

    GetObjectResult result = new GetObjectResult();
    Status param1 = new Status();
    param1.setCode( resultCode );
    param1.setDescription( engineResponse.getResultDescription());
    result.setStatus( param1 );

    if ( 200 == resultCode || 206 == resultCode )
    {
         result.setData(engineResponse.getData());
View Full Code Here


    return request;
  }
 
  private DeleteObjectResponse toDeleteObjectResponse(S3Response engineResponse) {
    DeleteObjectResponse response = new DeleteObjectResponse();
    Status status = new Status();
    status.setCode(engineResponse.getResultCode());
    status.setDescription(engineResponse.getResultDescription());
    response.setDeleteObjectResponse(status);
    return response;
  }
View Full Code Here

    /**
     * Stores the current state machine configuration ({@link Status#getAllStates()}) in the system context.
     * @param scInstance the state machine instance holding the current configuration
     */
    public void setSystemAllStatesVariable(final SCInstance scInstance) {
        Status currentStatus = scInstance.getCurrentStatus();
        scInstance.getSystemContext().setLocal(SCXMLSystemContext.ALL_STATES_KEY, currentStatus.getAllStates());
    }
View Full Code Here

    public void disconnect() {
        if(nickList != null) nickList.clear();
    }

    public void doAction(String command, MUCBuddyStatus buddy) {
        MUCUser user = buddy.getMUCUser();
        if (user == null) {
            serverErrorMessage(resources.getString("jidNotFound"));
            return;
        }

        MUCUser.Item item = user.getItem();

        if (item == null) {
            serverErrorMessage(resources.getString("jidNotFound"));
            return;
        }
View Full Code Here

                MUCBuddyStatus buddy = window.getBuddyStatus(from);

                window.removeBuddy(buddy.getUser());

                // get the role and affiliation information
                MUCUser user = (MUCUser) presence.getExtension("x",
                        "http://jabber.org/protocol/muc#user");
                if (user != null) {
                    buddy.setMUCUser(user);
                    MUCUser.Item item = user.getItem();
                    if (item != null) {
                        if (item.getAffiliation() != null)
                            buddy.setAffiliation(item.getAffiliation());
                        if (item.getRole() != null)
                            buddy.setRole(item.getRole());
View Full Code Here

        public BanThread(String reason) {
            this.reason = reason;
        }

        public void run() {
            MUCUser user = ((MUCBuddyStatus) buddy).getMUCUser();
            if (user == null)
                return;

            MUCUser.Item item = user.getItem();
            if (item == null)
                return;

            String jid = item.getJid();
            if (jid == null)
View Full Code Here

  private void addUser(final String occupant) {
    userList.getDisplay().asyncExec(new Runnable() {

      public void run() {
        Presence presence = getPresence(occupant);
        MUCUser mucUser = (MUCUser) presence.getExtension("x",
            "http://jabber.org/protocol/muc#user");
        MUCUser.Item item = mucUser.getItem();
        final String nick = StringUtils.parseResource(presence.getFrom());
        String role = item.getRole();
        TreeItem occupantItem;
        //Do this here so the suubtrees are in the right order
        getModeratorsItem();
View Full Code Here

   *
   * @param occupant
   * @return
   */
  private MUCUser.Item getMUCItem(String occupant) {
    MUCUser mucUser = (MUCUser) getPresence(occupant)
      .getExtension("x", "http://jabber.org/protocol/muc#user");
    return mucUser.getItem();
  }
View Full Code Here

        this.nick = item.getNick();
    }

    Occupant(Presence presence) {
        super();
        MUCUser mucUser = (MUCUser) presence.getExtension("x",
                "http://jabber.org/protocol/muc#user");
        MUCUser.Item item = mucUser.getItem();
        this.jid = item.getJid();
        this.affiliation = item.getAffiliation();
        this.role = item.getRole();
        // Get the nickname from the FROM attribute of the presence
        this.nick = StringUtils.parseResource(presence.getFrom());
View Full Code Here

                }
            }

            else {
                // Check if a room invitation was sent and if the sender is the workgroup
                MUCUser mucUser = (MUCUser)msg.getExtension("x", "http://jabber.org/protocol/muc#user");
                MUCUser.Invite invite = mucUser != null ? mucUser.getInvite() : null;
                if (invite != null && workgroupJID.equals(invite.getFrom())) {
                    String sessionID = null;
                    Map metaData = null;

                    pe = msg.getExtension(SessionID.ELEMENT_NAME,
View Full Code Here

TOP

Related Classes of org.jivesoftware.smackx.packet.MUCUser$Status

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.