File: dsc_entry.rb

package info (click to toggle)
ruby-rghost 0.9.9-5
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,188 kB
  • sloc: ruby: 3,374; makefile: 6; sh: 1
file content (17 lines) | stat: -rw-r--r-- 389 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
require "rghost/ps_object"
# Specifiesnew  DSC (Document Structuring Conventions)
class RGhost::DSCEntry < RGhost::PsObject
  #===Example
  #   DSCEntry.new do |entry|
  #     entry << "BoundingBox: 0 0 612 792"
  #     entry << "Pages: 45"
  #     entry << "BeginSetup"
  #   end
  def initialize
    yield @entries = []
  end

  def ps
    @entries.map { |e| "%%#{e}\n" }.to_s
  end
end