sdaiFindInstanceUsedInBN

The function returns the identifiers of all the entity instances in the defined domain that reference the specified entity instance by the specified attribute (with roleName). Technically sdaiFindInstanceUsedInBN will transform into the following call sdaiFindInstanceUsedIn( instance, sdaiGetAttrDefinition( sdaiGetInstanceType( instance ), roleName ), domain, resultList );

Syntax

public const string enginedll = @"engine.dll";

[DllImport(enginedll, EntryPoint = "sdaiFindInstanceUsedInBN")]
public static extern Int32 x86_sdaiFindInstanceUsedInBN(Int32 instance, string roleName, Int32 domain, Int32 resultList);

[DllImport(enginedll, EntryPoint = "sdaiFindInstanceUsedInBN")]
public static extern Int32 x64_sdaiFindInstanceUsedInBN(Int64 instance, string roleName, Int64 domain, Int64 resultList);

public static Int32 sdaiFindInstanceUsedInBN(Int64 instance, string roleName, Int64 domain, Int64 resultList)
		{
			if (IntPtr.Size == 4)
			{
				var _result = x86_sdaiFindInstanceUsedInBN((Int32)instance, roleName, (Int32)domain, (Int32)resultList);
				return _result;
			}
			else
			{
				return x64_sdaiFindInstanceUsedInBN(instance, roleName, domain, resultList);
			}
		}

[DllImport(enginedll, EntryPoint = "sdaiFindInstanceUsedInBN")]
public static extern Int32 x86_sdaiFindInstanceUsedInBN(Int32 instance, byte[] roleName, Int32 domain, Int32 resultList);

[DllImport(enginedll, EntryPoint = "sdaiFindInstanceUsedInBN")]
public static extern Int32 x64_sdaiFindInstanceUsedInBN(Int64 instance, byte[] roleName, Int64 domain, Int64 resultList);

public static Int32 sdaiFindInstanceUsedInBN(Int64 instance, byte[] roleName, Int64 domain, Int64 resultList)
		{
			if (IntPtr.Size == 4)
			{
				var _result = x86_sdaiFindInstanceUsedInBN((Int32)instance, roleName, (Int32)domain, (Int32)resultList);
				return _result;
			}
			else
			{
				return x64_sdaiFindInstanceUsedInBN(instance, roleName, domain, resultList);
			}
		}    

Property instance

Size: 32 bit / 4 byte (value)
...

Property roleName

Size: 32 bit / 4 byte (reference)
???.

Property domain

Size: 32 bit / 4 byte (reference)
???.

Property resultList

Size: 32 bit / 4 byte (reference)
???.