java.lang.Object
org.codelibs.jcifs.smb.internal.smb1.ServerMessageBlock
org.codelibs.jcifs.smb.internal.smb1.AndXServerMessageBlock
org.codelibs.jcifs.smb.internal.smb1.com.SmbComOpenAndXResponse
- All Implemented Interfaces:
CommonServerMessageBlock,CommonServerMessageBlockRequest,CommonServerMessageBlockResponse,RequestWithPath,SmbBasicFileInfo,Message,Request,Response
SMB1 Open AndX Response message.
This response contains information about the opened file,
including file ID, attributes, size, and access permissions.
-
Field Summary
Fields inherited from class org.codelibs.jcifs.smb.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
ConstructorsConstructorDescriptionSmbComOpenAndXResponse(Configuration config) Constructs an Open AndX response.SmbComOpenAndXResponse(Configuration config, SmbComSeekResponse andxResp) Constructs an Open AndX response with a chained response. -
Method Summary
Modifier and TypeMethodDescriptionfinal intGets the action taken.intGets the file attributes.longGets the file creation time.final intGets the file data size.final intGets the device state.final intgetFid()Gets the file identifier.final intGets the file attributes.final intGets the file type.final intGets the granted access rights.longGets the file last access time.final longGets the file last write time.final intGets the server file identifier.longgetSize()Gets the file size in bytes.protected intreadBytesWireFormat(byte[] buffer, int bufferIndex) Reads the data bytes portion of the SMB message from the wire format.protected intreadParameterWordsWireFormat(byte[] buffer, int bufferIndex) Reads the parameter words portion of the SMB message from the wire format.toString()protected intwriteBytesWireFormat(byte[] dst, int dstIndex) Writes the data bytes portion of the SMB message to the wire format.protected intwriteParameterWordsWireFormat(byte[] dst, int dstIndex) Writes the parameter words portion of the SMB message to the wire format.Methods inherited from class org.codelibs.jcifs.smb.internal.smb1.AndXServerMessageBlock
decode, encode, getAndx, getBatchLimit, getNext, getNextResponse, readAndXWireFormat, writeAndXWireFormatMethods inherited from class org.codelibs.jcifs.smb.internal.smb1.ServerMessageBlock
addFlags2, allowChain, clearReceived, createCancel, equals, error, exception, getByteCount, getCommand, getConfig, getCreditCost, getDigest, getDomain, getErrorCode, getException, getExpiration, getFlags, getFlags2, getFullUNCPath, getGrantedCredits, getLength, getMid, 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, reset, 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
-
Constructor Details
-
SmbComOpenAndXResponse
Constructs an Open AndX response.- Parameters:
config- the configuration
-
SmbComOpenAndXResponse
Constructs an Open AndX response with a chained response.- Parameters:
config- the configurationandxResp- the chained seek response
-
-
Method Details
-
getFid
public final int getFid()Gets the file identifier.- Returns:
- the fid
-
getDataSize
public final int getDataSize()Gets the file data size.- Returns:
- the dataSize
-
getSize
public long getSize()Gets the file size in bytes.- Specified by:
getSizein interfaceSmbBasicFileInfo- Returns:
- file size
- See Also:
-
getGrantedAccess
public final int getGrantedAccess()Gets the granted access rights.- Returns:
- the grantedAccess
-
getFileAttributes
public final int getFileAttributes()Gets the file attributes.- Returns:
- the fileAttributes
-
getAttributes
public int getAttributes()Gets the file attributes.- Specified by:
getAttributesin interfaceSmbBasicFileInfo- Returns:
- file attributes
- See Also:
-
getFileType
public final int getFileType()Gets the file type.- Returns:
- the fileType
-
getDeviceState
public final int getDeviceState()Gets the device state.- Returns:
- the deviceState
-
getAction
public final int getAction()Gets the action taken.- Returns:
- the action
-
getServerFid
public final int getServerFid()Gets the server file identifier.- Returns:
- the serverFid
-
getLastWriteTime
public final long getLastWriteTime()Description copied from interface:SmbBasicFileInfoGets the file last write time.- Specified by:
getLastWriteTimein interfaceSmbBasicFileInfo- Returns:
- the lastWriteTime
-
getCreateTime
public long getCreateTime()Gets the file creation time.- Specified by:
getCreateTimein interfaceSmbBasicFileInfo- Returns:
- file create time
- See Also:
-
getLastAccessTime
public long getLastAccessTime()Gets the file last access time.- Specified by:
getLastAccessTimein interfaceSmbBasicFileInfo- Returns:
- file last access time
- See Also:
-
writeParameterWordsWireFormat
protected int writeParameterWordsWireFormat(byte[] dst, int dstIndex) Description copied from class:ServerMessageBlockWrites the parameter words portion of the SMB message to the wire format.- Specified by:
writeParameterWordsWireFormatin classServerMessageBlock- Parameters:
dst- the destination bufferdstIndex- the starting offset in the buffer- Returns:
- the number of bytes written
-
writeBytesWireFormat
protected int writeBytesWireFormat(byte[] dst, int dstIndex) Description copied from class:ServerMessageBlockWrites the data bytes portion of the SMB message to the wire format.- Specified by:
writeBytesWireFormatin classServerMessageBlock- Parameters:
dst- the destination bufferdstIndex- the starting offset in the buffer- Returns:
- the number of bytes written
-
readParameterWordsWireFormat
protected int readParameterWordsWireFormat(byte[] buffer, int bufferIndex) Description copied from class:ServerMessageBlockReads the parameter words portion of the SMB message from the wire format.- Specified by:
readParameterWordsWireFormatin classServerMessageBlock- Parameters:
buffer- the buffer containing the message databufferIndex- the starting offset in the buffer- Returns:
- the number of bytes read
-
readBytesWireFormat
protected int readBytesWireFormat(byte[] buffer, int bufferIndex) Description copied from class:ServerMessageBlockReads the data bytes portion of the SMB message from the wire format.- Specified by:
readBytesWireFormatin classServerMessageBlock- Parameters:
buffer- the buffer containing the message databufferIndex- the starting offset in the buffer- Returns:
- the number of bytes read
-
toString
- Overrides:
toStringin classAndXServerMessageBlock
-