Sha256: a28d974167166babc7abea3e42db616d7b76cdb70d834683140eb5f314a9bcee
Contents?: true
Size: 1.91 KB
Versions: 5
Compression:
Stored size: 1.91 KB
Contents
module RSCM # Represents a file within a Revision, and also information about how this file # was modified compared with the previous revision. class RevisionFile include XMLRPC::Marshallable MODIFIED = "MODIFIED" DELETED = "DELETED" ADDED = "ADDED" MOVED = "MOVED" attr_accessor :status attr_accessor :path attr_accessor :previous_native_revision_identifier # The native SCM's revision for this file. For non-transactional SCMs this is different from # the parent Revision's attr_accessor :native_revision_identifier attr_accessor :developer attr_accessor :message # This is a UTC ruby time attr_accessor :time def initialize(path=nil, status=nil, developer=nil, message=nil, native_revision_identifier=nil, time=nil) @path, @developer, @message, @native_revision_identifier, @time, @status = path, developer, message, native_revision_identifier, time, status end def accept(visitor) visitor.visit_file(self) end def to_s "#{path} | #{native_revision_identifier}" end def developer=(developer) raise "can't be null" if developer.nil? @developer = developer end def message=(message) raise "can't be null" if message.nil? @message = message end def path=(path) raise "can't be null" if path.nil? @path = path end def native_revision_identifier=(id) raise "can't be null" if id.nil? @native_revision_identifier = id end def time=(time) raise "time must be a Time object" unless time.is_a?(Time) @time = time end def ==(other) return false if !other.is_a?(self.class) self.path == other.path && self.developer == other.developer && self.message == other.message && self.native_revision_identifier == other.native_revision_identifier && self.time == other.time end end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
rscm-0.3.3 | lib/rscm/revision_file.rb |
rscm-0.3.2 | lib/rscm/revision_file.rb |
rscm-0.3.0 | lib/rscm/revision_file.rb |
rscm-0.3.1 | lib/rscm/revision_file.rb |
rscm-0.3.4 | lib/rscm/revision_file.rb |