org.asteriskjava.manager.event.ParkedCallEvent Maven / Gradle / Ivy
Show all versions of asterisk-java Show documentation
/*
* Copyright 2004-2006 Stefan Reuter
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
package org.asteriskjava.manager.event;
/**
* A ParkedCallEvent is triggered when a channel is parked (in this case no
* action id is set) and in response to a ParkedCallsAction.
* It is implemented in res/res_features.c
*
* @see org.asteriskjava.manager.action.ParkedCallsAction
* @author srt
* @version $Id$
*/
public class ParkedCallEvent extends AbstractParkedCallEvent
{
/**
* Serializable version identifier
*/
private static final long serialVersionUID = 0L;
private String from;
private Integer timeout;
/**
* @param source
*/
public ParkedCallEvent(Object source)
{
super(source);
}
/**
* Returns the name of the channel that parked the call.
*/
public String getFrom()
{
return from;
}
/**
* Sets the name of the channel that parked the call.
*/
public void setFrom(String from)
{
this.from = from;
}
/**
* Returns the number of seconds this call will be parked.
* This corresponds to the parkingtime
option in
* features.conf
.
*/
public Integer getTimeout()
{
return timeout;
}
/**
* Sets the number of seconds this call will be parked.
*/
public void setTimeout(Integer timeout)
{
this.timeout = timeout;
}
/**
* Sets the unique id of the parked channel as a
* workaround for a typo in asterisk manager event.
*/
public void setUnqiueId(String unqiueId)
{
setUniqueId(unqiueId);
}
}