Search in sources :

Example 1 with SoftTypeRef

use of org.talend.mdm.commmon.metadata.SoftTypeRef in project tmdm-common by Talend.

the class ForeignKeyProcessor method handleForeignKey.

private void handleForeignKey(MetadataRepository repository, ComplexTypeMetadata type, XmlSchemaAnnotationProcessorState state, Element appInfo) {
    state.markAsReference();
    String path = appInfo.getTextContent();
    FieldMetadata fieldMetadata = getFieldMetadata(repository, type, appInfo, path, false);
    state.setReferencedField(fieldMetadata);
    // Only reference instantiable types.
    state.setReferencedType(new SoftTypeRef(repository, repository.getUserNamespace(), getTypeName(type, path), true));
}
Also used : FieldMetadata(org.talend.mdm.commmon.metadata.FieldMetadata) SoftTypeRef(org.talend.mdm.commmon.metadata.SoftTypeRef)

Aggregations

FieldMetadata (org.talend.mdm.commmon.metadata.FieldMetadata)1 SoftTypeRef (org.talend.mdm.commmon.metadata.SoftTypeRef)1