示例#1
0
文件: SVM.cs 项目: oloopy/LibSVMsharp
        /// <summary>
        ///
        /// </summary>
        /// <param name="function"></param>
        public static void SetPrintStringFunction(SVMPrintFunction function)
        {
            throw new NotImplementedException("There is an issue about this method in the github page of this library. Please visit 'https://github.com/ccerhan/LibSVMsharp/issues/1' and solve the issue and send a pull request.");

            IntPtr ptr_function = Marshal.GetFunctionPointerForDelegate(function);

            libsvm.svm_set_print_string_function(ptr_function);

            //Marshal.FreeHGlobal(ptr_function);
            //ptr_function = IntPtr.Zero;
        }
示例#2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="function"></param>
        public static void SetPrintStringFunction(SVMPrintFunction function)
        {
            // Not working

            IntPtr ptr_function = Marshal.GetFunctionPointerForDelegate(function);

            libsvm.svm_set_print_string_function(ptr_function);

            Marshal.FreeHGlobal(ptr_function);
            ptr_function = IntPtr.Zero;
        }
示例#3
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="function"></param>
        public static void SetPrintStringFunction(SVMPrintFunction function)
        {
            if (function == null)
            {
                throw new ArgumentNullException("function");
            }

            IntPtr ptr_function = Marshal.GetFunctionPointerForDelegate(function);

            libsvm.svm_set_print_string_function(ptr_function);
        }
示例#4
0
        /// <summary>
        /// 
        /// </summary>
        /// <param name="function"></param>
        public static void SetPrintStringFunction(SVMPrintFunction function)
        {
            throw new NotImplementedException("There is an issue about this method in the github page of this library. Please visit 'https://github.com/ccerhan/LibSVMsharp/issues/1' and solve the issue and send a pull request.");

            IntPtr ptr_function = Marshal.GetFunctionPointerForDelegate(function);
            libsvm.svm_set_print_string_function(ptr_function);

            //Marshal.FreeHGlobal(ptr_function);
            //ptr_function = IntPtr.Zero;
        }