Package jcifs.internal.smb1.trans
Class SmbComTransactionResponse
- java.lang.Object
-
- jcifs.internal.smb1.ServerMessageBlock
-
- jcifs.internal.smb1.trans.SmbComTransactionResponse
-
- All Implemented Interfaces:
Enumeration<SmbComTransactionResponse>
,CommonServerMessageBlock
,CommonServerMessageBlockRequest
,CommonServerMessageBlockResponse
,RequestWithPath
,Message
,Request
,Response
- Direct Known Subclasses:
NetServerEnum2Response
,NetShareEnumResponse
,SmbComNtTransactionResponse
,Trans2FindFirst2Response
,Trans2GetDfsReferralResponse
,Trans2QueryFSInformationResponse
,Trans2QueryPathInformationResponse
,Trans2SetFileInformationResponse
,TransCallNamedPipeResponse
,TransPeekNamedPipeResponse
,TransTransactNamedPipeResponse
,TransWaitNamedPipeResponse
public abstract class SmbComTransactionResponse extends ServerMessageBlock implements Enumeration<SmbComTransactionResponse>
-
-
Field Summary
Fields Modifier and Type Field Description protected int
bufDataStart
protected int
bufParameterStart
protected int
dataDisplacement
protected int
dataOffset
protected int
parameterCount
protected int
parameterDisplacement
protected int
parameterOffset
protected int
setupCount
protected int
totalDataCount
protected int
totalParameterCount
-
Fields inherited from class jcifs.internal.smb1.ServerMessageBlock
batchLevel, byteCount, digest, errorCode, flags2, headerStart, length, mid, path, pid, SMB_COM_CHECK_DIRECTORY, SMB_COM_CLOSE, SMB_COM_CREATE_DIRECTORY, SMB_COM_DELETE, SMB_COM_DELETE_DIRECTORY, SMB_COM_ECHO, SMB_COM_FIND_CLOSE2, SMB_COM_LOCKING_ANDX, SMB_COM_LOGOFF_ANDX, SMB_COM_MOVE, SMB_COM_NEGOTIATE, SMB_COM_NT_CANCEL, SMB_COM_NT_CREATE_ANDX, SMB_COM_NT_TRANSACT, SMB_COM_NT_TRANSACT_SECONDARY, SMB_COM_OPEN_ANDX, SMB_COM_QUERY_INFORMATION, SMB_COM_READ_ANDX, SMB_COM_RENAME, SMB_COM_SEEK, SMB_COM_SESSION_SETUP_ANDX, SMB_COM_SET_INFORMATION, SMB_COM_TRANSACTION, SMB_COM_TRANSACTION_SECONDARY, SMB_COM_TRANSACTION2, SMB_COM_TREE_CONNECT_ANDX, SMB_COM_TREE_DISCONNECT, SMB_COM_WRITE, SMB_COM_WRITE_ANDX, tid, uid, wordCount
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
SmbComTransactionResponse(Configuration config)
protected
SmbComTransactionResponse(Configuration config, byte command, byte subcommand)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description int
decode(byte[] buffer, int bufferIndex)
Decode message data from the given byte arrayprotected int
getDataCount()
int
getNumEntries()
FileEntry[]
getResults()
int
getStatus()
byte
getSubCommand()
boolean
hasMoreElements()
SmbComTransactionResponse
nextElement()
protected int
readBytesWireFormat(byte[] buffer, int bufferIndex)
protected abstract int
readDataWireFormat(byte[] buffer, int bufferIndex, int len)
protected abstract int
readParametersWireFormat(byte[] buffer, int bufferIndex, int len)
protected int
readParameterWordsWireFormat(byte[] buffer, int bufferIndex)
protected abstract int
readSetupWireFormat(byte[] buffer, int bufferIndex, int len)
byte[]
releaseBuffer()
void
reset()
void
setBuffer(byte[] buffer)
void
setDataCount(int dataCount)
protected void
setNumEntries(int numEntries)
protected void
setResults(FileEntry[] results)
protected void
setStatus(int status)
void
setSubCommand(byte subCommand)
String
toString()
protected int
writeBytesWireFormat(byte[] dst, int dstIndex)
protected abstract int
writeDataWireFormat(byte[] dst, int dstIndex)
protected abstract int
writeParametersWireFormat(byte[] dst, int dstIndex)
protected int
writeParameterWordsWireFormat(byte[] dst, int dstIndex)
protected abstract int
writeSetupWireFormat(byte[] dst, int dstIndex)
-
Methods inherited from class jcifs.internal.smb1.ServerMessageBlock
addFlags2, allowChain, clearReceived, createCancel, encode, equals, error, exception, getByteCount, getCommand, getConfig, getCreditCost, getDigest, getDomain, getErrorCode, getException, getExpiration, getFlags, getFlags2, getFullUNCPath, getGrantedCredits, getLength, getMid, getNext, getNextResponse, getOverrideTimeout, getPath, getPid, getRawPayload, getResponse, getServer, getSignSeq, getTid, getUid, hashCode, ignoreDisconnect, isAsync, isCancel, isError, isExtendedSecurity, isForceUnicode, isReceived, isResolveInDfs, isResponse, isResponseAsync, isRetainPayload, isUseUnicode, isVerifyFailed, prepare, readHeaderWireFormat, readString, readString, readString, readStringLength, received, remFlags2, retainPayload, setCommand, setDigest, setErrorCode, setExpiration, setExtendedSecurity, setFlags, setFlags2, setFullUNCPath, setMid, setOverrideTimeout, setPath, setPid, setRawPayload, setRequestCredits, setResolveInDfs, setResponse, setSessionId, setSignSeq, setTid, setUid, setUseUnicode, size, split, stringWireLength, verifySignature, writeHeaderWireFormat, writeString, writeString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Enumeration
asIterator
-
-
-
-
Field Detail
-
totalParameterCount
protected int totalParameterCount
-
totalDataCount
protected int totalDataCount
-
parameterCount
protected int parameterCount
-
parameterOffset
protected int parameterOffset
-
parameterDisplacement
protected int parameterDisplacement
-
dataOffset
protected int dataOffset
-
dataDisplacement
protected int dataDisplacement
-
setupCount
protected int setupCount
-
bufParameterStart
protected int bufParameterStart
-
bufDataStart
protected int bufDataStart
-
-
Constructor Detail
-
SmbComTransactionResponse
protected SmbComTransactionResponse(Configuration config)
-
SmbComTransactionResponse
protected SmbComTransactionResponse(Configuration config, byte command, byte subcommand)
-
-
Method Detail
-
getDataCount
protected final int getDataCount()
- Returns:
- the dataCount
-
setDataCount
public final void setDataCount(int dataCount)
- Parameters:
dataCount
- the dataCount to set
-
setBuffer
public void setBuffer(byte[] buffer)
- Parameters:
buffer
-
-
releaseBuffer
public byte[] releaseBuffer()
- Returns:
- the txn_buf
-
getSubCommand
public final byte getSubCommand()
- Returns:
- the subCommand
-
setSubCommand
public final void setSubCommand(byte subCommand)
- Parameters:
subCommand
- the subCommand to set
-
getStatus
public final int getStatus()
- Returns:
- the status
-
setStatus
protected final void setStatus(int status)
- Parameters:
status
- the status to set
-
getNumEntries
public final int getNumEntries()
- Returns:
- the numEntries
-
setNumEntries
protected final void setNumEntries(int numEntries)
- Parameters:
numEntries
- the numEntries to set
-
getResults
public final FileEntry[] getResults()
- Returns:
- the results
-
setResults
protected final void setResults(FileEntry[] results)
- Parameters:
results
- the results to set
-
reset
public void reset()
- Specified by:
reset
in interfaceCommonServerMessageBlock
- Specified by:
reset
in interfaceResponse
- Overrides:
reset
in classServerMessageBlock
-
hasMoreElements
public boolean hasMoreElements()
- Specified by:
hasMoreElements
in interfaceEnumeration<SmbComTransactionResponse>
-
nextElement
public SmbComTransactionResponse nextElement()
- Specified by:
nextElement
in interfaceEnumeration<SmbComTransactionResponse>
-
writeParameterWordsWireFormat
protected int writeParameterWordsWireFormat(byte[] dst, int dstIndex)
- Specified by:
writeParameterWordsWireFormat
in classServerMessageBlock
-
writeBytesWireFormat
protected int writeBytesWireFormat(byte[] dst, int dstIndex)
- Specified by:
writeBytesWireFormat
in classServerMessageBlock
-
decode
public int decode(byte[] buffer, int bufferIndex) throws SMBProtocolDecodingException
Decode message data from the given byte array- Specified by:
decode
in interfaceCommonServerMessageBlock
- Overrides:
decode
in classServerMessageBlock
- Returns:
- message length
- Throws:
SMBProtocolDecodingException
- See Also:
ServerMessageBlock.decode(byte[], int)
-
readParameterWordsWireFormat
protected int readParameterWordsWireFormat(byte[] buffer, int bufferIndex)
- Specified by:
readParameterWordsWireFormat
in classServerMessageBlock
-
readBytesWireFormat
protected int readBytesWireFormat(byte[] buffer, int bufferIndex) throws SMBProtocolDecodingException
- Specified by:
readBytesWireFormat
in classServerMessageBlock
- Throws:
SMBProtocolDecodingException
-
writeSetupWireFormat
protected abstract int writeSetupWireFormat(byte[] dst, int dstIndex)
-
writeParametersWireFormat
protected abstract int writeParametersWireFormat(byte[] dst, int dstIndex)
-
writeDataWireFormat
protected abstract int writeDataWireFormat(byte[] dst, int dstIndex)
-
readSetupWireFormat
protected abstract int readSetupWireFormat(byte[] buffer, int bufferIndex, int len)
-
readParametersWireFormat
protected abstract int readParametersWireFormat(byte[] buffer, int bufferIndex, int len) throws SMBProtocolDecodingException
- Throws:
SMBProtocolDecodingException
-
readDataWireFormat
protected abstract int readDataWireFormat(byte[] buffer, int bufferIndex, int len) throws SMBProtocolDecodingException
- Throws:
SMBProtocolDecodingException
-
toString
public String toString()
- Overrides:
toString
in classServerMessageBlock
-
-