lib/rdpl.rb in rdpl-0.1.0 vs lib/rdpl.rb in rdpl-0.2.0
- old
+ new
@@ -6,11 +6,11 @@
CR = 13.chr
LF = 10.chr
NEW_LINE = CR + LF
FEED = 'F'
- module Commandable
+ module Commandable # :nodoc:
def command(param)
raise EndedElementError if self.state == :finished
@contents << STX << param << NEW_LINE
end
end
@@ -18,11 +18,13 @@
module Sensor
REFLEXIVE = 'r'
EDGE = 'e'
end
+ # Raised when a job is created without a printer name
class MissingPrinterNameError < StandardError; end
- class EndedElementError < StandardError; end
+ # Raised when inserting a new command to a already closed job.
+ class EndedElementError < StandardError; end
end
require 'job'
require 'label'
require 'elements/element'