本文整理了Java中org.apache.directory.server.core.api.partition.Partition.setSchemaManager()
方法的一些代码示例,展示了Partition.setSchemaManager()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Partition.setSchemaManager()
方法的具体详情如下:
包路径:org.apache.directory.server.core.api.partition.Partition
类名称:Partition
方法名:setSchemaManager
[英]Sets the schema manager assigned to this Partition.
[中]设置分配给该分区的架构管理器。
代码示例来源:origin: org.apache.knox/gateway-test-ldap
public void addPartition( Partition partition ) throws Exception
{
partition.setSchemaManager( schemaManager );
try
{
// can be null when called before starting up
if ( partitionNexus != null )
{
partitionNexus.addContextPartition( partition );
}
}
catch ( LdapException le )
{
// We've got an exception, we cannot add the partition to the partitions
throw le;
}
// Now, add the partition to the set of managed partitions
partitions.add( partition );
}
代码示例来源:origin: org.apache.directory.server/apacheds-core-api
/**
* {@inheritDoc}
*/
@Override
protected void doInit() throws LdapException
{
if ( !initialized )
{
// -----------------------------------------------------------------------
// Load apachemeta schema from within the ldap-schema Jar with all the
// schema it depends on. This is a minimal mandatory set of schemas.
// -----------------------------------------------------------------------
wrapped.setId( SCHEMA_ID );
wrapped.setSuffixDn( schemaDN );
wrapped.setSchemaManager( schemaManager );
try
{
wrapped.initialize();
synchronizer = new RegistrySynchronizerAdaptor( schemaManager );
}
catch ( Exception e )
{
LOG.error( I18n.err( I18n.ERR_90 ), e );
throw new RuntimeException( e );
}
schemaModificationDN = new Dn( schemaManager, SchemaConstants.SCHEMA_MODIFICATIONS_DN );
}
}
代码示例来源:origin: org.apache.knox/gateway-test-ldap
/**
* Inits the system partition.
*
* @throws Exception the exception
*/
private void initSystemPartition() throws Exception
{
// change the working directory to something that is unique
// on the system and somewhere either under target directory
// or somewhere in a temp area of the machine.
// Inject the System Partition
Partition systemPartition = partitionFactory.createPartition(
directoryService.getSchemaManager(),
//directoryService.getDnFactory(),
"system",
ServerDNConstants.SYSTEM_DN,
500,
new File( directoryService.getInstanceLayout().getPartitionsDirectory(), "system" ) );
systemPartition.setSchemaManager( directoryService.getSchemaManager() );
partitionFactory.addIndex( systemPartition, SchemaConstants.OBJECT_CLASS_AT, 100 );
directoryService.setSystemPartition( systemPartition );
}
代码示例来源:origin: org.apache.directory.server/apacheds-core-annotations
/**
* Inits the system partition.
*
* @throws Exception the exception
*/
private void initSystemPartition() throws Exception
{
// change the working directory to something that is unique
// on the system and somewhere either under target directory
// or somewhere in a temp area of the machine.
// Inject the System Partition
Partition systemPartition = partitionFactory.createPartition( directoryService.getSchemaManager(),
directoryService.getDnFactory(),
"system", ServerDNConstants.SYSTEM_DN, 500,
new File( directoryService.getInstanceLayout().getPartitionsDirectory(), "system" ) );
systemPartition.setSchemaManager( directoryService.getSchemaManager() );
partitionFactory.addIndex( systemPartition, SchemaConstants.OBJECT_CLASS_AT, 100 );
directoryService.setSystemPartition( systemPartition );
}
代码示例来源:origin: org.sonatype.sisu.goodies/goodies-testsupport
.getDnFactory(), "system", ServerDNConstants.SYSTEM_DN, 500, new File(directoryService.getInstanceLayout()
.getPartitionsDirectory(), "system"));
systemPartition.setSchemaManager(directoryService.getSchemaManager());
partitionFactory.addIndex(systemPartition, SchemaConstants.OBJECT_CLASS_AT, 100);
directoryService.setSystemPartition(systemPartition);
directoryService.getDnFactory(), "sonatype", "o=sonatype", 500, new File(directoryService.getInstanceLayout()
.getPartitionsDirectory(), "sonatype"));
sonatypePartition.setSchemaManager(directoryService.getSchemaManager());
partitionFactory.addIndex(sonatypePartition, SchemaConstants.OBJECT_CLASS_AT, 100);
directoryService.addPartition(sonatypePartition);
.getDnFactory(), "groups", "ou=groups,dc=company,dc=com", 500, new File(directoryService.getInstanceLayout()
.getPartitionsDirectory(), "groups"));
groupsPartition.setSchemaManager(directoryService.getSchemaManager());
partitionFactory.addIndex(groupsPartition, SchemaConstants.OBJECT_CLASS_AT, 100);
directoryService.addPartition(groupsPartition);
.getDnFactory(), "users", "ou=users,dc=company,dc=com", 500, new File(directoryService.getInstanceLayout()
.getPartitionsDirectory(), "users"));
usersPartition.setSchemaManager(directoryService.getSchemaManager());
partitionFactory.addIndex(usersPartition, SchemaConstants.OBJECT_CLASS_AT, 100);
directoryService.addPartition(usersPartition);
directoryService.getDnFactory(), "acme_brick", "dc=acme brick,dc=com", 500, new File(directoryService
.getInstanceLayout().getPartitionsDirectory(), "acme_brick"));
acmeBrickPartition.setSchemaManager(directoryService.getSchemaManager());
partitionFactory.addIndex(acmeBrickPartition, SchemaConstants.OBJECT_CLASS_AT, 100);
directoryService.addPartition(acmeBrickPartition);
代码示例来源:origin: org.wildfly/wildfly-testsuite-shared
ServerDNConstants.SYSTEM_DN, 500, new File(directoryService.getInstanceLayout().getPartitionsDirectory(),
"system"));
systemPartition.setSchemaManager(directoryService.getSchemaManager());
partitionFactory.addIndex(systemPartition, SchemaConstants.OBJECT_CLASS_AT, 100);
directoryService.setSystemPartition(systemPartition);
代码示例来源:origin: kwart/ldap-server
directoryService.getDnFactory(), "system", ServerDNConstants.SYSTEM_DN, 500,
new File(directoryService.getInstanceLayout().getPartitionsDirectory(), "system"));
systemPartition.setSchemaManager(directoryService.getSchemaManager());
partitionFactory.addIndex(systemPartition, SchemaConstants.OBJECT_CLASS_AT, 100);
directoryService.setSystemPartition(systemPartition);
代码示例来源:origin: org.apache.directory.server/apacheds-core-annotations
partition.setSchemaManager( schemaManager );
内容来源于网络,如有侵权,请联系作者删除!