Class | ActiveLdap::Adapter::JndiConnection::ModifyRecord |
In: |
lib/active_ldap/adapter/jndi_connection.rb
|
Parent: | Object |
DirContext | = | directory.DirContext |
BasicAttribute | = | directory.BasicAttribute |
ADD_ATTRIBUTE | = | DirContext::ADD_ATTRIBUTE |
REPLACE_ATTRIBUTE | = | DirContext::REPLACE_ATTRIBUTE |
REMOVE_ATTRIBUTE | = | DirContext::REMOVE_ATTRIBUTE |
name | [R] | |
type | [R] | |
values | [R] |
# File lib/active_ldap/adapter/jndi_connection.rb, line 48 48: def initialize(type, name, values, binary) 49: @type = self.class.const_get("#{type.to_s.upcase}_ATTRIBUTE") 50: @name = name 51: @values = values 52: @binary = binary 53: end
# File lib/active_ldap/adapter/jndi_connection.rb, line 63 63: def to_java_attribute 64: attribute = BasicAttribute.new(@name) 65: values = @values 66: values = values.collect(&:to_java_bytes) if binary? 67: values.each do |value| 68: attribute.add(value) 69: end 70: attribute 71: end