module ActiveSambaLdap::SambaAccountEntry::ClassMethods

Public Instance Methods

rid2uid(rid) click to toggle source
# File lib/active_samba_ldap/samba_account_entry.rb, line 51
def rid2uid(rid)
  rid = Integer(rid)
  if WELL_KNOWN_RIDS.include?(rid)
    rid
  else
    (Integer(rid) - 1000) / 2
  end
end
samba_object_classes() click to toggle source
# File lib/active_samba_ldap/samba_account_entry.rb, line 34
def samba_object_classes
  if samba4?
    ["person", "organizationalPerson", "user"]
  else
    ["sambaSamAccount"]
  end
end
start_rid() click to toggle source
# File lib/active_samba_ldap/samba_account_entry.rb, line 60
def start_rid
  uid2rid(start_uid)
end
uid2rid(uid) click to toggle source
# File lib/active_samba_ldap/samba_account_entry.rb, line 42
def uid2rid(uid)
  uid = Integer(uid)
  if WELL_KNOWN_RIDS.include?(uid)
    uid
  else
    2 * uid + 1000
  end
end

Private Instance Methods

primary_group_options(options) click to toggle source
Calls superclass method
# File lib/active_samba_ldap/samba_account_entry.rb, line 65
def primary_group_options(options)
  super.merge(:extend => PrimaryGroupProxy)
end