public class TargetSession extends Object
Currently, a TargetSession can only have one Connection, i.e. MaxConnections=1.
| Constructor and Description |
|---|
TargetSession(TargetServer target,
Connection connection,
org.jscsi.parser.login.ISID initiatorSessionID,
int expectedCommandSequenceNumber,
int statusSequenceNumber)
Constructs a new
TargetSession |
| Modifier and Type | Method and Description |
|---|---|
Connection |
getConnection()
Returns the session's
Connection. |
org.jscsi.parser.login.ISID |
getInitiatorSessionID()
Returns the
ISID used by the initiator to identify this session. |
IStorageModule |
getStorageModule()
Returns the session's
IStorageModule. |
Target |
getTarget()
Returns the session's
Target |
String |
getTargetName() |
TargetServer |
getTargetServer()
Returns the session's
TargetServer. |
short |
getTargetSessionIdentifyingHandle()
Returns the value used by the jSCSI Target to identify this session.
|
boolean |
isNormalSession()
Returns
true if this session is a regular (operational) session, and false if it is s
discovery session. |
void |
setTargetName(String targetName)
Sets the target name and retrieves the target (if it exists) from the TargetServer
|
public TargetSession(TargetServer target, Connection connection, org.jscsi.parser.login.ISID initiatorSessionID, int expectedCommandSequenceNumber, int statusSequenceNumber)
TargetSessionconnection - the session's (first) ConnectioninitiatorSessionID - the ISID specified by the initiatorexpectedCommandSequenceNumber - initialization value of expectedCommandSequenceNumberstatusSequenceNumber - the value expected by the initiator in the next ProtocolDataUnit's
StatSN fieldpublic TargetServer getTargetServer()
TargetServer.TargetServerpublic Connection getConnection()
Connection.Connectionpublic IStorageModule getStorageModule()
IStorageModule.IStorageModulepublic org.jscsi.parser.login.ISID getInitiatorSessionID()
ISID used by the initiator to identify this session.ISID used by the initiator to identify this sessionpublic short getTargetSessionIdentifyingHandle()
public boolean isNormalSession()
true if this session is a regular (operational) session, and false if it is s
discovery session.true if and only if this is not a regular (operational) sessionpublic void setTargetName(String targetName)
targetName - public String getTargetName()
Copyright © 2013 University of Konstanz, Distributed Systems Group. All Rights Reserved.