upipe-modules/upipe_http_source.h header reference

Upipe source module for http GET requests More

Header inclusion [link] 

Members [link] 

Types [link] 

Functions [link] 

Description [link] 

Upipe source module for http GET requests

Members detail [link] 

#define UPIPE_HTTP_SRC_SIGNATURE [link] 

This macro is declared in upipe-modules/upipe_http_source.h source file, line 38.

#define _UPIPE_MODULES_UPIPE_HTTP_SOURCE_H_ [link] 

This macro is declared in upipe-modules/upipe_http_source.h source file, line 31.

enum upipe_http_src_command [link] 

This enum is declared in upipe-modules/upipe_http_source.h source file, line 142.

This enum extends upipe_command with specific commands for http source.

IdentifierValueDescription
UPIPE_HTTP_SRC_SENTINEL0x8000
UPIPE_HTTP_SRC_SET_PROXY1set the http proxy to use (const char *)
UPIPE_HTTP_SRC_SET_TIMEOUT2set the http read/write timeout (uint64_t)
UPIPE_HTTP_SRC_GET_USER_AGENT3get the current user agent (const char **)
UPIPE_HTTP_SRC_SET_USER_AGENT4set the user agent to use (const char *)

const char * upipe_http_src_command_str(int cmd) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 161.

This function converts an enum upipe_http_src_command to a string.

Parameter list:

  • cmd: the enum to convert

The return value is a string

int upipe_http_src_get_user_agent(struct upipe *upipe, const char **user_agent_p) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 193.

This function gets the current user agent.

Parameter list:

  • upipe: description structure of the pipe
  • user_agent_p: filled with the current user agent

The return value is an error code

struct upipe_http_src_hook [link] 

This struct is declared in upipe-modules/upipe_http_source.h source file, line 49.

This struct stores a http source hook.

FieldDescription
struct urefcount * urefcount;refcount on the structure
struct <anonymous> {
int (*read)(struct upipe *upipe, struct upipe_http_src_hook *, int ) ;called when the transport socket is ready for read
int (*write)(struct upipe *upipe, struct upipe_http_src_hook *, int ) ;called when the transport socket is ready for write
} transport;
struct <anonymous> {
ssize_t (*read)(struct upipe *upipe, struct upipe_http_src_hook *, uint8_t *size_t ) ;called when there is data for read
ssize_t (*write)(struct upipe *upipe, struct upipe_http_src_hook *, const uint8_t *size_t ) ;called when there is space for data to write
} data;

enum upipe_http_src_hook_code [link] 

This enum is declared in upipe-modules/upipe_http_source.h source file, line 41.

IdentifierValueDescription
UPIPE_HTTP_SRC_HOOK_TRANSPORT_READ1<<0
UPIPE_HTTP_SRC_HOOK_TRANSPORT_WRITE1<<1
UPIPE_HTTP_SRC_HOOK_DATA_READ1<<2
UPIPE_HTTP_SRC_HOOK_DATA_WRITE1<<3

void upipe_http_src_hook_release(struct upipe_http_src_hook *hook) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 78.

struct upipe_http_src_hook * upipe_http_src_hook_use(struct upipe_http_src_hook *hook) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 71.

struct upipe_mgr * upipe_http_src_mgr_alloc(void ) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 330.

This function returns the management structure for all http sources.

The return value is pointer to manager

enum upipe_http_src_mgr_command [link] 

This enum is declared in upipe-modules/upipe_http_source.h source file, line 225.

This enum extends upipe_mgr_command with specific commands for http source.

IdentifierValueDescription
UPIPE_HTTP_SRC_MGR_SENTINEL0x8000
UPIPE_HTTP_SRC_MGR_GET_PROXY1get the proxy url (const char **)
UPIPE_HTTP_SRC_MGR_SET_PROXY2set the proxy url (const char *)
UPIPE_HTTP_SRC_MGR_SET_COOKIE3add a cookie (const char *)
UPIPE_HTTP_SRC_MGR_ITERATE_COOKIE4iterate over cookies
UPIPE_HTTP_SRC_MGR_GET_USER_AGENT5get user agent (const char **)
UPIPE_HTTP_SRC_MGR_SET_USER_AGENT6set user agent (const char *)

int upipe_http_src_mgr_get_proxy(struct upipe_mgr *mgr, const char **proxy_p) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 265.

This function gets the proxy url to use by default for the new allocated pipes.

Parameter list:

  • mgr: pointer to upipe manager
  • proxy_p: a pointer the proxy url

The return value is an error code

int upipe_http_src_mgr_get_user_agent(struct upipe_mgr *mgr, const char **user_agent_p) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 291.

This function gets the user agent to use by default for newly allocated pipes.

Parameter list:

  • mgr: pointer to upipe manager
  • user_agent_p: a pointer filled with the current user agent

The return value is an error code

int upipe_http_src_mgr_iterate_cookie(struct upipe_mgr *mgr, const char *domain, const char *path, struct uchain **uchain_p) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 321.

This function iterates over the manager cookie list.

Parameter list:

  • mgr: pointer to upipe manager
  • domain: the domain to match
  • path: the path to match
  • uchain_p: iterator

The return value is an error code

int upipe_http_src_mgr_set_cookie(struct upipe_mgr *mgr, const char *string) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 304.

This function adds a cookie in the manager cookie list.

Parameter list:

  • mgr: pointer to upipe manager
  • string: the cookie string to add

The return value is an error code

int upipe_http_src_mgr_set_proxy(struct upipe_mgr *mgr, const char *proxy) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 252.

This function sets the proxy url to use by default for the new allocated pipes.

Parameter list:

  • mgr: pointer to upipe manager
  • proxy: the proxy url

The return value is an error code

int upipe_http_src_mgr_set_user_agent(struct upipe_mgr *mgr, const char *user_agent) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 278.

This function sets the user agent to use by default for newly allocated pipes.

Parameter list:

  • mgr: pointer to upipe manager
  • user_agent: the user_agent

The return value is an error code

int upipe_http_src_set_proxy(struct upipe *upipe, const char *proxy) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 180.

This function sets the http proxy to use.

Parameter list:

  • upipe: description structure of the pipe
  • proxy: the proxy url

The return value is an error code

int upipe_http_src_set_timeout(struct upipe *upipe, uint64_t timeout) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 219.

This function sets the read/write timeout.

Parameter list:

  • upipe: description structure of the pipe
  • timeout: timeout value in 27MHz clock ticks

The return value is an error code

int upipe_http_src_set_user_agent(struct upipe *upipe, const char *user_agent) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 206.

This function sets the user agent to use.

Parameter list:

  • upipe: description structure of the pipe
  • user_agent: user agent to use

The return value is an error code

int upipe_http_src_throw_error(struct upipe *upipe, unsigned int code) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 135.

This function throw an error code event.

Parameter list:

  • upipe: description structure of the pipe
  • code: HTTP error code

The return value is an error code

int upipe_http_src_throw_redirect(struct upipe *upipe, const char *uri) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 122.

This function throw a redirect event.

Parameter list:

  • upipe: description structure of the pipe
  • uri: the temporary uri

The return value is an error code

enum uprobe_http_src_event [link] 

This enum is declared in upipe-modules/upipe_http_source.h source file, line 84.

This enum extends uprobe_event with specific events for http source.

IdentifierValueDescription
UPROBE_HTTP_SRC_SENTINEL0x8000
UPROBE_HTTP_SRC_REDIRECT1request receive a HTTP 302 redirect response with the url (const char *)
UPROBE_HTTP_SRC_ERROR2request receive an error code response with the error code (unsigned int)
UPROBE_HTTP_SRC_SCHEME_HOOK3request for scheme hook (struct uref *, struct upipe_http_src_hook **)

const char * uprobe_http_src_event_str(int event) [link] 

This function is declared in upipe-modules/upipe_http_source.h source file, line 104.

This function converts an enum uprobe_http_src_event to a string.

Parameter list:

  • event: the enum to convert

The return value is a string

Valid XHTML 1.0 StrictGenerated by cmassiot on Sun Dec 14 18:31:17 2025 using MkDoc