# Interface EndpointControlPolicyOrBuilder (0.9.0)

0.9.0 (latest) 0.7.0 0.4.0 0.3.0 0.1.0

    public interface EndpointControlPolicyOrBuilder extends MessageOrBuilder

## Implements

[MessageOrBuilder](https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.MessageOrBuilder.html)

## Methods

### getAllowedOrigins(int index)

    public abstract String getAllowedOrigins(int index)

Optional. The allowed HTTP(s) origins that tools in the App are able to
directly call. The enforcement depends on the value of
enforcement_scope and the VPC-SC status of the project.
If a port number is not provided, all ports will be allowed. Otherwise,
the port number must match exactly. For example, "<https://example.com>"
will match "<https://example.com:443>" and any other port.
"<https://example.com:443>" will only match "<https://example.com:443>".

`repeated string allowed_origins = 2 [(.google.api.field_behavior) = OPTIONAL];`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `index` | `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` The index of the element to return. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` | The allowedOrigins at the given index. |

### getAllowedOriginsBytes(int index)

    public abstract ByteString getAllowedOriginsBytes(int index)

Optional. The allowed HTTP(s) origins that tools in the App are able to
directly call. The enforcement depends on the value of
enforcement_scope and the VPC-SC status of the project.
If a port number is not provided, all ports will be allowed. Otherwise,
the port number must match exactly. For example, "<https://example.com>"
will match "<https://example.com:443>" and any other port.
"<https://example.com:443>" will only match "<https://example.com:443>".

`repeated string allowed_origins = 2 [(.google.api.field_behavior) = OPTIONAL];`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `index` | `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` The index of the value to return. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.ByteString.html` | The bytes of the allowedOrigins at the given index. |

### getAllowedOriginsCount()

    public abstract int getAllowedOriginsCount()

Optional. The allowed HTTP(s) origins that tools in the App are able to
directly call. The enforcement depends on the value of
enforcement_scope and the VPC-SC status of the project.
If a port number is not provided, all ports will be allowed. Otherwise,
the port number must match exactly. For example, "<https://example.com>"
will match "<https://example.com:443>" and any other port.
"<https://example.com:443>" will only match "<https://example.com:443>".

`repeated string allowed_origins = 2 [(.google.api.field_behavior) = OPTIONAL];`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | The count of allowedOrigins. |

### getAllowedOriginsList()

    public abstract List<String> getAllowedOriginsList()

Optional. The allowed HTTP(s) origins that tools in the App are able to
directly call. The enforcement depends on the value of
enforcement_scope and the VPC-SC status of the project.
If a port number is not provided, all ports will be allowed. Otherwise,
the port number must match exactly. For example, "<https://example.com>"
will match "<https://example.com:443>" and any other port.
"<https://example.com:443>" will only match "<https://example.com:443>".

`repeated string allowed_origins = 2 [(.google.api.field_behavior) = OPTIONAL];`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/util/List.html<https://docs.oracle.com/javase/8/docs/api/java/lang/String.html>` | A list containing the allowedOrigins. |

### getEnforcementScope()

    public abstract EndpointControlPolicy.EnforcementScope getEnforcementScope()

Optional. The scope in which this policy's allowed_origins list is
enforced.

`
.google.cloud.ces.v1.EndpointControlPolicy.EnforcementScope enforcement_scope = 1 [(.google.api.field_behavior) = OPTIONAL];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-ces/latest/com.google.cloud.ces.v1.EndpointControlPolicy.EnforcementScope` | The enforcementScope. |

### getEnforcementScopeValue()

    public abstract int getEnforcementScopeValue()

Optional. The scope in which this policy's allowed_origins list is
enforced.

`
.google.cloud.ces.v1.EndpointControlPolicy.EnforcementScope enforcement_scope = 1 [(.google.api.field_behavior) = OPTIONAL];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | The enum numeric value on the wire for enforcementScope. |