]> err.no Git - sope/blob - sope-core/NGLdap/NGLdapURL.h
added svn:keywords and svn:ignore where appropriate. removed CVS artifacts.
[sope] / sope-core / NGLdap / NGLdapURL.h
1 /*
2   Copyright (C) 2000-2003 SKYRIX Software AG
3
4   This file is part of OGo
5
6   OGo is free software; you can redistribute it and/or modify it under
7   the terms of the GNU Lesser General Public License as published by the
8   Free Software Foundation; either version 2, or (at your option) any
9   later version.
10
11   OGo is distributed in the hope that it will be useful, but WITHOUT ANY
12   WARRANTY; without even the implied warranty of MERCHANTABILITY or
13   FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
14   License for more details.
15
16   You should have received a copy of the GNU Lesser General Public
17   License along with OGo; see the file COPYING.  If not, write to the
18   Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
19   02111-1307, USA.
20 */
21 // $Id$
22
23 #ifndef __NGLdapURL_H__
24 #define __NGLdapURL_H__
25
26 #import <Foundation/NSObject.h> // required by gstep-base
27 #import <Foundation/NSURL.h>
28
29 @class NSString, NSArray, NSHost, NSEnumerator;
30 @class NGLdapConnection, NGLdapEntry;
31
32 // ldap://hostport/dn[?attributes[?scope[?filter]]]
33
34 @interface NGLdapURL : NSURL < NSCopying >
35 {
36   NSString *host;
37   int      port;
38   NSString *base;
39   int      scope;
40   NSString *filter;
41   NSArray  *attributes;
42 }
43
44 + (id)ldapURLWithString:(NSString *)_url;
45 - (id)initWithString:(NSString *)_url; // designated initializer
46
47 /* accessors */
48
49 - (NSString *)hostName;
50 - (NSHost *)host;
51
52 - (int)port;
53 - (NSString *)baseDN;
54 - (int)scope;
55 - (NSString *)searchFilter;
56 - (NSArray *)attributes;
57
58 /* query */
59
60 - (NGLdapConnection *)openConnection;
61 - (NSEnumerator *)fetchEntries;
62 - (NGLdapEntry *)fetchEntry;
63
64 /* url */
65
66 - (NSString *)urlString;
67
68 @end
69
70 #endif /* __NGLdapURL_H__ */