net.sf.jradius.session
Class RadiusSession
java.lang.Object
net.sf.jradius.session.RadiusSession
- All Implemented Interfaces:
- java.io.Serializable, JRadiusSession
public class RadiusSession
- extends java.lang.Object
- implements JRadiusSession, java.io.Serializable
The Default Radius Session Base Class.
- Author:
- David Bird
- See Also:
- Serialized Form
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
serialVersionUID
public static final long serialVersionUID
- See Also:
- Constant Field Values
RadiusSession
public RadiusSession()
RadiusSession
public RadiusSession(java.lang.String session)
getLogEntry
public RadiusLogEntry getLogEntry(JRadiusEvent event,
java.lang.String key)
- Specified by:
getLogEntry in interface JRadiusSession
getLogEntry
public RadiusLogEntry getLogEntry(JRadiusRequest request)
throws RadiusException
- Specified by:
getLogEntry in interface JRadiusSession
- Throws:
RadiusException
addLogMessage
public void addLogMessage(JRadiusRequest request,
java.lang.String message)
throws RadiusException
- Specified by:
addLogMessage in interface JRadiusSession
- Throws:
RadiusException
commitLogEntries
public void commitLogEntries(int result)
- Specified by:
commitLogEntries in interface JRadiusSession
commitLogEntry
public void commitLogEntry(RadiusLogEntry entry,
int result)
- Specified by:
commitLogEntry in interface JRadiusSession
onPreProcessing
public boolean onPreProcessing(JRadiusRequest request)
throws RadiusException
- Specified by:
onPreProcessing in interface JRadiusSession
- Throws:
RadiusException
onPostProcessing
public void onPostProcessing(JRadiusRequest request)
throws RadiusException
- Specified by:
onPostProcessing in interface JRadiusSession
- Throws:
RadiusException
onAuthorization
public void onAuthorization(JRadiusRequest request)
throws RadiusException
- Specified by:
onAuthorization in interface JRadiusSession
- Throws:
RadiusException
onPostAuthentication
public void onPostAuthentication(JRadiusRequest request)
throws RadiusException
- Specified by:
onPostAuthentication in interface JRadiusSession
- Throws:
RadiusException
initSession
public void initSession(JRadiusRequest request)
throws RadiusException
- This method is kicked off by the InitSessionHandler after a new
PPRadiusSession has been created.
- Specified by:
initSession in interface JRadiusSession
- Parameters:
request - The JRadiusRequest
- Throws:
RadiusException
onAccounting
public void onAccounting(JRadiusRequest request)
throws RadiusException
- Description copied from interface:
JRadiusSession
- Updates the session with attributes from the accounting request. This method
is fired off during post processing.
- Specified by:
onAccounting in interface JRadiusSession
- Throws:
RadiusException
ensureSessionState
public void ensureSessionState(JRadiusRequest request,
int state)
throws RadiusException
- Specified by:
ensureSessionState in interface JRadiusSession
- Throws:
RadiusException
onNoAccountingStatusType
public boolean onNoAccountingStatusType(JRadiusRequest request)
throws RadiusException
- Specified by:
onNoAccountingStatusType in interface JRadiusSession
- Throws:
RadiusException
addAccessAcceptAttribtues
public void addAccessAcceptAttribtues(AttributeList attrs)
- Specified by:
addAccessAcceptAttribtues in interface JRadiusSession
getUsername
public java.lang.String getUsername()
- Specified by:
getUsername in interface JRadiusSession
- Returns:
- Returns the username.
setUsername
public void setUsername(java.lang.String username)
- Specified by:
setUsername in interface JRadiusSession
- Parameters:
username - The username to set.
getRealm
public java.lang.String getRealm()
- Specified by:
getRealm in interface JRadiusSession
- Returns:
- Returns the realm.
setRealm
public void setRealm(java.lang.String realm)
- Specified by:
setRealm in interface JRadiusSession
- Parameters:
realm - The realm to set.
getPassword
public java.lang.String getPassword()
- Specified by:
getPassword in interface JRadiusSession
- Returns:
- Returns the password.
setPassword
public void setPassword(java.lang.String password)
- Specified by:
setPassword in interface JRadiusSession
- Parameters:
password - The password to set.
getSessionKey
public java.lang.String getSessionKey()
- Specified by:
getSessionKey in interface JRadiusSession
- Returns:
- Returns the sessionKey.
setSessionKey
public void setSessionKey(java.lang.String sessionKey)
- Specified by:
setSessionKey in interface JRadiusSession
- Parameters:
sessionKey - The sessionKey to set.
getSessionId
public java.lang.String getSessionId()
- Specified by:
getSessionId in interface JRadiusSession
- Returns:
- Returns the sessionId.
setSessionId
public void setSessionId(java.lang.String sessionId)
- Specified by:
setSessionId in interface JRadiusSession
- Parameters:
sessionId - The sessionId to set.
getServiceType
public java.lang.Long getServiceType()
- Specified by:
getServiceType in interface JRadiusSession
- Returns:
- Returns the serviceType.
setServiceType
public void setServiceType(java.lang.Long serviceType)
- Specified by:
setServiceType in interface JRadiusSession
- Parameters:
serviceType - The serviceType to set.
getIdleTimeout
public java.lang.Long getIdleTimeout()
- Specified by:
getIdleTimeout in interface JRadiusSession
- Returns:
- Returns the idleTimeout.
setIdleTimeout
public void setIdleTimeout(java.lang.Long idleTimeout)
- Specified by:
setIdleTimeout in interface JRadiusSession
- Parameters:
idleTimeout - The idleTimeout to set.
getInterimInterval
public java.lang.Long getInterimInterval()
- Specified by:
getInterimInterval in interface JRadiusSession
- Returns:
- Returns the interimInterval.
setInterimInterval
public void setInterimInterval(java.lang.Long interimInterval)
- Specified by:
setInterimInterval in interface JRadiusSession
- Parameters:
interimInterval - The interimInterval to set.
getSessionTimeout
public java.lang.Long getSessionTimeout()
- Specified by:
getSessionTimeout in interface JRadiusSession
- Returns:
- Returns the sessionTimeout.
setSessionTimeout
public void setSessionTimeout(java.lang.Long sessionTimeout)
- Specified by:
setSessionTimeout in interface JRadiusSession
- Parameters:
sessionTimeout - The sessionTimeout to set.
getSessionTime
public java.lang.Long getSessionTime()
- Specified by:
getSessionTime in interface JRadiusSession
- Returns:
- Returns the sessionTime.
setSessionTime
public void setSessionTime(java.lang.Long sessionTime)
- Specified by:
setSessionTime in interface JRadiusSession
- Parameters:
sessionTime - The sessionTime to set.
getStartTime
public java.util.Date getStartTime()
- Specified by:
getStartTime in interface JRadiusSession
- Returns:
- Returns the startTime.
setStartTime
public void setStartTime(java.util.Date startTime)
- Specified by:
setStartTime in interface JRadiusSession
- Parameters:
startTime - The startTime to set.
getLastInterimTime
public java.util.Date getLastInterimTime()
- Specified by:
getLastInterimTime in interface JRadiusSession
- Returns:
- Returns the lastInterimTime.
setLastInterimTime
public void setLastInterimTime(java.util.Date lastInterimTime)
- Specified by:
setLastInterimTime in interface JRadiusSession
- Parameters:
lastInterimTime - The lastInterimTime to set.
getStopTime
public java.util.Date getStopTime()
- Specified by:
getStopTime in interface JRadiusSession
- Returns:
- Returns the stopTime.
setStopTime
public void setStopTime(java.util.Date stopTime)
- Specified by:
setStopTime in interface JRadiusSession
- Parameters:
stopTime - The stopTime to set.
getGigaWordsIn
public java.lang.Long getGigaWordsIn()
- Specified by:
getGigaWordsIn in interface JRadiusSession
- Returns:
- Returns the gigaWordsIn.
setGigaWordsIn
public void setGigaWordsIn(java.lang.Long gigaWordsIn)
- Specified by:
setGigaWordsIn in interface JRadiusSession
- Parameters:
gigaWordsIn - The gigaWordsIn to set.
getGigaWordsOut
public java.lang.Long getGigaWordsOut()
- Specified by:
getGigaWordsOut in interface JRadiusSession
- Returns:
- Returns the gigaWordsOut.
setGigaWordsOut
public void setGigaWordsOut(java.lang.Long gigaWordsOut)
- Specified by:
setGigaWordsOut in interface JRadiusSession
- Parameters:
gigaWordsOut - The gigaWordsOut to set.
getOctetsIn
public java.lang.Long getOctetsIn()
- Specified by:
getOctetsIn in interface JRadiusSession
- Returns:
- Returns the octetsIn.
setOctetsIn
public void setOctetsIn(java.lang.Long octetsIn)
- Specified by:
setOctetsIn in interface JRadiusSession
- Parameters:
octetsIn - The octetsIn to set.
getOctetsOut
public java.lang.Long getOctetsOut()
- Specified by:
getOctetsOut in interface JRadiusSession
- Returns:
- Returns the octetsOut.
setOctetsOut
public void setOctetsOut(java.lang.Long octetsOut)
- Specified by:
setOctetsOut in interface JRadiusSession
- Parameters:
octetsOut - The octetsOut to set.
getTotalOctetsIn
public java.lang.Long getTotalOctetsIn()
- Specified by:
getTotalOctetsIn in interface JRadiusSession
getTotalOctetsOut
public java.lang.Long getTotalOctetsOut()
- Specified by:
getTotalOctetsOut in interface JRadiusSession
getPacketsIn
public java.lang.Long getPacketsIn()
- Specified by:
getPacketsIn in interface JRadiusSession
- Returns:
- Returns the packetsIn.
setPacketsIn
public void setPacketsIn(java.lang.Long packetsIn)
- Specified by:
setPacketsIn in interface JRadiusSession
- Parameters:
packetsIn - The packetsIn to set.
getPacketsOut
public java.lang.Long getPacketsOut()
- Specified by:
getPacketsOut in interface JRadiusSession
- Returns:
- Returns the packetsOut.
setPacketsOut
public void setPacketsOut(java.lang.Long packetsOut)
- Specified by:
setPacketsOut in interface JRadiusSession
- Parameters:
packetsOut - The packetsOut to set.
getTerminateCause
public java.lang.Long getTerminateCause()
- Specified by:
getTerminateCause in interface JRadiusSession
- Returns:
- Returns the terminateCause.
setTerminateCause
public void setTerminateCause(java.lang.Long terminateCause)
- Specified by:
setTerminateCause in interface JRadiusSession
- Parameters:
terminateCause - The terminateCause to set.
getRadiusClass
public byte[] getRadiusClass()
- Specified by:
getRadiusClass in interface JRadiusSession
- Returns:
- Returns the radiusClass.
setRadiusClass
public void setRadiusClass(byte[] radiusClass)
- Specified by:
setRadiusClass in interface JRadiusSession
- Parameters:
radiusClass - The radiusClass to set.
getSessionState
public int getSessionState()
- Specified by:
getSessionState in interface JRadiusSession
- Returns:
- Returns the sessionState.
setSessionState
public void setSessionState(int sessionState)
- Specified by:
setSessionState in interface JRadiusSession
- Parameters:
sessionState - The sessionState to set.
getLocationCity
public java.lang.String getLocationCity()
- Specified by:
getLocationCity in interface JRadiusSession
- Returns:
- Returns the locationCity.
setLocationCity
public void setLocationCity(java.lang.String locationCity)
- Specified by:
setLocationCity in interface JRadiusSession
- Parameters:
locationCity - The locationCity to set.
getLocationCountryCode
public java.lang.String getLocationCountryCode()
- Specified by:
getLocationCountryCode in interface JRadiusSession
- Returns:
- Returns the locationCountryCode.
setLocationCountryCode
public void setLocationCountryCode(java.lang.String locationCountryCode)
- Specified by:
setLocationCountryCode in interface JRadiusSession
- Parameters:
locationCountryCode - The locationCountryCode to set.
getLocationID
public java.lang.String getLocationID()
- Specified by:
getLocationID in interface JRadiusSession
- Returns:
- Returns the locationID.
setLocationID
public void setLocationID(java.lang.String locationID)
- Specified by:
setLocationID in interface JRadiusSession
- Parameters:
locationID - The locationID to set.
getLocationType
public java.lang.String getLocationType()
- Specified by:
getLocationType in interface JRadiusSession
- Returns:
- Returns the locationType.
setLocationType
public void setLocationType(java.lang.String locationType)
- Specified by:
setLocationType in interface JRadiusSession
- Parameters:
locationType - The locationType to set.
getLocationName
public java.lang.String getLocationName()
- Specified by:
getLocationName in interface JRadiusSession
- Returns:
- Returns the locationName.
setLocationName
public void setLocationName(java.lang.String locationName)
- Specified by:
setLocationName in interface JRadiusSession
- Parameters:
locationName - The locationName to set.
getLocationStateProvince
public java.lang.String getLocationStateProvince()
- Specified by:
getLocationStateProvince in interface JRadiusSession
- Returns:
- Returns the locationStateProvince.
setLocationStateProvince
public void setLocationStateProvince(java.lang.String locationStateProvince)
- Specified by:
setLocationStateProvince in interface JRadiusSession
- Parameters:
locationStateProvince - The locationStateProvince to set.
getPaymentType
public java.lang.String getPaymentType()
- Specified by:
getPaymentType in interface JRadiusSession
- Returns:
- Returns the paymentType.
setPaymentType
public void setPaymentType(java.lang.String paymentType)
- Specified by:
setPaymentType in interface JRadiusSession
- Parameters:
paymentType - The paymentType to set.
getServiceClass
public java.lang.String getServiceClass()
- Specified by:
getServiceClass in interface JRadiusSession
- Returns:
- Returns the serviceClass.
setServiceClass
public void setServiceClass(java.lang.String serviceClass)
- Specified by:
setServiceClass in interface JRadiusSession
- Parameters:
serviceClass - The serviceClass to set.
getServiceName
public java.lang.String getServiceName()
- Specified by:
getServiceName in interface JRadiusSession
- Returns:
- Returns the serviceName.
setServiceName
public void setServiceName(java.lang.String serviceName)
- Specified by:
setServiceName in interface JRadiusSession
- Parameters:
serviceName - The serviceName to set.
getProxyToRealm
public java.lang.String getProxyToRealm()
- Specified by:
getProxyToRealm in interface JRadiusSession
- Returns:
- Returns the proxyToRealm.
setProxyToRealm
public void setProxyToRealm(java.lang.String proxyToRealm)
- Specified by:
setProxyToRealm in interface JRadiusSession
- Parameters:
proxyToRealm - The proxyToRealm to set.
isSecured
public boolean isSecured()
- Specified by:
isSecured in interface JRadiusSession
- Returns:
- Returns the secured.
setSecured
public void setSecured(boolean secured)
- Specified by:
setSecured in interface JRadiusSession
- Parameters:
secured - The secured to set.
getCalledStationId
public java.lang.String getCalledStationId()
- Specified by:
getCalledStationId in interface JRadiusSession
- Returns:
- Returns the calledStation.
setCalledStationId
public void setCalledStationId(java.lang.String calledStation)
- Specified by:
setCalledStationId in interface JRadiusSession
- Parameters:
calledStation - The calledStation to set.
getCallingStationId
public java.lang.String getCallingStationId()
- Specified by:
getCallingStationId in interface JRadiusSession
- Returns:
- Returns the callingStation.
setCallingStationId
public void setCallingStationId(java.lang.String callingStation)
- Specified by:
setCallingStationId in interface JRadiusSession
- Parameters:
callingStation - The callingStation to set.
getConnectInfo
public java.lang.String getConnectInfo()
- Specified by:
getConnectInfo in interface JRadiusSession
- Returns:
- Returns the connectInfo.
setConnectInfo
public void setConnectInfo(java.lang.String connectInfo)
- Specified by:
setConnectInfo in interface JRadiusSession
- Parameters:
connectInfo - The connectInfo to set.
getClientIPAddress
public java.lang.String getClientIPAddress()
- Specified by:
getClientIPAddress in interface JRadiusSession
- Returns:
- Returns the clientIP.
getFramedIPAddress
public java.lang.String getFramedIPAddress()
- Specified by:
getFramedIPAddress in interface JRadiusSession
- Returns:
- Returns the framedIPAddress.
setFramedIPAddress
public void setFramedIPAddress(java.lang.String framedIPAddress)
- Specified by:
setFramedIPAddress in interface JRadiusSession
- Parameters:
framedIPAddress - The framedIPAddress to set.
setClientIPAddress
public void setClientIPAddress(java.lang.String clientIP)
- Specified by:
setClientIPAddress in interface JRadiusSession
- Parameters:
clientIP - The clientIP to set.
getNasIdentifier
public java.lang.String getNasIdentifier()
- Specified by:
getNasIdentifier in interface JRadiusSession
- Returns:
- Returns the nasID.
setNasIdentifier
public void setNasIdentifier(java.lang.String nasID)
- Specified by:
setNasIdentifier in interface JRadiusSession
- Parameters:
nasID - The nasID to set.
getNasIPAddress
public java.lang.String getNasIPAddress()
- Specified by:
getNasIPAddress in interface JRadiusSession
- Returns:
- Returns the nasIP.
setNasIPAddress
public void setNasIPAddress(java.lang.String nasIP)
- Specified by:
setNasIPAddress in interface JRadiusSession
- Parameters:
nasIP - The nasIP to set.
getMaxBandwidthDown
public java.lang.Long getMaxBandwidthDown()
- Specified by:
getMaxBandwidthDown in interface JRadiusSession
setMaxBandwidthDown
public void setMaxBandwidthDown(java.lang.Long maxBandwidthDown)
- Specified by:
setMaxBandwidthDown in interface JRadiusSession
getMaxBandwidthUp
public java.lang.Long getMaxBandwidthUp()
- Specified by:
getMaxBandwidthUp in interface JRadiusSession
setMaxBandwidthUp
public void setMaxBandwidthUp(java.lang.Long maxBandwidthUp)
- Specified by:
setMaxBandwidthUp in interface JRadiusSession
getMinBandwidthDown
public java.lang.Long getMinBandwidthDown()
- Specified by:
getMinBandwidthDown in interface JRadiusSession
setMinBandwidthDown
public void setMinBandwidthDown(java.lang.Long minBandwidthDown)
- Specified by:
setMinBandwidthDown in interface JRadiusSession
getMinBandwidthUp
public java.lang.Long getMinBandwidthUp()
- Specified by:
getMinBandwidthUp in interface JRadiusSession
- Returns:
- Returns the minBandwidthUp.
setMinBandwidthUp
public void setMinBandwidthUp(java.lang.Long minBandwidthUp)
- Specified by:
setMinBandwidthUp in interface JRadiusSession
- Parameters:
minBandwidthUp - the minBandwidth to set.
getTimeStamp
public long getTimeStamp()
- Specified by:
getTimeStamp in interface JRadiusSession
- Returns:
- Returns the timeStamp.
setTimeStamp
public void setTimeStamp(long timeStamp)
- Specified by:
setTimeStamp in interface JRadiusSession
- Parameters:
timeStamp - The timeStamp to set.
isNewSession
public boolean isNewSession()
- Specified by:
isNewSession in interface JRadiusSession
- Returns:
- Returns the newSession.
setNewSession
public void setNewSession(boolean newSession)
- Specified by:
setNewSession in interface JRadiusSession
- Parameters:
newSession - The newSession to set.
getJRadiusKey
public java.lang.String getJRadiusKey()
- Specified by:
getJRadiusKey in interface JRadiusSession
setJRadiusKey
public void setJRadiusKey(java.lang.String jRadiusKey)
- Specified by:
setJRadiusKey in interface JRadiusSession
getLastRadiusRequest
public JRadiusRequest getLastRadiusRequest()
- Specified by:
getLastRadiusRequest in interface JRadiusSession
setLastRadiusRequest
public void setLastRadiusRequest(JRadiusRequest lastRadiusRequest)
- Specified by:
setLastRadiusRequest in interface JRadiusSession
getMaxOctetsDown
public java.lang.Long getMaxOctetsDown()
- Specified by:
getMaxOctetsDown in interface JRadiusSession
setMaxOctetsDown
public void setMaxOctetsDown(java.lang.Long maxOctetsDown)
- Specified by:
setMaxOctetsDown in interface JRadiusSession
getMaxOctetsUp
public java.lang.Long getMaxOctetsUp()
- Specified by:
getMaxOctetsUp in interface JRadiusSession
setMaxOctetsUp
public void setMaxOctetsUp(java.lang.Long maxOctetsUp)
- Specified by:
setMaxOctetsUp in interface JRadiusSession
getMaxOctetsTotal
public java.lang.Long getMaxOctetsTotal()
- Specified by:
getMaxOctetsTotal in interface JRadiusSession
setMaxOctetsTotal
public void setMaxOctetsTotal(java.lang.Long maxOctetsTotal)
- Specified by:
setMaxOctetsTotal in interface JRadiusSession
getNasType
public java.lang.String getNasType()
- Specified by:
getNasType in interface JRadiusSession
setNasType
public void setNasType(java.lang.String nasType)
- Specified by:
setNasType in interface JRadiusSession
getRedirectURL
public java.lang.String getRedirectURL()
- Specified by:
getRedirectURL in interface JRadiusSession
setRedirectURL
public void setRedirectURL(java.lang.String redirectURL)
- Specified by:
setRedirectURL in interface JRadiusSession
lock
public void lock()
unlock
public void unlock()
toString
public java.lang.String toString()
- Specified by:
toString in interface JRadiusSession- Overrides:
toString in class java.lang.Object
Copyright © 2006 The JRadius Project, All Rights Reserved.