Interface RfServerSessionActivity
-
public interface RfServerSessionActivityAn RfServerSessionActivity represents an offline charging session for accounting servers.
A single RfServerSessionActivity will be created for the Diameter session. All requests received for the session will be fired as events on the same RfServerSessionActivity.
- Author:
- OpenCloud
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description AccountingAnswercreateRfAccountingAnswer()Create an Accounting-Answer with the Acct-Application-Id set to 3.AccountingAnswercreateRfAccountingAnswer(AccountingRequest acr)Create an Accounting-Answer with some AVPs populated from the provided Accounting-Request.voidendActivity()End this activity.longgetLastReceiveTime()Returns the timestamp for the last message received on this activity, or 0 if no timestamp is available.longgetLastSendTime()Returns the timestamp for the last message sent on this activity, or 0 if no timestamp is available.StringgetSessionId()Returns the session ID of this session.voidsendAccountingAnswer(AccountingAnswer accountingAnswer)Send an Accounting Answer.
-
-
-
Method Detail
-
sendAccountingAnswer
void sendAccountingAnswer(AccountingAnswer accountingAnswer) throws IllegalArgumentException, SendException
Send an Accounting Answer.- Parameters:
accountingAnswer- answer message to send- Throws:
SendException- if the message could not be sentIllegalArgumentException- if accountingAnswer is missing any required AVPs
-
createRfAccountingAnswer
AccountingAnswer createRfAccountingAnswer()
Create an Accounting-Answer with the Acct-Application-Id set to 3.- Returns:
- an Accounting-Answer
-
createRfAccountingAnswer
AccountingAnswer createRfAccountingAnswer(AccountingRequest acr)
Create an Accounting-Answer with some AVPs populated from the provided Accounting-Request.The ACR will contain the AVPs specified in
createRfAccountingAnswer()and the following AVPs from the Accounting-Request:- Accounting-Record-Type
- Accounting-Record-Number
- Parameters:
acr- Accounting-Request to copy AVPs from- Returns:
- an Accounting-Answer
-
getSessionId
String getSessionId()
Returns the session ID of this session.
-
endActivity
void endActivity() throws IllegalStateExceptionEnd this activity.- Throws:
IllegalStateException- if this activity represents a stateful session that is not idle
-
getLastSendTime
long getLastSendTime()
Returns the timestamp for the last message sent on this activity, or 0 if no timestamp is available.
-
getLastReceiveTime
long getLastReceiveTime()
Returns the timestamp for the last message received on this activity, or 0 if no timestamp is available.
-
-