}
private ComparatorDescription getComparatorDescription( String schemaName, ServerEntry entry ) throws Exception
{
ComparatorDescription description = new ComparatorDescription();
description.setNumericOid( getOid( entry ) );
List<String> values = new ArrayList<String>();
values.add( schemaName );
description.addExtension( MetaSchemaConstants.X_SCHEMA, values );
description.setFqcn( entry.get( fqcnAT ).getString() );
EntryAttribute desc = entry.get( descAT );
if ( desc != null && desc.size() > 0 )
{
description.setDescription( desc.getString() );
}
EntryAttribute bytecode = entry.get( byteCodeAT );
if ( bytecode != null && bytecode.size() > 0 )
{
byte[] bytes = bytecode.getBytes();
description.setBytecode( new String( Base64.encode( bytes ) ) );
}
return description;
}