Class BillingAccount (2.2.0)

public final class BillingAccount extends GeneratedMessageV3 implements BillingAccountOrBuilder

A billing account in GCP Console. You can assign a billing account to one or more projects.

Protobuf type google.cloud.billing.v1.BillingAccount

Static Fields

DISPLAY_NAME_FIELD_NUMBER

public static final int DISPLAY_NAME_FIELD_NUMBER
Field Value
TypeDescription
int

MASTER_BILLING_ACCOUNT_FIELD_NUMBER

public static final int MASTER_BILLING_ACCOUNT_FIELD_NUMBER
Field Value
TypeDescription
int

NAME_FIELD_NUMBER

public static final int NAME_FIELD_NUMBER
Field Value
TypeDescription
int

OPEN_FIELD_NUMBER

public static final int OPEN_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static BillingAccount getDefaultInstance()
Returns
TypeDescription
BillingAccount

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static BillingAccount.Builder newBuilder()
Returns
TypeDescription
BillingAccount.Builder

newBuilder(BillingAccount prototype)

public static BillingAccount.Builder newBuilder(BillingAccount prototype)
Parameter
NameDescription
prototypeBillingAccount
Returns
TypeDescription
BillingAccount.Builder

parseDelimitedFrom(InputStream input)

public static BillingAccount parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static BillingAccount parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static BillingAccount parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static BillingAccount parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static BillingAccount parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static BillingAccount parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static BillingAccount parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static BillingAccount parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static BillingAccount parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static BillingAccount parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static BillingAccount parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static BillingAccount parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BillingAccount
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<BillingAccount> parser()
Returns
TypeDescription
Parser<BillingAccount>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public BillingAccount getDefaultInstanceForType()
Returns
TypeDescription
BillingAccount

getDisplayName()

public String getDisplayName()

The display name given to the billing account, such as My Billing Account. This name is displayed in the GCP Console.

string display_name = 3;

Returns
TypeDescription
String

The displayName.

getDisplayNameBytes()

public ByteString getDisplayNameBytes()

The display name given to the billing account, such as My Billing Account. This name is displayed in the GCP Console.

string display_name = 3;

Returns
TypeDescription
ByteString

The bytes for displayName.

getMasterBillingAccount()

public String getMasterBillingAccount()

If this account is a subaccount, then this will be the resource name of the master billing account that it is being resold through. Otherwise this will be empty.

string master_billing_account = 4;

Returns
TypeDescription
String

The masterBillingAccount.

getMasterBillingAccountBytes()

public ByteString getMasterBillingAccountBytes()

If this account is a subaccount, then this will be the resource name of the master billing account that it is being resold through. Otherwise this will be empty.

string master_billing_account = 4;

Returns
TypeDescription
ByteString

The bytes for masterBillingAccount.

getName()

public String getName()

The resource name of the billing account. The resource name has the form billingAccounts/{billing_account_id}. For example, billingAccounts/012345-567890-ABCDEF would be the resource name for billing account 012345-567890-ABCDEF.

string name = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

The resource name of the billing account. The resource name has the form billingAccounts/{billing_account_id}. For example, billingAccounts/012345-567890-ABCDEF would be the resource name for billing account 012345-567890-ABCDEF.

string name = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
ByteString

The bytes for name.

getOpen()

public boolean getOpen()

Output only. True if the billing account is open, and will therefore be charged for any usage on associated projects. False if the billing account is closed, and therefore projects associated with it will be unable to use paid services.

bool open = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

The open.

getParserForType()

public Parser<BillingAccount> getParserForType()
Returns
TypeDescription
Parser<BillingAccount>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getUnknownFields()

public final UnknownFieldSet getUnknownFields()
Returns
TypeDescription
UnknownFieldSet
Overrides

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public BillingAccount.Builder newBuilderForType()
Returns
TypeDescription
BillingAccount.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected BillingAccount.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
BillingAccount.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public BillingAccount.Builder toBuilder()
Returns
TypeDescription
BillingAccount.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides Exceptions
TypeDescription
IOException