msl.examples.loadlib.dotnet64 module
Communicates with a 32-bit .NET library via the DotNet32
class.
Example of a module that can be executed within a 64-bit Python interpreter which can
communicate with a 32-bit .NET library, dotnet_lib32.dll that is
hosted by a 32-bit Python server, dotnet32
. A 64-bit process cannot load a
32-bit library and therefore inter-process communication is used to
interact with a 32-bit library from a 64-bit process.
DotNet64
is the 64-bit client and DotNet32
is the 32-bit server for inter-process communication.
- class msl.examples.loadlib.dotnet64.DotNet64
Bases:
Client64
Communicates with the 32-bit C# dotnet_lib32.dll library.
This class demonstrates how to communicate with a 32-bit .NET library if an instance of this class is created within a 64-bit Python interpreter.
- get_class_names()
Returns the class names in the library.
See the corresponding 32-bit
get_class_names()
method.- Returns:
The names of the classes that are available in dotnet_lib32.dll.
- Return type:
- add_integers(a, b)
Add two integers.
See the corresponding 32-bit
add_integers()
method.
- divide_floats(a, b)
Divide two C# floating-point numbers.
See the corresponding 32-bit
divide_floats()
method.
- multiply_doubles(a, b)
Multiply two C# double-precision numbers.
See the corresponding 32-bit
multiply_doubles()
method.
- add_or_subtract(a, b, do_addition)
Add or subtract two C# double-precision numbers.
See the corresponding 32-bit
add_or_subtract()
method.
- scalar_multiply(a, xin)
Multiply each element in an array by a number.
See the corresponding 32-bit
scalar_multiply()
method.
- multiply_matrices(a1, a2)
Multiply two matrices.
See the corresponding 32-bit
multiply_matrices()
method.
- reverse_string(original)
Reverse a string.
See the corresponding 32-bit
reverse_string()
method.
- add_multiple(a, b, c, d, e)
Add multiple integers. Calls a static method in a static class.
See the corresponding 32-bit
add_multiple()
method.
- concatenate(a, b, c, d, e)
Concatenate strings. Calls a static method in a static class.
See the corresponding 32-bit
concatenate()
method.