src/net/java/sip/communicator/impl/gui/main/chat/ChatPanel.java
/**
     * Invites the given <tt>chatContacts</tt> to this chat.
     * @param inviteChatTransport the chat transport to use to send the invite
     * @param chatContacts the contacts to invite
     * @param reason the reason of the invitation
     */
Invites the given chatContacts to this chat.
@param inviteChatTransport the chat transport to use to send the invite
@param chatContacts the contacts to invite
@param reason the reason of the invitation
Invites the given chatContacts to this chat . @param inviteChatTransport the chat transport to use to send the invite @param chatContacts the contacts to invite @param reason the reason of the invitation
public void inviteContacts( ChatTransport inviteChatTransport,
                                Collection<String> chatContacts,
                                String reason)
    {
        ChatSession conferenceChatSession = null;
        if (chatSession instanceof MetaContactChatSession)
        {
            chatContacts.add(inviteChatTransport.getName());
            ConferenceChatManager conferenceChatManager
                = GuiActivator.getUIService().getConferenceChatManager();
            if(inviteChatTransport.getProtocolProvider().
                    getOperationSet(OperationSetMultiUserChat.class) != null)
            {
                ChatRoomWrapper chatRoomWrapper
                    = GuiActivator.getMUCService().createPrivateChatRoom(
                        inviteChatTransport.getProtocolProvider(),
                        chatContacts,
                        reason,
                        false);
                conferenceChatSession
                    = new ConferenceChatSession(this, chatRoomWrapper);
            }
            else if (inviteChatTransport.getProtocolProvider().
                getOperationSet(OperationSetAdHocMultiUserChat.class) != null)
            {
                AdHocChatRoomWrapper chatRoomWrapper
                    = conferenceChatManager.createAdHocChatRoom(
                            inviteChatTransport.getProtocolProvider(),
                            chatContacts,
                            reason);
                conferenceChatSession
                    = new AdHocConferenceChatSession(this, chatRoomWrapper);
            }
            if (conferenceChatSession != null)
                this.setChatSession(conferenceChatSession);
        }
        else
        {
            conferenceChatSession = chatSession;
            for (String contactAddress : chatContacts)
            {
                conferenceChatSession.getCurrentChatTransport()
                    .inviteChatContact(contactAddress, reason);
            }
        }
    }
public void inviteContacts ( ChatTransport inviteChatTransport , Collection < String > chatContacts , String reason ) { ChatSession conferenceChatSession = null ; if ( chatSession instanceof MetaContactChatSession ) { chatContacts . add ( inviteChatTransport . getName ( ) ) ; ConferenceChatManager conferenceChatManager = GuiActivator . getUIService ( ) . getConferenceChatManager ( ) ; if ( inviteChatTransport . getProtocolProvider ( ) . getOperationSet ( OperationSetMultiUserChat . class ) != null ) { ChatRoomWrapper chatRoomWrapper = GuiActivator . getMUCService ( ) . createPrivateChatRoom ( inviteChatTransport . getProtocolProvider ( ) , chatContacts , reason , false ) ; conferenceChatSession = new ConferenceChatSession ( this , chatRoomWrapper ) ; } else if ( inviteChatTransport . getProtocolProvider ( ) . getOperationSet ( OperationSetAdHocMultiUserChat . class ) != null ) { AdHocChatRoomWrapper chatRoomWrapper = conferenceChatManager . createAdHocChatRoom ( inviteChatTransport . getProtocolProvider ( ) , chatContacts , reason ) ; conferenceChatSession = new AdHocConferenceChatSession ( this , chatRoomWrapper ) ; } if ( conferenceChatSession != null ) this . setChatSession ( conferenceChatSession ) ; } else { conferenceChatSession = chatSession ; for ( String contactAddress : chatContacts ) { conferenceChatSession . getCurrentChatTransport ( ) . inviteChatContact ( contactAddress , reason ) ; } } }
Invites the given <tt>chatContacts</tt> to this chat.
Invites the given <tt > chatContacts< / tt > to this chat .
// the chat session is set regarding to which OpSet is used for MUC // We're already in a conference chat.