Class: Google::Apis::NetworkconnectivityV1::Route

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

Overview

A route defines a path from VM instances within a spoke to a specific destination resource. Only VPC spokes have routes.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Route

Returns a new instance of Route.



2857
2858
2859
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2857

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

Instance Attribute Details

#create_timeString

Output only. The time the route was created. Corresponds to the JSON property createTime

Returns:

  • (String)


2767
2768
2769
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2767

def create_time
  @create_time
end

#descriptionString

An optional description of the route. Corresponds to the JSON property description

Returns:

  • (String)


2772
2773
2774
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2772

def description
  @description
end

#ip_cidr_rangeString

The destination IP address range. Corresponds to the JSON property ipCidrRange

Returns:

  • (String)


2777
2778
2779
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2777

def ip_cidr_range
  @ip_cidr_range
end

#labelsHash<String,String>

Optional labels in key-value pair format. For more information about labels, see Requirements for labels. Corresponds to the JSON property labels

Returns:

  • (Hash<String,String>)


2784
2785
2786
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2784

def labels
  @labels
end

#locationString

Output only. The origin location of the route. Uses the following form: " projects/project/locations/location" Example: projects/1234/locations/us- central1 Corresponds to the JSON property location

Returns:

  • (String)


2791
2792
2793
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2791

def location
  @location
end

#nameString

Immutable. The name of the route. Route names must be unique. Route names use the following form: projects/project_number/locations/global/hubs/hub/ routeTables/route_table_id/routes/route_id` Corresponds to the JSON propertyname`

Returns:

  • (String)


2798
2799
2800
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2798

def name
  @name
end

#next_hop_interconnect_attachmentGoogle::Apis::NetworkconnectivityV1::NextHopInterconnectAttachment

A route next hop that leads to an interconnect attachment resource. Corresponds to the JSON property nextHopInterconnectAttachment



2803
2804
2805
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2803

def next_hop_interconnect_attachment
  @next_hop_interconnect_attachment
end

#next_hop_router_appliance_instanceGoogle::Apis::NetworkconnectivityV1::NextHopRouterApplianceInstance

A route next hop that leads to a Router appliance instance. Corresponds to the JSON property nextHopRouterApplianceInstance



2808
2809
2810
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2808

def next_hop_router_appliance_instance
  @next_hop_router_appliance_instance
end

#next_hop_vpc_networkGoogle::Apis::NetworkconnectivityV1::NextHopVpcNetwork

Immutable. The destination VPC network for packets on this route. Corresponds to the JSON property nextHopVpcNetwork



2813
2814
2815
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2813

def next_hop_vpc_network
  @next_hop_vpc_network
end

#next_hop_vpn_tunnelGoogle::Apis::NetworkconnectivityV1::NextHopVpnTunnel

A route next hop that leads to a VPN tunnel resource. Corresponds to the JSON property nextHopVpnTunnel



2818
2819
2820
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2818

def next_hop_vpn_tunnel
  @next_hop_vpn_tunnel
end

#priorityFixnum

Output only. The priority of this route. Priority is used to break ties in cases where a destination matches more than one route. In these cases the route with the lowest-numbered priority value wins. Corresponds to the JSON property priority

Returns:

  • (Fixnum)


2825
2826
2827
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2825

def priority
  @priority
end

#spokeString

Immutable. The spoke that this route leads to. Example: projects/12345/ locations/global/spokes/SPOKE Corresponds to the JSON property spoke

Returns:

  • (String)


2831
2832
2833
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2831

def spoke
  @spoke
end

#stateString

Output only. The current lifecycle state of the route. Corresponds to the JSON property state

Returns:

  • (String)


2836
2837
2838
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2836

def state
  @state
end

#typeString

Output only. The route's type. Its type is determined by the properties of its IP address range. Corresponds to the JSON property type

Returns:

  • (String)


2842
2843
2844
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2842

def type
  @type
end

#uidString

Output only. The Google-generated UUID for the route. This value is unique across all Network Connectivity Center route resources. If a route is deleted and another with the same name is created, the new route is assigned a different uid. Corresponds to the JSON property uid

Returns:

  • (String)


2850
2851
2852
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2850

def uid
  @uid
end

#update_timeString

Output only. The time the route was last updated. Corresponds to the JSON property updateTime

Returns:

  • (String)


2855
2856
2857
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2855

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
# File 'lib/google/apis/networkconnectivity_v1/classes.rb', line 2862

def update!(**args)
  @create_time = args[:create_time] if args.key?(:create_time)
  @description = args[:description] if args.key?(:description)
  @ip_cidr_range = args[:ip_cidr_range] if args.key?(:ip_cidr_range)
  @labels = args[:labels] if args.key?(:labels)
  @location = args[:location] if args.key?(:location)
  @name = args[:name] if args.key?(:name)
  @next_hop_interconnect_attachment = args[:next_hop_interconnect_attachment] if args.key?(:next_hop_interconnect_attachment)
  @next_hop_router_appliance_instance = args[:next_hop_router_appliance_instance] if args.key?(:next_hop_router_appliance_instance)
  @next_hop_vpc_network = args[:next_hop_vpc_network] if args.key?(:next_hop_vpc_network)
  @next_hop_vpn_tunnel = args[:next_hop_vpn_tunnel] if args.key?(:next_hop_vpn_tunnel)
  @priority = args[:priority] if args.key?(:priority)
  @spoke = args[:spoke] if args.key?(:spoke)
  @state = args[:state] if args.key?(:state)
  @type = args[:type] if args.key?(:type)
  @uid = args[:uid] if args.key?(:uid)
  @update_time = args[:update_time] if args.key?(:update_time)
end