module RCM class File attr_accessor :path, :owner, :group, :mode, :local_content_md5, :target_content_md5, :current_state, :desired_state def ==(other) return false unless other.is_a?(RCM::File) @path == other.path && @owner == other.owner && @group == other.group && @mode == other.mode && @content_md5 == other.content_md5 && @desired_state == other.desired_state && @current_state == other.current_state end def initialize(path, owner, group, mode, local_content_md5, target_content_md5, current_state, desired_state) @path = path @owner = owner @group = group @mode = mode @local_content_md5 = local_content_md5 @target_content_md5 = target_content_md5 @current_state = current_state @desired_state = desired_state end def lackin(other) raise 'not implemented.' end def to_s "Path = #{@path}\n" + "Owner = #{@owner}\n" + "Group = #{@group}\n" + "Mode = #{@mode}\n" + "Local Content MD5 = #{@local_content_md5}\n" + "Target Content MD5 = #{@target_content_md5}\n" + "Desired State = #{@desired_state}\n" + "Current State = #{@current_state}" end end end