public class LdifFileLoader extends Object
Modifier and Type | Field and Description |
---|---|
protected CoreSession |
coreSession
a handle on the top core session
|
protected List<LdifLoadFilter> |
filters
the filters to use while loading entries into the server
|
protected File |
ldif
the LDIF file or directory containing LDIFs to load
|
protected ClassLoader |
loader
the class loader to use if we cannot file the file as a path
|
Constructor and Description |
---|
LdifFileLoader(CoreSession coreSession,
File ldif,
List<? extends LdifLoadFilter> filters)
Creates a new instance of LdifFileLoader.
|
LdifFileLoader(CoreSession coreSession,
File ldif,
List<? extends LdifLoadFilter> filters,
ClassLoader loader)
Creates a new instance of LdifFileLoader.
|
LdifFileLoader(CoreSession coreSession,
String ldif)
Creates a new instance of LdifFileLoader.
|
Modifier and Type | Method and Description |
---|---|
int |
execute()
Opens the LDIF file and loads the entries into the context.
|
protected CoreSession coreSession
protected final List<LdifLoadFilter> filters
protected final ClassLoader loader
public LdifFileLoader(CoreSession coreSession, String ldif)
coreSession
- the context to load the entries into.ldif
- the file of LDIF entries to load.public LdifFileLoader(CoreSession coreSession, File ldif, List<? extends LdifLoadFilter> filters)
coreSession
- The CoreSession instanceldif
- The ldif file to loadfilters
- The search filter to usepublic LdifFileLoader(CoreSession coreSession, File ldif, List<? extends LdifLoadFilter> filters, ClassLoader loader)
coreSession
- The CoreSession instanceldif
- The ldif file to loadfilters
- The search filter to useloader
- The LdifLoader to usepublic int execute()
Copyright © 2003–2020 The Apache Software Foundation. All rights reserved.