/*
* Jitsi, the OpenSource Java VoIP and Instant Messaging client.
*
* Distributable under LGPL license. See terms of license at gnu.org.
*/
package net.java.sip.communicator.service.protocol.event;
import net.java.sip.communicator.service.protocol.*;
/**
* The event that occurs when an ad-hoc chat room has been created.
*
* @author Valentin Martinet
*/
public class AdHocChatRoomCreatedEvent
{
/**
* The ad-hoc room that has been created.
*/
private AdHocChatRoom adHocChatRoom;
/**
* The Contact who created the ad-hoc room.
*/
private Contact by;
/**
* Initializes an AdHocChatRoomCreatedEvent with the creator (
* by) and the ad-hoc room adHocChatRoom.
*
* @param adHocChatRoom the AdHocChatRoom
* @param by the Contact who created this ad-hoc room
*/
public AdHocChatRoomCreatedEvent(AdHocChatRoom adHocChatRoom, Contact by)
{
this.adHocChatRoom = adHocChatRoom;
this.by = by;
}
/**
* Returns the Contact who created the room.
*
* @return Contact
*/
public Contact getBy()
{
return this.by;
}
/**
* Returns the ad-hoc room concerned by this event.
*
* @return AdHocChatRoom
*/
public AdHocChatRoom getAdHocCreatedRoom()
{
return this.adHocChatRoom;
}
}