Package de.hybris.platform.ldap
Class LDIF2ImpExConverter
java.lang.Object
de.hybris.platform.ldap.LDIF2ImpExConverter
Converts a given LDIF file to a IMPEX file. An additional mapping object will be used for translating LDAP objectclasses to
their corresponding hybris types.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionLDIF2ImpExConverter(File file, ConfigValueObject config) Opens the file and sets the given encoding.LDIF2ImpExConverter(InputStream inputStream, ConfigValueObject config) Opens the given Inputstream with the given file.LDIF2ImpExConverter(Reader reader, ConfigValueObject config) Opens the given reader.LDIF2ImpExConverter(String fileName, ConfigValueObject config) Opens the file with the given filename and sets the given encoding. -
Method Summary
Modifier and TypeMethodDescriptionbooleancallsgenerateImpExScript( "INSERT" )booleangenerateImpExScript(String mode) generateImportLine(LDAPGenericObject obj, String mode)
-
Field Details
-
DEFAULT_ENCODING
- See Also:
-
-
Constructor Details
-
LDIF2ImpExConverter
public LDIF2ImpExConverter(String fileName, ConfigValueObject config) throws UnsupportedEncodingException, FileNotFoundException Opens the file with the given filename and sets the given encoding.- Parameters:
fileName- the filename of the LDIF file- Throws:
UnsupportedEncodingException- thrown by false encoding typeFileNotFoundException- thrown if file not found
-
LDIF2ImpExConverter
public LDIF2ImpExConverter(File file, ConfigValueObject config) throws UnsupportedEncodingException, FileNotFoundException Opens the file and sets the given encoding.- Parameters:
file- the LDIF file- Throws:
UnsupportedEncodingException- thrown by false encoding typeFileNotFoundException- thrown if file not found
-
LDIF2ImpExConverter
public LDIF2ImpExConverter(InputStream inputStream, ConfigValueObject config) throws UnsupportedEncodingException Opens the given Inputstream with the given file.- Parameters:
inputStream- the InputStream- Throws:
UnsupportedEncodingException
-
LDIF2ImpExConverter
Opens the given reader. The default encoding is set to"UTF-8"- Parameters:
reader- the reader
-
-
Method Details
-
generateImpExScript
callsgenerateImpExScript( "INSERT" )- Returns:
- success
- Throws:
JaloBusinessExceptionUnsupportedEncodingException
-
generateImpExScript
public boolean generateImpExScript(String mode) throws JaloBusinessException, UnsupportedEncodingException -
generateImportLine
-
getExportAsMedia
-
getExportAsString
-