Class: Array

Inherits:
Object show all
Defined in:
lib/puppet/util/zaml.rb

Instance Method Summary collapse

Instance Method Details

#to_zaml(z) ⇒ Object



374
375
376
377
378
379
380
381
382
383
384
# File 'lib/puppet/util/zaml.rb', line 374

def to_zaml(z)
  z.first_time_only(self) {
    z.nested {
      if empty?
        z.emit('[]')
      else
        each { |v| z.nl('- '); v.to_zaml(z) }
      end
    }
  }
end