CARVIEW |
Every repository with this icon (

Every repository with this icon (

Fork of automatthew/ambitious_activeldap | |
Description: | Ambition adapter for ActiveLdap |
Clone URL: |
git://github.com/defunkt/ambitious_activeldap.git
Give this clone URL to anyone.
git clone git://github.com/defunkt/ambitious_activeldap.git
|
name | age | message | |
---|---|---|---|
![]() |
LICENSE | Wed Jan 30 17:42:57 -0800 2008 | updated license and Rakefile author info; chang... [automatthew] |
![]() |
Manifest | Wed Jan 30 17:44:51 -0800 2008 | updated manifest [automatthew] |
![]() |
README.textile | Sun Mar 09 11:31:09 -0700 2008 | gotta add the file in question, yep [defunkt] |
![]() |
Rakefile | Thu Jan 31 12:22:53 -0800 2008 | version fix [automatthew] |
![]() |
lib/ | Thu Jan 31 12:00:11 -0800 2008 | adjusted query kick to actually match spec, hey! [automatthew] |
![]() |
test/ | Wed Jan 30 12:06:34 -0800 2008 | copied from ambition [automatthew] |
An Ambitious ActiveLdap Adapter
Write LDAP search filters in Ruby. Awesomeness courtesy of Chris Wanstrath’s Ambition library.
You must be using ActiveLdap 0.9 or greater.
Get It
$ sudo gem install ambitious-activeldap
require 'rubygems' require 'ambition/adapters/active_ldap'
Examples
Let User
be a subclass of ActiveLdap::Base
Queries don't run until you kick them. This adapter supports only the basic kicker methods: each
, each_with_index
, map
, entries
, to_a
.
This adapter also doesn’t support the methods that require sorting, slicing, or counting, because OpenLDAP effectively doesn’t support such things. ActiveLdap lets you request sorted and sliced result sets, but it does the work in Ruby, so you might as well do it yourself.
You can call to_s
, but not to_hash
on a query. to_s
returns the LDAP search filter as a string.
Issues.find(:all, :filter => “(type=bug)”)
Found a bug? Sweet. Add it at the Lighthouse.
More information on Ambition: