Class: Google::Apis::DiscoveryV1::RestResource
- Inherits:
- 
      Object
      
        - Object
- Google::Apis::DiscoveryV1::RestResource
 
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/generator/model.rb,
 generated/google/apis/discovery_v1/classes.rb,
 generated/google/apis/discovery_v1/representations.rb,
 generated/google/apis/discovery_v1/representations.rb
Instance Attribute Summary collapse
- 
  
    
      #api_methods  ⇒ Hash<String,Google::Apis::DiscoveryV1::RestMethod> 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    Methods on this resource. 
- 
  
    
      #parent  ⇒ Object 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    Returns the value of attribute parent. 
- 
  
    
      #resources  ⇒ Hash<String,Google::Apis::DiscoveryV1::RestResource> 
    
    
  
  
  
  
    
    
  
  
  
  
  
  
    Sub-resources on this resource. 
Instance Method Summary collapse
- #all_methods ⇒ Object
- 
  
    
      #initialize(**args)  ⇒ RestResource 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    A new instance of RestResource. 
- 
  
    
      #update!(**args)  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    Update properties of this object. 
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ RestResource
Returns a new instance of RestResource
| 949 950 951 | # File 'generated/google/apis/discovery_v1/classes.rb', line 949 def initialize(**args) update!(**args) end | 
Instance Attribute Details
#api_methods ⇒ Hash<String,Google::Apis::DiscoveryV1::RestMethod>
Methods on this resource.
Corresponds to the JSON property methods
| 942 943 944 | # File 'generated/google/apis/discovery_v1/classes.rb', line 942 def api_methods Hash[(@api_methods || {}).sort] end | 
#parent ⇒ Object
Returns the value of attribute parent
| 103 104 105 | # File 'lib/google/apis/generator/model.rb', line 103 def parent @parent end | 
#resources ⇒ Hash<String,Google::Apis::DiscoveryV1::RestResource>
Sub-resources on this resource.
Corresponds to the JSON property resources
| 947 948 949 | # File 'generated/google/apis/discovery_v1/classes.rb', line 947 def resources Hash[(@resources || {}).sort] end | 
Instance Method Details
#all_methods ⇒ Object
| 113 114 115 116 117 118 | # File 'lib/google/apis/generator/model.rb', line 113 def all_methods m = [] m << api_methods.values unless api_methods.nil? m << resources.map { |_k, r| r.all_methods } unless resources.nil? m.flatten end | 
#update!(**args) ⇒ Object
Update properties of this object
| 954 955 956 957 | # File 'generated/google/apis/discovery_v1/classes.rb', line 954 def update!(**args) @api_methods = args[:api_methods] if args.key?(:api_methods) @resources = args[:resources] if args.key?(:resources) end |