RepositoryGetLabel Method (String, String, Options)
|
Get the record for an existing label from the repository.
Namespace:
Perforce.P4
Assembly:
p4api.net (in p4api.net.dll) Version: 2024.2.269.3570
Syntax public Label GetLabel(
string label,
string template,
Options options
)
Public Function GetLabel (
label As String,
template As String,
options As Options
) As Label
public:
Label^ GetLabel(
String^ label,
String^ template,
Options^ options
)
member GetLabel :
label : string *
template : string *
options : Options -> Label
Parameters
- label
- Type: SystemString
Label name - template
- Type: SystemString
Template to use (if required) - options
- Type: Perforce.P4Options
Flags used when fetching an existing label
Return Value
Type:
LabelThe Label object if label was found, null if creation failed
Examples
To get the admin_label with the gobal option:
LabelCmdOptions opts = new LabelCmdOptions(LabelCmdFlags.Global,null);
Label label = rep.GetLabel("admin_label", null, opts);
See Also