Created
November 19, 2012 00:48
-
-
Save richo/4108386 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [9] pry(main)> s = n.all[0] | |
| => <AWS::EC2::Instance id:i-1101936d> | |
| [10] pry(main)> show-source s.dns_name | |
| From: /Users/richo/.rvm/gems/ruby-1.9.3-p327/gems/aws-sdk-1.7.0/lib/aws/core/resource.rb @ line 2 | |
| 29: | |
| Number of lines: 13 | |
| Owner: AWS::EC2::Instance | |
| Visibility: public | |
| define_method(attribute.name) do | |
| return static_attributes[attribute.name] if | |
| static_attributes.has_key?(attribute.name) | |
| begin | |
| retrieve_attribute(attribute) { get_resource(attribute) } | |
| rescue Cacheable::NoData => e | |
| name = ruby_name.tr("_", " ") | |
| raise NotFound, "unable to find the #{name}" | |
| end | |
| end | |
| [11] pry(main)> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment