internal static unsafe NodeTransitionProgress FromNative(IntPtr pointer) { NativeTypes.FABRIC_NODE_TRANSITION_PROGRESS nativeProgress = *(NativeTypes.FABRIC_NODE_TRANSITION_PROGRESS *)pointer; var state = TestCommandStateHelper.FromNative(nativeProgress.State); NodeCommandResult result = null; if (nativeProgress.Result != IntPtr.Zero) { result = new NodeCommandResult(); result.CreateFromNative(nativeProgress.Result); } return(new NodeTransitionProgress(state, result)); }
internal static unsafe PartitionRestartProgress FromNative(IntPtr pointer) { NativeTypes.FABRIC_PARTITION_RESTART_PROGRESS nativeProgress = *(NativeTypes.FABRIC_PARTITION_RESTART_PROGRESS *)pointer; var state = TestCommandStateHelper.FromNative(nativeProgress.State); PartitionRestartResult result = null; if (nativeProgress.Result != IntPtr.Zero) { result = new PartitionRestartResult(); result.CreateFromNative(nativeProgress.Result); } return(new PartitionRestartProgress(state, result)); }