// Set the up-stream tally notifications. This returns FALSE if we are not currently connected to anything. That // said, the moment that we do connect to something it will automatically be sent the tally state. public static bool recv_set_tally(IntPtr p_instance, ref tally_t p_tally) { if (IntPtr.Size == 8) { return(UnsafeNativeMethods.recv_set_tally_64(p_instance, ref p_tally)); } else { return(UnsafeNativeMethods.recv_set_tally_32(p_instance, ref p_tally)); } }
// Determine the current tally sate. If you specify a timeout then it will wait until it has changed, otherwise it will simply poll it // and return the current tally immediately. The return value is whether anything has actually change (true) or whether it timed out (false) public static bool send_get_tally(IntPtr p_instance, ref tally_t p_tally, UInt32 timeout_in_ms) { if (IntPtr.Size == 8) { return(UnsafeNativeMethods.send_get_tally_64(p_instance, ref p_tally, timeout_in_ms)); } else { return(UnsafeNativeMethods.send_get_tally_32(p_instance, ref p_tally, timeout_in_ms)); } }
internal static extern bool recv_set_tally_32(IntPtr p_instance, ref tally_t p_tally);
internal static extern bool send_get_tally_32(IntPtr p_instance, ref tally_t p_tally, UInt32 timeout_in_ms);
public static extern bool recv_set_tally(IntPtr p_instance, ref tally_t p_tally);