def describe_mount_targets(options={})
response = Excon::Response.new
mount_targets = if id = options[:id]
if mount_target = self.data[:mount_targets][id]
[mount_target]
else
raise Fog::AWS::EFS::NotFound.new("Mount target does not exist.")
end
elsif file_system_id = options[:file_system_id]
self.data[:mount_targets].values.select { |mt| mt["FileSystemId"] == file_system_id }
else
raise Fog::AWS::EFS::Error.new("file system ID or mount target ID must be specified")
end
mount_targets.each do |mount_target|
mount_target['LifeCycleState'] = 'available'
self.data[:mount_targets][mount_target["MountTargetId"]] = mount_target
end
response.body = {"MountTargets" => mount_targets}
response
end