Module: Ldaptic::MatchingRules

Defined in:
lib/ldaptic/matching_rules.rb

Overview

RFC4517 - Lightweight Directory Access Protocol (LDAP): Syntaxes and Matching Rules RFC4518 - Lightweight Directory Access Protocol (LDAP): Internationalized String Preparation

Defined Under Namespace

Classes: Boolean, CaseExactIA5Match, CaseExactMatch, CaseIgnoreIA5Match, CaseIgnoreListMatch, CaseIgnoreMatch, DistinguishedNameMatch, GeneralizedTimeMatch, NumericStringMatch, OctetStringMatch, TelephoneNumberMatch

Class Method Summary collapse

Class Method Details

.for(name) ⇒ Object



8
9
10
11
12
13
14
15
16
# File 'lib/ldaptic/matching_rules.rb', line 8

def self.for(name)
  name = name.to_s
  name = name[0..0].upcase + name[1..-1].to_s
  if !name.empty? && const_defined?(name)
    const_get(name)
  else
    CaseIgnoreMatch
  end
end