Search in sources :

Example 1 with MidpointValueMetadataFactory

use of com.evolveum.midpoint.schema.metadata.MidpointValueMetadataFactory in project midpoint by Evolveum.

the class MidPointPrismContextFactory method createPrismContext.

@Override
public PrismContext createPrismContext() throws SchemaException, IOException {
    SchemaRegistryImpl schemaRegistry = createSchemaRegistry();
    PrismContextImpl context = PrismContextImpl.create(schemaRegistry);
    context.setDefinitionFactory(createDefinitionFactory());
    context.setDefaultRelation(SchemaConstants.ORG_DEFAULT);
    context.setObjectsElementName(SchemaConstants.C_OBJECTS);
    context.setDefaultReferenceTypeName(ObjectReferenceType.COMPLEX_TYPE);
    context.setExtensionContainerTypeName(ExtensionType.COMPLEX_TYPE);
    if (InternalsConfig.isPrismMonitoring()) {
        context.setMonitor(new InternalMonitor());
    }
    context.setParsingMigrator(new MidpointParsingMigrator());
    context.setValueMetadataFactory(new MidpointValueMetadataFactory(context));
    context.setProvenanceEquivalenceStrategy(MidpointProvenanceEquivalenceStrategy.INSTANCE);
    context.registerQueryExpressionFactory(new PrismQueryExpressionSupport());
    return context;
}
Also used : InternalMonitor(com.evolveum.midpoint.schema.internals.InternalMonitor) MidpointValueMetadataFactory(com.evolveum.midpoint.schema.metadata.MidpointValueMetadataFactory) PrismContextImpl(com.evolveum.midpoint.prism.impl.PrismContextImpl) SchemaRegistryImpl(com.evolveum.midpoint.prism.impl.schema.SchemaRegistryImpl)

Aggregations

PrismContextImpl (com.evolveum.midpoint.prism.impl.PrismContextImpl)1 SchemaRegistryImpl (com.evolveum.midpoint.prism.impl.schema.SchemaRegistryImpl)1 InternalMonitor (com.evolveum.midpoint.schema.internals.InternalMonitor)1 MidpointValueMetadataFactory (com.evolveum.midpoint.schema.metadata.MidpointValueMetadataFactory)1