Class: Google::Apis::NetworkmanagementV1::Endpoint

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/networkmanagement_v1/classes.rb,
lib/google/apis/networkmanagement_v1/representations.rb,
lib/google/apis/networkmanagement_v1/representations.rb

Overview

Source or destination of the Connectivity Test.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Endpoint

Returns a new instance of Endpoint.



398
399
400
# File 'lib/google/apis/networkmanagement_v1/classes.rb', line 398

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#instanceString

A Compute Engine instance URI. Corresponds to the JSON property instance

Returns:

  • (String)


361
362
363
# File 'lib/google/apis/networkmanagement_v1/classes.rb', line 361

def instance
  @instance
end

#ip_addressString

The IP address of the endpoint, which can be an external or internal IP. An IPv6 address is only allowed when the test's destination is a global load balancer VIP. Corresponds to the JSON property ipAddress

Returns:

  • (String)


368
369
370
# File 'lib/google/apis/networkmanagement_v1/classes.rb', line 368

def ip_address
  @ip_address
end

#networkString

A Compute Engine network URI. Corresponds to the JSON property network

Returns:

  • (String)


373
374
375
# File 'lib/google/apis/networkmanagement_v1/classes.rb', line 373

def network
  @network
end

#network_typeString

Type of the network where the endpoint is located. Applicable only to source endpoint, as destination network type can be inferred from the source. Corresponds to the JSON property networkType

Returns:

  • (String)


379
380
381
# File 'lib/google/apis/networkmanagement_v1/classes.rb', line 379

def network_type
  @network_type
end

#portFixnum

The IP protocol port of the endpoint. Only applicable when protocol is TCP or UDP. Corresponds to the JSON property port

Returns:

  • (Fixnum)


385
386
387
# File 'lib/google/apis/networkmanagement_v1/classes.rb', line 385

def port
  @port
end

#project_idString

Project ID where the endpoint is located. The Project ID can be derived from the URI if you provide a VM instance or network URI. The following are two cases where you must provide the project ID: 1. Only the IP address is specified, and the IP address is within a GCP project. 2. When you are using Shared VPC and the IP address that you provide is from the service project. In this case, the network that the IP address resides in is defined in the host project. Corresponds to the JSON property projectId

Returns:

  • (String)


396
397
398
# File 'lib/google/apis/networkmanagement_v1/classes.rb', line 396

def project_id
  @project_id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



403
404
405
406
407
408
409
410
# File 'lib/google/apis/networkmanagement_v1/classes.rb', line 403

def update!(**args)
  @instance = args[:instance] if args.key?(:instance)
  @ip_address = args[:ip_address] if args.key?(:ip_address)
  @network = args[:network] if args.key?(:network)
  @network_type = args[:network_type] if args.key?(:network_type)
  @port = args[:port] if args.key?(:port)
  @project_id = args[:project_id] if args.key?(:project_id)
end