Class SmbShare
java.lang.Object
java.net.URLConnection
jcifs.smb.SmbFile
org.springframework.integration.smb.session.SmbShare
- All Implemented Interfaces:
- AutoCloseable,- jcifs.SmbConstants,- jcifs.SmbResource
public class SmbShare
extends jcifs.smb.SmbFile
The 
SmbFile extension to  represent an SMB share directory.- Since:
- 6.0
- Author:
- Markus Spann, Gregory Bragg, Adam Jones, Artem Bilan, Christian Tzolov
- 
Field SummaryFields inherited from class jcifs.smb.SmbFileATTR_GET_MASK, ATTR_SET_MASK, DEFAULT_ATTR_EXPIRATION_PERIOD, fileLocator, HASH_DOT, HASH_DOT_DOTFields inherited from class java.net.URLConnectionallowUserInteraction, connected, doInput, doOutput, ifModifiedSince, url, useCachesFields inherited from interface jcifs.SmbConstantsATTR_ARCHIVE, ATTR_COMPRESSED, ATTR_DIRECTORY, ATTR_HIDDEN, ATTR_NORMAL, ATTR_READONLY, ATTR_SYSTEM, ATTR_TEMPORARY, ATTR_VOLUME, CAP_DFS, CAP_EXTENDED_SECURITY, CAP_LARGE_FILES, CAP_LARGE_READX, CAP_LARGE_WRITEX, CAP_LEVEL_II_OPLOCKS, CAP_LOCK_AND_READ, CAP_MPX_MODE, CAP_NONE, CAP_NT_FIND, CAP_NT_SMBS, CAP_RAW_MODE, CAP_RPC_REMOTE_APIS, CAP_STATUS32, CAP_UNICODE, CMD_OFFSET, DEFAULT_CONN_TIMEOUT, DEFAULT_MAX_MPX_COUNT, DEFAULT_NOTIFY_BUF_SIZE, DEFAULT_OEM_ENCODING, DEFAULT_PORT, DEFAULT_RCV_BUF_SIZE, DEFAULT_RESPONSE_TIMEOUT, DEFAULT_SHARING, DEFAULT_SND_BUF_SIZE, DEFAULT_SO_TIMEOUT, DEFAULT_SSN_LIMIT, DELETE, ERROR_CODE_OFFSET, FILE_APPEND_DATA, FILE_DELETE, FILE_EXECUTE, FILE_NO_SHARE, FILE_READ_ATTRIBUTES, FILE_READ_DATA, FILE_READ_EA, FILE_SHARE_DELETE, FILE_SHARE_READ, FILE_SHARE_WRITE, FILE_WRITE_ATTRIBUTES, FILE_WRITE_DATA, FILE_WRITE_EA, FLAGS_COPY_SOURCE_MODE_ASCII, FLAGS_COPY_TARGET_MODE_ASCII, FLAGS_LOCK_AND_READ_WRITE_AND_UNLOCK, FLAGS_NONE, FLAGS_NOTIFY_OF_MODIFY_ACTION, FLAGS_OFFSET, FLAGS_OPLOCK_REQUESTED_OR_GRANTED, FLAGS_PATH_NAMES_CANONICALIZED, FLAGS_PATH_NAMES_CASELESS, FLAGS_RECEIVE_BUFFER_POSTED, FLAGS_RESPONSE, FLAGS_TARGET_MUST_BE_DIRECTORY, FLAGS_TARGET_MUST_BE_FILE, FLAGS_TREE_COPY, FLAGS_VERIFY_ALL_WRITES, FLAGS2_EXTENDED_ATTRIBUTES, FLAGS2_EXTENDED_SECURITY_NEGOTIATION, FLAGS2_LONG_FILENAMES, FLAGS2_NONE, FLAGS2_PERMIT_READ_IF_EXECUTE_PERM, FLAGS2_RESOLVE_PATHS_IN_DFS, FLAGS2_SECURITY_REQUIRE_SIGNATURES, FLAGS2_SECURITY_SIGNATURES, FLAGS2_STATUS32, FLAGS2_UNICODE, FOREVER, GENERIC_ALL, GENERIC_EXECUTE, GENERIC_READ, GENERIC_WRITE, MILLISECONDS_BETWEEN_1970_AND_1601, O_APPEND, O_CREAT, O_EXCL, O_RDONLY, O_RDWR, O_TRUNC, O_WRONLY, OPEN_FUNCTION_FAIL_IF_EXISTS, OPEN_FUNCTION_OVERWRITE_IF_EXISTS, READ_CONTROL, SECURITY_SHARE, SECURITY_USER, SIGNATURE_OFFSET, SMB1_HEADER_LENGTH, SYNCHRONIZE, TID_OFFSET, TYPE_COMM, TYPE_FILESYSTEM, TYPE_NAMED_PIPE, TYPE_PRINTER, TYPE_SERVER, TYPE_SHARE, TYPE_WORKGROUP, WRITE_DAC, WRITE_OWNER
- 
Constructor SummaryConstructorsConstructorDescriptionInitializes the jCIFS library with default properties.SmbShare(SmbConfig _smbConfig, Properties _props) Initializes the jCIFS library with custom properties such as 'jcifs.smb.client.minVersion' and 'jcifs.smb.client.maxVersion' for setting the minimum/maximum SMB supported versions.Initializes the jCIFS library with a custom client context configuration.
- 
Method SummaryMethods inherited from class jcifs.smb.SmbFilecanRead, canWrite, children, children, children, children, connect, copyTo, createNewFile, createTime, customizeCreate, delete, exists, fileIndex, getAttributes, getCanonicalPath, getCanonicalUncPath, getContentLength, getContentLengthLong, getContext, getDate, getDfsPath, getDiskFreeSpace, getInputStream, getLastModified, getLocator, getName, getOutputStream, getOwnerGroup, getOwnerGroup, getOwnerUser, getOwnerUser, getParent, getPath, getSecurity, getSecurity, getServer, getServerWithDfs, getShare, getShareSecurity, getTransportContext, getTreeHandle, getType, getUncPath, isDirectory, isFile, isHidden, lastAccess, lastModified, length, list, list, listFiles, listFiles, listFiles, listFiles, mkdir, mkdirs, openInputStream, openInputStream, openInputStream, openOutputStream, openOutputStream, openOutputStream, openOutputStream, openRandomAccess, openRandomAccess, renameTo, renameTo, resolve, setAttributes, setCreateTime, setFileTimes, setLastAccess, setLastModified, setNonPooled, setReadOnly, setReadWrite, toString, toURL, watch, withOpen, withOpen, withOpenMethods inherited from class java.net.URLConnectionaddRequestProperty, getAllowUserInteraction, getConnectTimeout, getContent, getContent, getContentEncoding, getContentType, getDefaultAllowUserInteraction, getDefaultRequestProperty, getDefaultUseCaches, getDefaultUseCaches, getDoInput, getDoOutput, getExpiration, getFileNameMap, getHeaderField, getHeaderField, getHeaderFieldDate, getHeaderFieldInt, getHeaderFieldKey, getHeaderFieldLong, getHeaderFields, getIfModifiedSince, getPermission, getReadTimeout, getRequestProperties, getRequestProperty, getURL, getUseCaches, guessContentTypeFromName, guessContentTypeFromStream, setAllowUserInteraction, setConnectTimeout, setContentHandlerFactory, setDefaultAllowUserInteraction, setDefaultRequestProperty, setDefaultUseCaches, setDefaultUseCaches, setDoInput, setDoOutput, setFileNameMap, setIfModifiedSince, setReadTimeout, setRequestProperty, setUseCaches
- 
Constructor Details- 
SmbShareInitializes the jCIFS library with default properties.- Parameters:
- _smbConfig- the SMB share configuration
- Throws:
- IOException- if an invalid SMB URL was constructed by jCIFS
 
- 
SmbShareInitializes the jCIFS library with a custom client context configuration.- Parameters:
- _smbConfig- the SMB share configuration
- _context- that holds the client configuration, shared services as well as the active credentials
- Throws:
- IOException- if an invalid SMB URL was constructed by jCIFS
 
- 
SmbShareInitializes the jCIFS library with custom properties such as 'jcifs.smb.client.minVersion' and 'jcifs.smb.client.maxVersion' for setting the minimum/maximum SMB supported versions.- Parameters:
- _smbConfig- the SMB share configuration
- _props- the custom property set for jCIFS to initialize
- Throws:
- IOException- if an invalid property was set or an invalid SMB URL was constructed by jCIFS
 
 
- 
- 
Method Details- 
init- Throws:
- IOException
 
- 
closepublic void close()- Specified by:
- closein interface- AutoCloseable
- Specified by:
- closein interface- jcifs.SmbResource
- Overrides:
- closein class- jcifs.smb.SmbFile
 
- 
equals
- 
hashCodepublic int hashCode()Return a cache code from the super class.- Overrides:
- hashCodein class- jcifs.smb.SmbFile
- Returns:
- A hashcode for this share
 
 
-