パッケージ jcifs
インタフェース SmbResourceLocator
-
- 既知のサブインタフェースのリスト:
SmbResourceLocatorInternal
public interface SmbResourceLocatorLocation information for a SMB resource- 作成者:
- mbechler
-
-
メソッドの概要
すべてのメソッド インスタンス・メソッド abstractメソッド 修飾子とタイプ メソッド 説明 AddressgetAddress()StringgetCanonicalURL()Returns the full URL of this SMB resource with '.' and '..' components factored out.StringgetDfsPath()If the path of thisSmbFilefalls within a DFS volume, this method will return the referral path to which it maps.DfsReferralDatagetDfsReferral()StringgetName()Returns the last component of the target URL.StringgetParent()Everything but the last component of the URL representing this SMB resource is effectively it's parent.StringgetPath()Returns the full uncanonicalized URL of this SMB resource.intgetPort()StringgetServer()Retrieve the hostname of the server for this SMB resource.StringgetServerWithDfs()Retrieve the hostname of the server for this SMB resource.StringgetShare()Retrieves the share associated with this SMB resource.intgetType()Returns type of of object this SmbFile represents.StringgetUNCPath()URLgetURL()StringgetURLPath()booleanisIPC()booleanisRoot()booleanisWorkgroup()
-
-
-
メソッドの詳細
-
getName
String getName()
Returns the last component of the target URL. This will effectively be the name of the file or directory represented by thisSmbFileor in the case of URLs that only specify a server or workgroup, the server or workgroup will be returned. The name of the root URLsmb://is alsosmb://. If this SmbFile refers to a workgroup, server, share, or directory, the name will include a trailing slash '/' so that composing new SmbFiles will maintain the trailing slash requirement.- 戻り値:
- The last component of the URL associated with this SMB
resource or
smb://if the resource issmb://itself.
-
getDfsReferral
DfsReferralData getDfsReferral()
- 戻り値:
- dfs referral data
-
getParent
String getParent()
Everything but the last component of the URL representing this SMB resource is effectively it's parent. The root URLsmb://does not have a parent. In this casesmb://is returned.- 戻り値:
- The parent directory of this SMB resource or
smb://if the resource refers to the root of the URL hierarchy which incidentally is alsosmb://.
-
getPath
String getPath()
Returns the full uncanonicalized URL of this SMB resource. AnSmbFileconstructed with the result of this method will result in anSmbFilethat is equal to the original.- 戻り値:
- The uncanonicalized full URL of this SMB resource.
-
getCanonicalURL
String getCanonicalURL()
Returns the full URL of this SMB resource with '.' and '..' components factored out. AnSmbFileconstructed with the result of this method will result in anSmbFilethat is equal to the original.- 戻り値:
- The canonicalized URL of this SMB resource.
-
getUNCPath
String getUNCPath()
- 戻り値:
- The canonicalized UNC path of this SMB resource (relative to it's share)
-
getURLPath
String getURLPath()
- 戻り値:
- The canonicalized URL path (relative to the server/domain)
-
getShare
String getShare()
Retrieves the share associated with this SMB resource. In the case ofsmb://,smb://workgroup/, andsmb://server/URLs which do not specify a share,nullwill be returned.- 戻り値:
- The share component or
nullif there is no share
-
getServerWithDfs
String getServerWithDfs()
Retrieve the hostname of the server for this SMB resource. If the resources has been resolved by DFS this will return the target name.- 戻り値:
- The server name
-
getServer
String getServer()
Retrieve the hostname of the server for this SMB resource. If thisSmbFilereferences a workgroup, the name of the workgroup is returned. If thisSmbFilerefers to the root of this SMB network hierarchy,nullis returned.- 戻り値:
- The server or workgroup name or
nullif thisSmbFilerefers to the rootsmb://resource.
-
getDfsPath
String getDfsPath()
If the path of thisSmbFilefalls within a DFS volume, this method will return the referral path to which it maps. Otherwisenullis returned.- 戻り値:
- URL to the DFS volume
-
getPort
int getPort()
- 戻り値:
- the transport port, if specified
-
getURL
URL getURL()
- 戻り値:
- the original URL
-
getAddress
Address getAddress() throws CIFSException
- 戻り値:
- resolved server address
- 例外:
CIFSException
-
isIPC
boolean isIPC()
- 戻り値:
- whether this is a IPC connection
-
getType
int getType() throws CIFSExceptionReturns type of of object this SmbFile represents.- 戻り値:
- TYPE_FILESYSTEM, TYPE_WORKGROUP, TYPE_SERVER, TYPE_NAMED_PIPE, or TYPE_SHARE in which case it may be either TYPE_SHARE, TYPE_PRINTER or TYPE_COMM.
- 例外:
CIFSException
-
isWorkgroup
boolean isWorkgroup() throws CIFSException- 戻り値:
- whether this is a workgroup reference
- 例外:
CIFSException
-
isRoot
boolean isRoot()
- 戻り値:
- whether this is a root resource
-
-