File: msocket.h

package info (click to toggle)
dbeacon 0.4.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 396 kB
  • sloc: cpp: 2,346; perl: 1,549; makefile: 42; sh: 21
file content (25 lines) | stat: -rw-r--r-- 708 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
/*
 * Copyright 2005-2010, Hugo Santos <hugo@fivebits.net>
 * Distributed under the terms of the MIT License.
 */

#ifndef _msocket_h_
#define _msocket_h_

#include "address.h"

void MulticastStartup();

int MulticastListen(int sock, const address &);
int SSMJoin(int sock, const address &, const address &);
int SSMLeave(int sock, const address &, const address &);

int SetupSocket(const address &, bool bind, bool ssm);
bool SetHops(int sock, const address &, int);
bool RequireToAddress(int sock, const address &);

int RecvMsg(int, address &from, address &to, uint8_t *buffer, int len, int &ttl, uint64_t &ts);
int SendTo(int, const uint8_t *, int len, const address &from, const address &to);

#endif