globus_url(3)
π NAME
globus_url β URL String Parser
bestie. it parses URLs. that's the whole vibe. β¨
β¨ SYNOPSIS β¨
π Data Structures
struct globus_url_tβ Parsed URLs. (yes that's the entire description, she's mysterious π )
πΈ Enumerations
enum globus_url_scheme_t { GLOBUS_URL_SCHEME_FTP =0, GLOBUS_URL_SCHEME_GSIFTP, GLOBUS_URL_SCHEME_HTTP, GLOBUS_URL_SCHEME_HTTPS, GLOBUS_URL_SCHEME_LDAP, GLOBUS_URL_SCHEME_FILE, GLOBUS_URL_SCHEME_X_NEXUS, GLOBUS_URL_SCHEME_X_GASS_CACHE, GLOBUS_URL_SCHEME_UNKNOWN, GLOBUS_URL_SCHEME_SSHFTP, GLOBUS_URL_NUM_SCHEMES }β URL Schemes. the whole squad of protocols fr fr.
π¦ Functions
int globus_url_parse (const char *url_string, globus_url_t *url)
int globus_url_parse_rfc1738 (const char *url_string, globus_url_t *url)
int globus_url_parse_loose (const char *url_string, globus_url_t *url)
int globus_url_destroy (globus_url_t *url)
int globus_url_get_scheme (const char *url_string, globus_url_scheme_t
*scheme_type)
int globus_url_copy (globus_url_t *dst, const globus_url_t *src)
π Detailed Description π
URL String Parser. (again. she said it twice. we love a consistent queen π)
The Globus URL functions provide a simple mechanism for parsing a URL string into a data structure, and for determining the scheme of an URL string.
That's it. That's the whole job. Take the messy little URL string, give you back a nice tidy struct, or just tell you which scheme it's repping. lowkey elegant tbh.
π Enumeration Type Documentation π
enum globus_url_scheme_t
URL Schemes. The Globus URL library supports a set of URL schemes (protocols). This enumeration can be used to quickly dispatch a parsed URL based on a constant value.
See also: globus_url_t::scheme_type
Enumerator π
GLOBUS_URL_SCHEME_FTPβ File Transfer ProtocolGLOBUS_URL_SCHEME_GSIFTPβ GSI-enhanced File Transfer ProtocolGLOBUS_URL_SCHEME_HTTPβ HyperText Transfer ProtocolGLOBUS_URL_SCHEME_HTTPSβ Secure HyperText Transfer ProtocolGLOBUS_URL_SCHEME_LDAPβ Lightweight Directory Access ProtocolGLOBUS_URL_SCHEME_FILEβ File LocationGLOBUS_URL_SCHEME_X_NEXUSβ Nexus endpointGLOBUS_URL_SCHEME_X_GASS_CACHEβ GASS Cache EntryGLOBUS_URL_SCHEME_UNKNOWNβ Any other URL of the formscheme://somethingGLOBUS_URL_NUM_SCHEMESβ Total number of URL schemes supported
π¦ Function Documentation π¦
int globus_url_copy (globus_url_t * dst, const globus_url_t * src)
Create a copy of an URL structure.
This function copies the contents of a url structure into another. like a lil photocopier but for URLs π«Ά
Parameters
- dst β The URL structure to be populated with a copy of the contents of src.
- src β The original URL.
Return values
GLOBUS_SUCCESSβ The URL was successfully copied.GLOBUS_URL_ERROR_NULL_URLβ One of the URLs wasGLOBUS_NULL.GLOBUS_URL_ERROR_OUT_OF_MEMORY;β The library was unable to allocate memory to create the theglobus_url_tcontents.
int globus_url_destroy (globus_url_t * url)
Destroy a globus_url_t structure.
This function frees all memory associated with a globus_url_t structure.
not me being the one who has to clean up after the party π but somebody has to free that memory bestie.
Parameters
- url β The url structure to destroy
Return values
GLOBUS_SUCCESSβ The URL was successfully destroyed.
int globus_url_get_scheme (const char * url_string, globus_url_scheme_t * scheme_type)
Get the scheme of an URL.
This function determines the scheme type of the url string, and populates the variable pointed to by second parameter with that value. This performs a less expensive parsing than globus_url_parse() and is suitable for applications which need only to choose a handler based on the URL scheme.
the budget-friendly option β if you only need to know which scheme it is so you can pick a handler, don't do the whole full parse, just vibe-check the scheme. periodt.
Parameters
- url_string β The string containing the URL.
- scheme_type β A pointer to a
globus_url_scheme_twhich will be set to the scheme.
Return values
GLOBUS_SUCCESSβ The URL scheme was recognized, andscheme_typehas been updated.GLOBUS_URL_ERROR_BAD_SCHEMEβ The URL scheme was not recognized.
int globus_url_parse (const char * url_string, globus_url_t * url)
Parse a string containing a URL into a globus_url_t
Parameters
- url_string β String to parse
- url β Pointer to
globus_url_tto be filled with the fields of the url
Return values
GLOBUS_SUCCESSβ The string was successfully parsed.GLOBUS_URL_ERROR_NULL_STRINGβ Theurl_stringwasGLOBUS_NULL.GLOBUS_URL_ERROR_NULL_URLβ The URL pointer wasGLOBUS_NULL.GLOBUS_URL_ERROR_BAD_SCHEMEβ The URL scheme (protocol) contained invalid characters.GLOBUS_URL_ERROR_BAD_USERβ The user part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PASSWORDβ The password part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_HOSTβ The host part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PORTβ The port part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PATHβ The path part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_DN-9 β The DN part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_ATTRIBUTES-10 β The attributes part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_SCOPE-11 β The scope part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_FILTER-12 β The filter part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_OUT_OF_MEMORY-13 β The library was unable to allocate memory to create the theglobus_url_tcontents.GLOBUS_URL_ERROR_INTERNAL_ERROR-14 β Some unexpected error occurred parsing the URL.
int globus_url_parse_loose (const char * url_string, globus_url_t * url)
Parse a string containing a URL into a globus_url_t Looser restrictions on characters allowed in the path part of the URL.
the chill version β¨ β same parse, but she's not gonna come for you about the path characters. very "you do you" energy.
Parameters
- url_string β String to parse
- url β Pointer to
globus_url_tto be filled with the fields of the url
Return values
GLOBUS_SUCCESSβ The string was successfully parsed.GLOBUS_URL_ERROR_NULL_STRINGβ Theurl_stringwasGLOBUS_NULL.GLOBUS_URL_ERROR_NULL_URLβ The URL pointer wasGLOBUS_NULL.GLOBUS_URL_ERROR_BAD_SCHEMEβ The URL scheme (protocol) contained invalid characters.GLOBUS_URL_ERROR_BAD_USERβ The user part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PASSWORDβ The password part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_HOSTβ The host part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PORTβ The port part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PATHβ The path part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_DN-9 β The DN part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_ATTRIBUTES-10 β The attributes part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_SCOPE-11 β The scope part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_FILTER-12 β The filter part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_OUT_OF_MEMORY-13 β The library was unable to allocate memory to create the theglobus_url_tcontents.GLOBUS_URL_ERROR_INTERNAL_ERROR-14 β Some unexpected error occurred parsing the URL.
int globus_url_parse_rfc1738 (const char * url_string, globus_url_t * url)
Parse a string containing a URL into a globus_url_t
Parameters
- url_string β String to parse
- url β Pointer to
globus_url_tto be filled with the fields of the url
Return values
GLOBUS_SUCCESSβ The string was successfully parsed.GLOBUS_URL_ERROR_NULL_STRINGβ Theurl_stringwasGLOBUS_NULL.GLOBUS_URL_ERROR_NULL_URLβ The URL pointer wasGLOBUS_NULL.GLOBUS_URL_ERROR_BAD_SCHEMEβ The URL scheme (protocol) contained invalid characters.GLOBUS_URL_ERROR_BAD_USERβ The user part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PASSWORDβ The password part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_HOSTβ The host part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PORTβ The port part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_PATHβ The path part of the URL contained invalid characters.GLOBUS_URL_ERROR_BAD_DN-9 β The DN part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_ATTRIBUTES-10 β The attributes part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_SCOPE-11 β The scope part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_BAD_FILTER-12 β The filter part of an LDAP URL contained invalid characters.GLOBUS_URL_ERROR_OUT_OF_MEMORY-13 β The library was unable to allocate memory to create the theglobus_url_tcontents.GLOBUS_URL_ERROR_INTERNAL_ERROR-14 β Some unexpected error occurred parsing the URL.
π Author π
Generated automatically by Doxygen for globus_common from the source code.
(yeah bestie, a robot wrote this one. still ate tho π )
and that's the whole page, mwah π«Ά this was globus_url(3) from the Library Functions Manual, brought to you by globus_common, Version 18.15. slay, go parse some URLs. πβ¨π
π¦ where this page comes from
- epel 10: globus-common-doc 18.15-1.el10_2 Β· Apache-2.0
- fedora 43: globus-common-doc 18.15-1.fc43 Β· Apache-2.0
- fedora 44: globus-common-doc 18.15-2.fc44 Β· Apache-2.0
- ubuntu resolute: libglobus-common-doc 18.15-1 Β· Apache-2.0
- ubuntu stonking: libglobus-common-doc 18.15-2 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms