ProtectionEntryExtensionsToServerCompatibleString Method (ProtectionMode)
|
Extension method which returns a string presentation of protection mode,
which can be recognized by the server
e.g. Write is translated to "write" and ReadRights to "=read".
These are server compatible mode representations
Namespace:
Perforce.P4
Assembly:
p4api.net (in p4api.net.dll) Version: 2024.1.261.8274
Syntaxpublic static string ToServerCompatibleString(
this ProtectionMode mode
)
<ExtensionAttribute>
Public Shared Function ToServerCompatibleString (
mode As ProtectionMode
) As String
public:
[ExtensionAttribute]
static String^ ToServerCompatibleString(
ProtectionMode mode
)
[<ExtensionAttribute>]
static member ToServerCompatibleString :
mode : ProtectionMode -> string
Parameters
- mode
- Type: Perforce.P4ProtectionMode
Return Value
Type:
StringUsage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
ProtectionMode. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
Examples
To get string representation of protection mode instance
string readMode = ProtectionMode.Read.ToServerCompatibleString();
string writeRightMode = ProtectionMode.WriteRights.ToServerCompatibleString();
See Also