/// <summary>
        /// Init an instance of the <see cref="I3dSitesGetterWrapper"/> class.
        /// </summary>
        public void Init(Action <I3dLogLevel, string> logCallback, I3dHttpGetCallback callback, IntPtr userdata)
        {
            _logCallback = logCallback;

            int code = i3d_ping_sites_getter_create(out _ptr, callback, userdata);

            I3dErrorValidator.Validate(code);

            code = i3d_ping_sites_getter_set_logger(_ptr, LogCallback, _ptr);
            I3dErrorValidator.Validate(code);

            lock (SitesGetter)
            {
                SitesGetter.Add(_ptr, this);
            }
        }
Esempio n. 2
0
 private static extern int i3d_ping_sites_getter_create(out IntPtr sitesGetter, I3dHttpGetCallback callback, IntPtr userdata);