/// <summary> /// Returns the RDF schema type for the specified entity interface or implementation type /// </summary> /// <param name="type">The entity interface or implementation type</param> /// <returns>The schema type URI for the entity type</returns> /// <exception cref="MappingNotFoundException">Raised if no mapping is found for <paramref name="type"/></exception> public string MapTypeToUri(Type type) { if (EntityMappingStore.IsMappedImplementation(type)) { return(EntityMappingStore.GetMappedInterfaceTypeUri(type)); } if (EntityMappingStore.IsKnownInterface(type)) { return(EntityMappingStore.GetMappedInterfaceTypeUri(EntityMappingStore.GetImplType(type))); } throw new MappingNotFoundException(type); }
/// <summary> /// Returns the entity implementation type for an entity interface type /// </summary> /// <param name="interfaceType">The entity interface type</param> /// <returns>The mapped entity implementation type, or <paramref name="interfaceType"/> if no mapping is found</returns> public Type GetImplType(Type interfaceType) { return(EntityMappingStore.GetImplType(interfaceType)); }