---
name: "lo_Server"
section: "3"
platform: "linux"
package: "liblo"
version: "1:0.36-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/lo_Server"
---

# lo\_Server(3)

Class representing a local OSC server, proxy for lo\_server.

## NAME

lo::Server - Class representing a local OSC server, proxy for **lo\_server**.

## SYNOPSIS

\#include \<lo\_cpp.h\>

Inherited by **lo::ServerThread**.

### Public Member Functions

**Server** (**lo\_server** s)\
 template\<typename E\> **Server** (const num\_string\_type &port, E &&e)\
 template\<typename E\> **Server** (const num\_string\_type &port, int proto, E &&e=0)\
 template\<typename E\> **Server** (const string\_type &group, const num\_string\_type &port, const string\_type &iface=0, const string\_type &ip=0, E &&e=0)\
 **Server** (const num\_string\_type &port, **lo\_err\_handler** err\_h=0)\
 **Server** (const num\_string\_type &port, int proto, **lo\_err\_handler** err\_h=0)\
 **Server** (const string\_type &group, const num\_string\_type &port, const string\_type &iface='', const string\_type &ip='', **lo\_err\_handler** err\_h=0)\
 virtual **~Server** ()\
 **Method** **add\_method** (const string\_type &path, const string\_type &types, **lo\_method\_handler** h, void \*data) const\
 **LO\_ADD\_METHOD** ((const char \*, const char \*, **lo\_arg** \*\*, int),((char \*) 0,(char \*) 0,(**lo\_arg** \*\*) 0,(int) 0),(path, types, argv, argc))\
 **LO\_ADD\_METHOD** ((const char \*, **lo\_arg** \*\*, int),((char \*) 0,(**lo\_arg** \*\*) 0,(int) 0),(types, argv, argc))\

## Detailed Description

Class representing a local OSC server, proxy for **lo\_server**.

Definition at line **502** of file **lo\_cpp.h**.

## Constructor & Destructor Documentation

### lo::Server::Server (lo\_server s) \[inline\]

Constructor.

Definition at line **506** of file **lo\_cpp.h**.

Referenced by **Server()**, **Server()**, **Server()**, **Server()**, **Server()**, and **Server()**.

### template\<typename E\> lo::Server::Server (const num\_string\_type & port, E && e) \[inline\]

Constructor taking an error handler.

Definition at line **510** of file **lo\_cpp.h**.

References **lo\_server\_new()**, and **Server()**.

### template\<typename E\> lo::Server::Server (const num\_string\_type & port, int proto, E && e = 0) \[inline\]

Constructor taking a port number and error handler.

Definition at line **527** of file **lo\_cpp.h**.

References **lo\_server\_new\_with\_proto()**, and **Server()**.

### template\<typename E\> lo::Server::Server (const string\_type & group, const num\_string\_type & port, const string\_type & iface = 0, const string\_type & ip = 0, E && e = 0) \[inline\]

Constructor taking a multicast group, port number, interface identifier or IP, and error handler.

Definition at line **545** of file **lo\_cpp.h**.

References **lo\_server\_new\_multicast\_iface()**, and **Server()**.

### lo::Server::Server (const num\_string\_type & port, lo\_err\_handler err\_h = 0) \[inline\]

Constructor taking a port number and error handler.

Definition at line **568** of file **lo\_cpp.h**.

References **lo\_server\_new()**, and **Server()**.

### lo::Server::Server (const num\_string\_type & port, int proto, lo\_err\_handler err\_h = 0) \[inline\]

Constructor taking a port number, protocol, and error handler.

Definition at line **572** of file **lo\_cpp.h**.

References **lo\_server\_new\_with\_proto()**, and **Server()**.

### lo::Server::Server (const string\_type & group, const num\_string\_type & port, const string\_type & iface = '', const string\_type & ip = '', lo\_err\_handler err\_h = 0) \[inline\]

Constructor taking a multicast group, port number, interface identifier or IP, and error handler.

Definition at line **578** of file **lo\_cpp.h**.

References **lo\_server\_new\_multicast()**, **lo\_server\_new\_multicast\_iface()**, and **Server()**.

### virtual lo::Server::~Server () \[inline\], \[virtual\]

Destructor

Definition at line **587** of file **lo\_cpp.h**.

References **lo\_server\_free()**.

## Member Function Documentation

### Method lo::Server::add\_method (const string\_type & path, const string\_type & types, lo\_method\_handler h, void \* data) const \[inline\]

Add a method to handle a given path and type, with a handler and user data pointer.

Definition at line **596** of file **lo\_cpp.h**.

### lo::Server::LO\_ADD\_METHOD ((const char \*, const char \*, lo\_arg \*\*, int) , ((char \*) 0,(char \*) 0,(lo\_arg \*\*) 0,(int) 0) , (path, types, argv, argc) )

Add a method to handle a given path and type, with a handler taking (argv, argc), user data.

### lo::Server::LO\_ADD\_METHOD ((const char \*, lo\_arg \*\*, int) , ((char \*) 0,(lo\_arg \*\*) 0,(int) 0) , (types, argv, argc) )

Add a method to handle a given path and type, with a handler taking (types, argv, argc), user data.

## Author

Generated automatically by Doxygen for liblo from the source code.
