Class: Aws::EC2::Instance::Collection
- Inherits:
-
Resources::Collection
- Object
- Resources::Collection
- Aws::EC2::Instance::Collection
- Defined in:
- lib/aws-sdk-ec2/instance.rb
Batch Actions collapse
- #batch_create_tags(options = {}) ⇒ void
- #batch_delete_tags!(options = {}) ⇒ void
- #batch_monitor(options = {}) ⇒ void
- #batch_reboot(options = {}) ⇒ void
- #batch_start(options = {}) ⇒ void
- #batch_stop(options = {}) ⇒ void
- #batch_terminate!(options = {}) ⇒ void
- #batch_unmonitor(options = {}) ⇒ void
Instance Method Details
#batch_create_tags(options = {}) ⇒ void
This method returns an undefined value.
1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 |
# File 'lib/aws-sdk-ec2/instance.rb', line 1849 def ( = {}) batch_enum.each do |batch| params = Aws::Util.copy_hash() params[:resources] ||= [] batch.each do |item| params[:resources] << item.id end Aws::Plugins::UserAgent.feature('resource') do batch[0].client.(params) end end nil end |
#batch_delete_tags!(options = {}) ⇒ void
This method returns an undefined value.
1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 |
# File 'lib/aws-sdk-ec2/instance.rb', line 1893 def ( = {}) batch_enum.each do |batch| params = Aws::Util.copy_hash() params[:resources] ||= [] batch.each do |item| params[:resources] << item.id end Aws::Plugins::UserAgent.feature('resource') do batch[0].client.(params) end end nil end |
#batch_monitor(options = {}) ⇒ void
This method returns an undefined value.
1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 |
# File 'lib/aws-sdk-ec2/instance.rb', line 1919 def batch_monitor( = {}) batch_enum.each do |batch| params = Aws::Util.copy_hash() params[:instance_ids] ||= [] batch.each do |item| params[:instance_ids] << item.id end Aws::Plugins::UserAgent.feature('resource') do batch[0].client.monitor_instances(params) end end nil end |
#batch_reboot(options = {}) ⇒ void
This method returns an undefined value.
1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 |
# File 'lib/aws-sdk-ec2/instance.rb', line 1945 def batch_reboot( = {}) batch_enum.each do |batch| params = Aws::Util.copy_hash() params[:instance_ids] ||= [] batch.each do |item| params[:instance_ids] << item.id end Aws::Plugins::UserAgent.feature('resource') do batch[0].client.reboot_instances(params) end end nil end |
#batch_start(options = {}) ⇒ void
This method returns an undefined value.
1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 |
# File 'lib/aws-sdk-ec2/instance.rb', line 1974 def batch_start( = {}) batch_enum.each do |batch| params = Aws::Util.copy_hash() params[:instance_ids] ||= [] batch.each do |item| params[:instance_ids] << item.id end Aws::Plugins::UserAgent.feature('resource') do batch[0].client.start_instances(params) end end nil end |
#batch_stop(options = {}) ⇒ void
This method returns an undefined value.
2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 |
# File 'lib/aws-sdk-ec2/instance.rb', line 2020 def batch_stop( = {}) batch_enum.each do |batch| params = Aws::Util.copy_hash() params[:instance_ids] ||= [] batch.each do |item| params[:instance_ids] << item.id end Aws::Plugins::UserAgent.feature('resource') do batch[0].client.stop_instances(params) end end nil end |
#batch_terminate!(options = {}) ⇒ void
This method returns an undefined value.
2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 |
# File 'lib/aws-sdk-ec2/instance.rb', line 2046 def batch_terminate!( = {}) batch_enum.each do |batch| params = Aws::Util.copy_hash() params[:instance_ids] ||= [] batch.each do |item| params[:instance_ids] << item.id end Aws::Plugins::UserAgent.feature('resource') do batch[0].client.terminate_instances(params) end end nil end |
#batch_unmonitor(options = {}) ⇒ void
This method returns an undefined value.
2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 |
# File 'lib/aws-sdk-ec2/instance.rb', line 2072 def batch_unmonitor( = {}) batch_enum.each do |batch| params = Aws::Util.copy_hash() params[:instance_ids] ||= [] batch.each do |item| params[:instance_ids] << item.id end Aws::Plugins::UserAgent.feature('resource') do batch[0].client.unmonitor_instances(params) end end nil end |