Platforms to show: All Mac Windows Linux Cross-Platform

Back to NetFSMountMBS class.

NetFSMountMBS.URLForRemountingVolume(path as String) as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Files MBS MacOSX Plugin 18.3 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Given a localPathURL that refers to a location on a mounted network share, return the URL needed to remount that volume.
Example
dim url as string = NetFSMountMBS.URLForRemountingVolume("/Volumes/Ablage2")

MsgBox url

The return value is an URL of the server, or "" if localPathURL isn't a mounted network share.

See also:

NetFSMountMBS.URLForRemountingVolume(vol as FolderItem) as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Files MBS MacOSX Plugin 18.3 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Given a localPathURL that refers to a location on a mounted network share, return the URL needed to remount that volume.
Example
dim v as FolderItem = volume(VolumeCount-1)
dim url as string = NetFSMountMBS.URLForRemountingVolume(v)

MsgBox url

The return value is an URL of the server, or "" if localPathURL isn't a mounted network share.

See also:

NetFSMountMBS.URLProbe(hostname as String) as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Files MBS MacOSX Plugin 18.3 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Checks what protocol may be used to mount disk from this server.
Example
dim protocol as string = NetFSMountMBS.URLProbe("Ablage2.local")

MsgBox protocol

The user may enter a hostname in lieu of a full URL. We need to determine an appropriate protocol for this host and return a scheme from which a URL can be derived. For instance, if we determine that it's an SMB server then we return "smb" which the caller can use to build a URL: "smb://hostname".

We start with a list of likely protocols, e.g. "smb", "afp" and initiate a TCP connection to the port for each protocol. These connect attempts run in parallel. Then wait in a select() call to see which connections are successful, or refused, or do not respond. There is a preference order, even if a protocol later in the list responds first, it may lose out if a protocol earlier in the list responds within the timeout.

Returns "smb" for example.

The items on this page are in the following plugins: MBS MacOSX Plugin.


The biggest plugin in space...