%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/local/share/emacs/27.2/lisp/url/
Upload File :
Create Path :
Current File : //usr/local/share/emacs/27.2/lisp/url/url-util.elc

;ELC
;;; Compiled
;;; in Emacs version 27.2
;;; with all optimizations.

;;; This file uses dynamic docstrings, first added in Emacs 19.29.

;;; This file does not contain utf-8 non-ASCII characters,
;;; and so can be loaded in Emacs versions earlier than 23.

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;


(byte-code "\300\301!\210\300\302!\210\303\304\305\"\210\303\306\305\"\210\303\307\310\"\207" [require url-parse url-vars autoload timezone-parse-date "timezone" timezone-make-date-arpa-standard mail-header-extract "mailheader"] 3)
#@45 A syntax table for parsing sgml attributes.
(defvar url-parse-args-syntax-table (copy-syntax-table emacs-lisp-mode-syntax-table) (#$ . 640))
(byte-code "\301\302\303#\210\301\304\303#\210\301\305\306#\210\301\307\310#\210\311\312\313\314\315DD\316\317\320\321\322&\207" [url-parse-args-syntax-table modify-syntax-entry 39 "\"" 96 123 "(" 125 ")" custom-declare-variable url-debug funcall function #[0 "\300\207" [nil] 1] "What types of debug messages from the URL library to show.\nDebug messages are logged to the *URL-DEBUG* buffer.\n\nIf t, all messages will be logged.\nIf a number, all messages will be logged, as well shown via `message'.\nIf a list, it is a list of the types of messages to be logged." :type (choice (const :tag "none" nil) (const :tag "all" t) (checklist :tag "custom" (const :tag "HTTP" :value http) (const :tag "DAV" :value dav) (const :tag "General" :value retrieval) (const :tag "Filename handlers" :value handlers) (symbol :tag "Other"))) :group url-hairy] 8)
#@23 

(fn TAG &rest ARGS)
(defalias 'url-debug #[385 "\301=\204\247\204<\2055>\2055r\302\303!q\210db\210\304!\305\306\307\"\310\261\210\247\2054\306\311\")\207" [url-debug t get-buffer-create "*URL-DEBUG*" symbol-name " -> " apply format "\n" message] 7 (#$ . 1641)])
#@33 

(fn STR &optional NODOWNCASE)
(defalias 'url-parse-args #[513 "\301\211\211\211\211\302\303!r\211q\210\304\305\306\307\310!\311\"\312$\216c\210\313!\210eb\210m\204\254\314\301w\210`\262\315\301w\210\204<\316`\"\210`{\262\317\301w\210`f\206K\305\320U\204V\301\262\202\236\321\301w\210`\262f\206c\305\322U\204sf\206n\305\323U\203\221T\3241\207\325\326!\210`S\327\301w\2100\202\215\210\330\301w\210`{\202\234\331\301w\210\332\301x\210`{\262BB\262\314\301w\210\202#*\262\207" [url-parse-args-syntax-table nil generate-new-buffer " *temp*" make-byte-code 0 "\301\300!\205	\302\300!\207" vconcat vector [buffer-name kill-buffer] 2 set-syntax-table "; \n	" "^ \n	=;" downcase-region " 	\n" 61 " 	\n=" 34 39 (error) forward-sexp 1 "\"" "^ 	\n" "^;" " 	"] 14 (#$ . 1928)])
#@351 Convert HTML markup-start characters to entity references in STRING.
Also replaces the " character, so that the result may be safely used as
an attribute value in a tag.  Returns a new string with the result of the
conversion.  Replaces these characters as follows:
    &  ==>  &amp;
    <  ==>  &lt;
    >  ==>  &gt;
    "  ==>  &quot;

(fn STRING)
(defalias 'url-insert-entities-in-string #[257 "\300\301\"\2034r\302\303!q\210\304 \210\305p!\210\211c\210eb\210\306\307w\210m\2040`f\310\236Ac\210\311\312!\210\202\313 )\207\207" [string-match "[&<>\"]" get-buffer-create " *entity*" erase-buffer buffer-disable-undo "^&<>\"" nil ((34 . "&quot;") (38 . "&amp;") (60 . "&lt;") (62 . "&gt;")) delete-char 1 buffer-string] 4 (#$ . 2738)])
#@87 Return a "normalized" version of URL.
Strips out default port numbers, etc.

(fn URL)
(defalias 'url-normalize-url #[257 "\301\211\211\302!\262\303!>\204\304\305\306D\"\210\307H\262\310\235\203(\262\202C\303!>\2047\304\305\306D\"\210\211\311\301I\266\312!\262\207" [cl-struct-url-tags nil url-generic-parse-url type-of signal wrong-type-argument url 1 ("www" "about" "mailto" "info") 7 url-recreate-url] 8 (#$ . 3485)])
#@139 Just like `message', but is a no-op if called more than once a second.
Will not do anything if `url-show-status' is nil.

(fn &rest ARGS)
(defalias 'url-lazy-message #[128 "\203\304!	>\204\305\306\307D\"\210\310H\206+\n?\206+\311 \206+\312\313\314\"\211U?\2053\315\316\"\207" [url-current-object cl-struct-url-tags url-show-status url-lazy-message-time type-of signal wrong-type-argument url 10 active-minibuffer-window time-convert nil integer apply message] 5 (#$ . 3934)])
#@92 Return a date string that most HTTP servers can understand.

(fn &optional SPECIFIED-TIME)
(defalias 'url-get-normalized-date #[256 "\301\302\303\304#)\207" [system-time-locale "C" format-time-string "%a, %d %b %Y %T GMT" t] 5 (#$ . 4431)])
#@52 Remove spaces/tabs at the end of a string.

(fn X)
(defalias 'url-eat-trailing-space #[257 "\211GS\300\301\302E\303Y\203H>\203S\262\202\304\303T#\207" [32 9 10 0 substring] 7 (#$ . 4680)])
#@49 Remove spaces at the front of a string.

(fn X)
(defalias 'url-strip-leading-spaces #[257 "\211GS\300\301\302\303EX\203H>\203T\262\202\304\305#\207" [0 32 9 10 substring nil] 8 (#$ . 4889)])
(byte-code "\300\301\302\303#\210\304\301\302\305#\207" [defalias url-pretty-length file-size-human-readable nil make-obsolete "24.4"] 4)
#@28 

(fn FMT PERC &rest ARGS)
(defalias 'url-display-percentage #[642 "\205A	\203\303	!\n>\204\304\305\306	D\"\210	\307H?\205A\204+\310\311!\205A\311 \207\310\312!\203<\203<\313\312$\207\313\314#\207" [url-show-status url-current-object cl-struct-url-tags type-of signal wrong-type-argument url 10 fboundp clear-progress-display progress-display apply message] 8 (#$ . 5239)])
#@12 

(fn X Y)
(defalias 'url-percentage #[514 "\300\301!\203\302\303\301!\245_!\207\303_\245\207" [fboundp float round 100] 7 (#$ . 5637)])
(defalias 'url-basepath 'url-file-directory)
#@58 Return the directory part of FILE, for a URL.

(fn FILE)
(defalias 'url-file-directory #[257 "\211\204\300\207\301\302\"\203\303\304\305\211\224#!\207\301\306\"\205!\307\310\"\207" ["" string-match "\\?" url-file-directory substring 0 "\\(.*\\(/\\|%2[fF]\\)\\)" match-string 1] 6 (#$ . 5831)])
#@61 Return the nondirectory part of FILE, for a URL.

(fn FILE)
(defalias 'url-file-nondirectory #[257 "\211\204\300\207\301\302\"\203\303\304\305\211\224#!\207\301\306\"\203\"\307\310\"\207\207" ["" string-match "\\?" url-file-nondirectory substring 0 ".*\\(?:/\\|%2[fF]\\)\\(.*\\)" match-string 1] 6 (#$ . 6140)])
#@48 

(fn QUERY &optional DOWNCASE ALLOW-NEWLINES)
(defalias 'url-parse-query-string #[769 "\300\211\211\211\211\301\302\"\262\203k@\262A\262\303\304\"\204$\304P\262\303\304\"\203\f\305\306\307\211\224#\"\262\305\306\307\225\300#\"\262\203L\227\262\310\"\262\203aAB\241\210\202\fDB\262\202\f\207" [nil split-string "[;&]" string-match "=" url-unhex-string substring 0 assoc] 13 (#$ . 6467)])
#@555 Build a query-string.

Given a QUERY in the form:
 ((key1 val1)
  (key2 val2)
  (key3 val1 val2)
  (key4)
  (key5 ""))

(This is the same format as produced by `url-parse-query-string')

This will return a string
"key1=val1&key2=val2&key3=val1&key3=val2&key4&key5". Keys may
be strings or symbols; if they are symbols, the symbol name will
be used.

When SEMICOLONS is given, the separator will be ";".

When KEEP-EMPTY is given, empty values will show as "key="
instead of just "key" as in the example above.

(fn QUERY &optional SEMICOLONS KEEP-EMPTY)
(defalias 'url-build-query-string #[769 "\300\301\302\303\304\305\"\306\"\307\310%\203\311\202\312#\207" [mapconcat make-byte-code 257 "\302\303\"\304\305\306\307\310\311\301\"\312\"\313\314%A\206\315\300\203!\316\202\"\317#\207" vconcat vector [mapcar #[257 "\300\301\302\"!\207" [url-hexify-string format "%s"] 5 "\n\n(fn SYM)"] mapconcat make-byte-code 257 "\302\303\"\302\303\301@\"\211\300\204\203G\304U\204\305\202\306Q\207" vconcat vector [format "%s" 0 "=" #1=""] 6 "\n\n(fn VAL)" (#1#) ";" "&"] 10 "\n\n(fn KEY-VALS)" ";" "&"] 11 (#$ . 6906)])
#@10 

(fn X)
(defalias 'url-unhex #[257 "\211\300V\203\211\301Y\203\302\301Z\\\207\302\303Z\\\207\211\304Z\207" [57 97 10 65 48] 4 (#$ . 8050)])
#@252 Remove %XX embedded spaces, etc in a URL.
If optional second argument ALLOW-NEWLINES is non-nil, then allow the
decoding of carriage returns and line feeds in the string, which is normally
forbidden in URL encoding.

(fn STR &optional ALLOW-NEWLINES)
(defalias 'url-unhex-string #[513 "\206\301\262\301\302\303\304\"\203[\305\224\306T\234!\307_\306\310\\\234!\\\311\305#\2038\312!\202K\313U\204D\314U\203H\315\202K\312!Q\262\311\305\225\"\262\266\202\n\211P)\207" [case-fold-search "" t string-match "%[0-9a-f][0-9a-f]" 0 url-unhex 16 2 substring byte-to-string 10 13 " "] 11 (#$ . 8204)])
#@100 List of characters that are unreserved in the URL spec.
This is taken from RFC 3986 (section 2.3).
(defconst url-unreserved-chars '(97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 48 49 50 51 52 53 54 55 56 57 45 95 46 126) (#$ . 8837))
#@54 Vector translating bytes to URI-encoded %-sequences.
(defconst url-encoding-table (byte-code "\300\301\302\"\301\303\211W\203\211\304\305\"I\266\211T\262\202\266\211\207" [make-vector 256 nil 0 format "%%%02X"] 9) (#$ . 9211))
#@200 Return an "allowed character" mask (a 256-slot vector).
The Nth element is non-nil if character N is in CHAR-LIST.  The
result can be passed as the second arg to `url-hexify-string'.

(fn CHAR-LIST)
(defalias 'url--allowed-chars #[257 "\300\301\302\"\211\203#\211@\3031\304I0\202\210\202\210A\266\202\202\210\211\207" [make-vector 256 nil (error) t] 7 (#$ . 9456)])
#@606 URI-encode STRING and return the result.
If STRING is multibyte, it is first converted to a utf-8 byte
string.  Each byte corresponding to an allowed character is left
as-is, while all other bytes are converted to a three-character
string: "%" followed by two upper-case hex digits.

The allowed characters are specified by ALLOWED-CHARS.  If this
argument is nil, the list `url-unreserved-chars' determines the
allowed characters.  Otherwise, ALLOWED-CHARS should be either a
list of allowed chars, or a vector whose Nth element is non-nil
if character N is allowed.

(fn STRING &optional ALLOWED-CHARS)
(defalias 'url-hexify-string #[513 "\211C\211\242\203\301\242!\204\211\302\242!\240\210\202\211\302!\240\210\303\304\305\306\307\310!\311\"\312\313%\314!\2039\315\316\"\202:\317#\207" [url-unreserved-chars vectorp url--allowed-chars mapconcat make-byte-code 257 "\300\242H\203\302!\207	H\207" vconcat vector [url-encoding-table char-to-string] 3 "\n\n(fn BYTE)" multibyte-string-p encode-coding-string utf-8 ""] 10 (#$ . 9842)])
#@116 Allowed-character byte mask for the host segment of a URI.
These characters are specified in RFC 3986, Appendix A.
(defconst url-host-allowed-chars (byte-code "\301\302\303\"!\207" [url-unreserved-chars url--allowed-chars append (37 33 36 38 39 40 41 42 43 44 59 61)] 4) (#$ . 10904))
#@116 Allowed-character byte mask for the path segment of a URI.
These characters are specified in RFC 3986, Appendix A.
(defconst url-path-allowed-chars (byte-code "\301!\211\302\303I\210\211\304\303I\210\211\305\303I\210\211\207" [url-host-allowed-chars copy-sequence 47 t 58 64] 4) (#$ . 11197))
#@117 Allowed-character byte mask for the query segment of a URI.
These characters are specified in RFC 3986, Appendix A.
(defconst url-query-allowed-chars (byte-code "\301!\211\302\303I\210\211\207" [url-path-allowed-chars copy-sequence 63 t] 4) (#$ . 11498))
#@264 Return a properly URI-encoded version of URL.
This function also performs URI normalization, e.g. converting
the scheme to lowercase if it is uppercase.  Apart from
normalization, if URL is already URI-encoded, this function
should return it unchanged.

(fn URL)
(defalias 'url-encode-url #[257 "\303!\304!>\204\305\306\307D\"\210\211\310H\304!>\204$\305\306\307D\"\210\311H\312!\211@A\304!>\204?\305\306\307D\"\210\313H\203b\304!>\204W\305\306\307	D\"\210\211\310\314	!I\266\203\202\304!>\204w\305\306\307	D\"\210\211\311\314!I\266\203\214\314	\"\262\203\226\314\n\"\262\304!>\204\247\305\306\307	D\"\210\211\315\203\267\316Q\202\270I\266\211\203\333\304!>\204\320\305\306\307	D\"\210\211\313\314\n\"I\266\317!\207" [cl-struct-url-tags url-path-allowed-chars url-query-allowed-chars url-generic-parse-url type-of signal wrong-type-argument url 2 3 url-path-and-query 7 url-hexify-string 6 "?" url-recreate-url] 14 (#$ . 11761)])
#@164 Return the filename extension of FNAME.
If optional argument X is t, then return the basename
of the file with the extension stripped off.

(fn FNAME &optional X)
(defalias 'url-file-extension #[513 "\203&\300!\211\262\203&\301\302\"\203&\211\203\303\304\211\224#\207\303\304\224\305#\207\211\203,\207\306\207" [url-file-nondirectory string-match "\\.[^./]+$" substring 0 nil ""] 6 (#$ . 12776)])
#@143 Return a shortened version of URL that is WIDTH characters wide or less.
WIDTH defaults to the current frame width.

(fn URL &optional WIDTH)
(defalias 'url-truncate-url-for-viewing #[513 "\211\206\301 G\302\303\302Y\203)\304\305\"\203)\306\303\211\224#\307P\262G\262W\204\270\310!\262\311!>\204D\312\313\314D\"\210\211\315H\262\316Z\262Y\203\212\304\317\"\203\212\306\303\225\302#\262T\262\311!>\204v\312\313\314D\"\210\211\211\315I\266\320!\262G\262\202N\321V\203\230\322P\262\202\235\317P\262\311!>\204\254\312\313\314D\"\210\211\211\315I\266\320!\262\207" [cl-struct-url-tags frame-width nil 0 string-match "\\?" substring "?..." url-generic-parse-url type-of signal wrong-type-argument url 6 4 "/" url-recreate-url 1 "/.../"] 11 (#$ . 13193)])
#@204 View the current document's URL.
Optional argument NO-SHOW means just return the URL, don't show it in
the minibuffer.

This uses `url-current-object', set locally to the buffer.

(fn &optional NO-SHOW)
(defalias 'url-view-url #[256 "\205\211\203\f\301!\207\302\303\301!\"\207" [url-current-object url-recreate-url message "%s"] 5 (#$ . 14015) nil])
#@28 Valid characters in a URL.
(defvar url-get-url-filename-chars "-%.?@a-zA-Z0-9()_/:~=&" (#$ . 14377))
#@146 Get the URL closest to point, but don't change position.
Has a preference for looking backward when not directly on a symbol.

(fn &optional PT)
(defalias 'url-get-url-at-point #[256 "\212\211\203\211b\210\302\211\212m\204 \303\304!\203 \305\302x\210o\204 \306u\210`f\203@\307\310\311Q\312`f!\"\203@\302x\210`\262\302w\210\202C`\262\313`\"\262)\211\203[\307\314\"\203[\315\316\"\262\211\203m\307\317\"\203m\320\321\302#\262\211\203\307\322\"\203\320\323\306#\262\211\203\217\307\324\"\203\217\325P\262\211\203\235\307	\"\204\235\302\262\262)\207" [url-get-url-filename-chars url-nonrelative-link nil looking-at "[] 	\n[{}()]" " \n	
({[]})" -1 string-match "[" "]" char-to-string buffer-substring-no-properties "^(\\(.*\\))\\.?$" match-string 1 "^URL:" substring 4 "\\.$" 0 "^www\\." "http://"] 7 (#$ . 14485)])
(make-obsolete 'url-get-url-at-point 'thing-at-point-url-at-point "27.1")
#@78 Generate a unique filename in `url-temporary-directory'.

(fn &optional FMT)
(defalias 'url-generate-unique-filename #[256 "\2044\301\302\303 \"\304\305\301\306#\262\307\310\"!\203+\211T\262\311!P\262\202\310\"\266\203\202g\312\311\303 !P\304\305\301\311!P\"\262\307\310\"!\203a\211T\262\301\311!P\"\262\202F\310\"\266\203\207" [url-temporary-directory format "url-tmp.%d" user-real-uid "" 0 "%s%d" file-exists-p expand-file-name int-to-string "url"] 10 (#$ . 15418)])
(make-obsolete 'url-generate-unique-filename 'make-temp-file "23.1")
#@51 Set `url-current-mime-headers' in current buffer.
(defalias 'url-extract-mime-headers #[0 "\212eb\210?\205\301\300!\210\302 \211)\207" [url-current-mime-headers make-local-variable mail-header-extract] 2 (#$ . 15997)])
#@132 Make FILE only readable and writable by the current user.
Creates FILE and its parent directories if they do not exist.

(fn FILE)
(defalias 'url-make-private-file #[257 "\300!\211\203\f\301\302\"\210\210\3031H\304 \305\306\307\310\311!\312\"\313$\216\314\315!\210\316\317!r\211q\210\305\306\320\310\311!\321\"\313$\216\322ed\323\324\323\325&*\262)\2620\207\210\326!\203T\327\330\"\210\331\315\"\207" [file-name-directory make-directory t (file-already-exists) default-file-modes make-byte-code 0 "\301\300!\207" vconcat vector [set-default-file-modes] 2 set-default-file-modes 384 generate-new-buffer " *temp*" "\301\300!\205	\302\300!\207" [buffer-name kill-buffer] write-region nil silent excl file-symlink-p error "Danger: `%s' is a symbolic link" set-file-modes] 11 (#$ . 16227)])
(byte-code "\300\301\302\"\210\300\303\304\"\207" [autoload puny-encode-domain "puny" url-domsuf-cookie-allowed-p "url-domsuf"] 3)
#@185 Return the domain of the host of the URL.
Return nil if this can't be determined.

For instance, this function will return "fsf.co.uk" if the host in URL
is "www.fsf.co.uk".

(fn URL)
(defalias 'url-domain #[257 "\301\302!>\204\303\304\305D\"\210\306H!\307\310\"\237\211A\262\242\311\312\313\"\203*\311\262\203B\314\211A\262\242\315Q\211\262!\211\262\203*\211\205G\207" [cl-struct-url-tags puny-encode-domain type-of signal wrong-type-argument url 4 split-string "\\." nil string-match "\\`[0-9.]+\\'" url-domsuf-cookie-allowed-p "."] 9 (#$ . 17166)])
(provide 'url-util)

Zerion Mini Shell 1.0