Class BranchRule
Metadata of a BranchRule. BranchRule is the protection rule to enforce pre-defined rules on designated branches within a repository.
Implements
Inherited Members
Namespace: Google.Apis.SecureSourceManager.v1.Data
Assembly: Google.Apis.SecureSourceManager.v1.dll
Syntax
public class BranchRule : IDirectResponseSchema
Properties
AllowStaleReviews
Optional. Determines if allow stale reviews or approvals before merging to the branch.
Declaration
[JsonProperty("allowStaleReviews")]
public virtual bool? AllowStaleReviews { get; set; }
Property Value
| Type | Description |
|---|---|
| bool? |
Annotations
Optional. User annotations. These attributes can only be set and used by the user. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
Declaration
[JsonProperty("annotations")]
public virtual IDictionary<string, string> Annotations { get; set; }
Property Value
| Type | Description |
|---|---|
| IDictionary<string, string> |
CreateTime
object representation of CreateTimeRaw.
Declaration
[JsonIgnore]
[Obsolete("This property is obsolete and may behave unexpectedly; please use CreateTimeDateTimeOffset instead.")]
public virtual object CreateTime { get; set; }
Property Value
| Type | Description |
|---|---|
| object |
CreateTimeDateTimeOffset
DateTimeOffset representation of CreateTimeRaw.
Declaration
[JsonIgnore]
public virtual DateTimeOffset? CreateTimeDateTimeOffset { get; set; }
Property Value
| Type | Description |
|---|---|
| DateTimeOffset? |
CreateTimeRaw
Output only. Create timestamp.
Declaration
[JsonProperty("createTime")]
public virtual string CreateTimeRaw { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
Disabled
Optional. Determines if the branch rule is disabled or not.
Declaration
[JsonProperty("disabled")]
public virtual bool? Disabled { get; set; }
Property Value
| Type | Description |
|---|---|
| bool? |
ETag
Optional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.
Declaration
[JsonProperty("etag")]
public virtual string ETag { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
IncludePattern
Optional. The pattern of the branch that can match to this BranchRule. Specified as regex. .* for all
branches. Examples: main, (main|release.*). Current MVP phase only support .* for wildcard.
Declaration
[JsonProperty("includePattern")]
public virtual string IncludePattern { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
MinimumApprovalsCount
Optional. The minimum number of approvals required for the branch rule to be matched.
Declaration
[JsonProperty("minimumApprovalsCount")]
public virtual int? MinimumApprovalsCount { get; set; }
Property Value
| Type | Description |
|---|---|
| int? |
MinimumReviewsCount
Optional. The minimum number of reviews required for the branch rule to be matched.
Declaration
[JsonProperty("minimumReviewsCount")]
public virtual int? MinimumReviewsCount { get; set; }
Property Value
| Type | Description |
|---|---|
| int? |
Name
Optional. A unique identifier for a BranchRule. The name should be of the format:
projects/{project}/locations/{location}/repositories/{repository}/branchRules/{branch_rule}
Declaration
[JsonProperty("name")]
public virtual string Name { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
RequireCommentsResolved
Optional. Determines if require comments resolved before merging to the branch.
Declaration
[JsonProperty("requireCommentsResolved")]
public virtual bool? RequireCommentsResolved { get; set; }
Property Value
| Type | Description |
|---|---|
| bool? |
RequireLinearHistory
Optional. Determines if require linear history before merging to the branch.
Declaration
[JsonProperty("requireLinearHistory")]
public virtual bool? RequireLinearHistory { get; set; }
Property Value
| Type | Description |
|---|---|
| bool? |
RequirePullRequest
Optional. Determines if the branch rule requires a pull request or not.
Declaration
[JsonProperty("requirePullRequest")]
public virtual bool? RequirePullRequest { get; set; }
Property Value
| Type | Description |
|---|---|
| bool? |
RequiredStatusChecks
Optional. List of required status checks before merging to the branch.
Declaration
[JsonProperty("requiredStatusChecks")]
public virtual IList<Check> RequiredStatusChecks { get; set; }
Property Value
| Type | Description |
|---|---|
| IList<Check> |
Uid
Output only. Unique identifier of the repository.
Declaration
[JsonProperty("uid")]
public virtual string Uid { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
UpdateTime
object representation of UpdateTimeRaw.
Declaration
[JsonIgnore]
[Obsolete("This property is obsolete and may behave unexpectedly; please use UpdateTimeDateTimeOffset instead.")]
public virtual object UpdateTime { get; set; }
Property Value
| Type | Description |
|---|---|
| object |
UpdateTimeDateTimeOffset
DateTimeOffset representation of UpdateTimeRaw.
Declaration
[JsonIgnore]
public virtual DateTimeOffset? UpdateTimeDateTimeOffset { get; set; }
Property Value
| Type | Description |
|---|---|
| DateTimeOffset? |
UpdateTimeRaw
Output only. Update timestamp.
Declaration
[JsonProperty("updateTime")]
public virtual string UpdateTimeRaw { get; set; }
Property Value
| Type | Description |
|---|---|
| string |