# File lib/active_ldap/ldif.rb, line 838 def initialize(dn, controls=[], operations=[]) super(dn, {}, controls, "modify") @operations = operations end
# File lib/active_ldap/ldif.rb, line 847 def <<(operation) @operations << operation end
# File lib/active_ldap/ldif.rb, line 856 def ==(other) super(other) and @operations == other.operations end
# File lib/active_ldap/ldif.rb, line 851 def add_operation(type, attribute, options, attributes) klass = self.class.const_get("#{type.to_s.capitalize}Operation") self << klass.new(attribute, options, attributes) end
# File lib/active_ldap/ldif.rb, line 843 def each(&block) @operations.each(&block) end
# File lib/active_ldap/ldif.rb, line 861 def to_s_content result = super return result if @operations.empty? @operations.collect do |operation| result << "#{operation}-\n" end result end