Currently ImportMemoryManagementType used in parameters of methods like setImportSlice is implemented as enum and therefore can be misinterpreted to an integer. SetImportSlice e.g. has 3 integer parameters (s, t, n) where the memmory management value is interpreted as s, t or n instead of managedMemoryType if used incorrectly.
We should make ImportMemoryManagementType a strongly typed enum to prevent users from using these methods incorrectly.