diff options
Diffstat (limited to 'toxcore/tox.api.h')
-rw-r--r-- | toxcore/tox.api.h | 97 |
1 files changed, 49 insertions, 48 deletions
diff --git a/toxcore/tox.api.h b/toxcore/tox.api.h index 87c3219a..fcd43f7a 100644 --- a/toxcore/tox.api.h +++ b/toxcore/tox.api.h | |||
@@ -854,7 +854,7 @@ enum class CONNECTION { | |||
854 | } | 854 | } |
855 | 855 | ||
856 | 856 | ||
857 | inline namespace self { | 857 | namespace self { |
858 | 858 | ||
859 | CONNECTION connection_status { | 859 | CONNECTION connection_status { |
860 | /** | 860 | /** |
@@ -908,7 +908,7 @@ void iterate(any user_data); | |||
908 | ******************************************************************************/ | 908 | ******************************************************************************/ |
909 | 909 | ||
910 | 910 | ||
911 | inline namespace self { | 911 | namespace self { |
912 | 912 | ||
913 | uint8_t[ADDRESS_SIZE] address { | 913 | uint8_t[ADDRESS_SIZE] address { |
914 | /** | 914 | /** |
@@ -986,7 +986,7 @@ error for set_info { | |||
986 | } | 986 | } |
987 | 987 | ||
988 | 988 | ||
989 | inline namespace self { | 989 | namespace self { |
990 | 990 | ||
991 | uint8_t[length <= MAX_NAME_LENGTH] name { | 991 | uint8_t[length <= MAX_NAME_LENGTH] name { |
992 | /** | 992 | /** |
@@ -1226,7 +1226,7 @@ namespace friend { | |||
1226 | 1226 | ||
1227 | } | 1227 | } |
1228 | 1228 | ||
1229 | inline namespace self { | 1229 | namespace self { |
1230 | 1230 | ||
1231 | uint32_t[size] friend_list { | 1231 | uint32_t[size] friend_list { |
1232 | /** | 1232 | /** |
@@ -1514,8 +1514,14 @@ namespace friend { | |||
1514 | * | 1514 | * |
1515 | ******************************************************************************/ | 1515 | ******************************************************************************/ |
1516 | 1516 | ||
1517 | error for set_typing { | ||
1518 | /** | ||
1519 | * The friend number did not designate a valid friend. | ||
1520 | */ | ||
1521 | FRIEND_NOT_FOUND, | ||
1522 | } | ||
1517 | 1523 | ||
1518 | inline namespace self { | 1524 | namespace self { |
1519 | 1525 | ||
1520 | bool typing { | 1526 | bool typing { |
1521 | /** | 1527 | /** |
@@ -1528,12 +1534,7 @@ inline namespace self { | |||
1528 | * | 1534 | * |
1529 | * @return true on success. | 1535 | * @return true on success. |
1530 | */ | 1536 | */ |
1531 | set(uint32_t friend_number) { | 1537 | set(uint32_t friend_number) with error for set_typing; |
1532 | /** | ||
1533 | * The friend number did not designate a valid friend. | ||
1534 | */ | ||
1535 | FRIEND_NOT_FOUND, | ||
1536 | } | ||
1537 | } | 1538 | } |
1538 | 1539 | ||
1539 | } | 1540 | } |
@@ -2655,36 +2656,36 @@ namespace conference { | |||
2655 | 2656 | ||
2656 | namespace friend { | 2657 | namespace friend { |
2657 | 2658 | ||
2658 | inline namespace send { | 2659 | error for custom_packet { |
2660 | NULL, | ||
2661 | /** | ||
2662 | * The friend number did not designate a valid friend. | ||
2663 | */ | ||
2664 | FRIEND_NOT_FOUND, | ||
2665 | /** | ||
2666 | * This client is currently not connected to the friend. | ||
2667 | */ | ||
2668 | FRIEND_NOT_CONNECTED, | ||
2669 | /** | ||
2670 | * The first byte of data was not in the specified range for the packet type. | ||
2671 | * This range is 200-254 for lossy, and 160-191 for lossless packets. | ||
2672 | */ | ||
2673 | INVALID, | ||
2674 | /** | ||
2675 | * Attempted to send an empty packet. | ||
2676 | */ | ||
2677 | EMPTY, | ||
2678 | /** | ||
2679 | * Packet data length exceeded $MAX_CUSTOM_PACKET_SIZE. | ||
2680 | */ | ||
2681 | TOO_LONG, | ||
2682 | /** | ||
2683 | * Packet queue is full. | ||
2684 | */ | ||
2685 | SENDQ, | ||
2686 | } | ||
2659 | 2687 | ||
2660 | error for custom_packet { | 2688 | namespace send { |
2661 | NULL, | ||
2662 | /** | ||
2663 | * The friend number did not designate a valid friend. | ||
2664 | */ | ||
2665 | FRIEND_NOT_FOUND, | ||
2666 | /** | ||
2667 | * This client is currently not connected to the friend. | ||
2668 | */ | ||
2669 | FRIEND_NOT_CONNECTED, | ||
2670 | /** | ||
2671 | * The first byte of data was not in the specified range for the packet type. | ||
2672 | * This range is 200-254 for lossy, and 160-191 for lossless packets. | ||
2673 | */ | ||
2674 | INVALID, | ||
2675 | /** | ||
2676 | * Attempted to send an empty packet. | ||
2677 | */ | ||
2678 | EMPTY, | ||
2679 | /** | ||
2680 | * Packet data length exceeded $MAX_CUSTOM_PACKET_SIZE. | ||
2681 | */ | ||
2682 | TOO_LONG, | ||
2683 | /** | ||
2684 | * Packet queue is full. | ||
2685 | */ | ||
2686 | SENDQ, | ||
2687 | } | ||
2688 | 2689 | ||
2689 | /** | 2690 | /** |
2690 | * Send a custom lossy packet to a friend. | 2691 | * Send a custom lossy packet to a friend. |
@@ -2762,7 +2763,14 @@ namespace friend { | |||
2762 | ******************************************************************************/ | 2763 | ******************************************************************************/ |
2763 | 2764 | ||
2764 | 2765 | ||
2765 | inline namespace self { | 2766 | error for get_port { |
2767 | /** | ||
2768 | * The instance was not bound to any port. | ||
2769 | */ | ||
2770 | NOT_BOUND, | ||
2771 | } | ||
2772 | |||
2773 | namespace self { | ||
2766 | 2774 | ||
2767 | uint8_t[PUBLIC_KEY_SIZE] dht_id { | 2775 | uint8_t[PUBLIC_KEY_SIZE] dht_id { |
2768 | /** | 2776 | /** |
@@ -2781,13 +2789,6 @@ inline namespace self { | |||
2781 | } | 2789 | } |
2782 | 2790 | ||
2783 | 2791 | ||
2784 | error for get_port { | ||
2785 | /** | ||
2786 | * The instance was not bound to any port. | ||
2787 | */ | ||
2788 | NOT_BOUND, | ||
2789 | } | ||
2790 | |||
2791 | 2792 | ||
2792 | uint16_t udp_port { | 2793 | uint16_t udp_port { |
2793 | /** | 2794 | /** |