/** * The syntax checks for the URL values of a DID document. Each check uses the grammar of the * text that defines the value: * * - A DID and a DID URL: the ABNF of DID Core v1.1, sections 3.1 and 3.2. * - A URI and a relative reference: the ABNF of RFC 3986, sections 3 and 4.2. * - A URL: the URL parser of the URL Standard (https://url.spec.whatwg.org/). * * The regular expressions follow the ABNF rule names. ABNF strings are case-insensitive * (RFC 5234, section 2.3), so the `did:` string of the DID ABNF also matches `DID:`. */ /** * Returns true if the value conforms to the DID syntax of DID Core v1.1, section 3.1. * @param {string} value The value. * @returns {boolean} True if the value is a DID. */ export declare function isDid(value: string): boolean; /** * Returns true if the value conforms to the DID URL syntax of DID Core v1.1, section 3.2. A * DID is also a DID URL. * @param {string} value The value. * @returns {boolean} True if the value is a DID URL. */ export declare function isDidUrl(value: string): boolean; /** * Returns true if the value starts with the `did` scheme. The syntax of a URI in the `did` * scheme is the DID URL syntax, so such a value must be a DID URL. * @param {string} value The value. * @returns {boolean} True if the value starts with `did:`. */ export declare function hasDidScheme(value: string): boolean; /** * Returns true if the value starts with a scheme: it is not a relative reference. * @param {string} value The value. * @returns {boolean} True if the value starts with an RFC 3986 scheme and a colon. */ export declare function hasScheme(value: string): boolean; /** * Returns true if the value is an RFC 3986 `URI`: a scheme, a colon, and the other parts. * @param {string} value The value. * @returns {boolean} True if the value is a URI. */ export declare function isUri(value: string): boolean; /** * Returns true if the value is an RFC 3986 `relative-ref`: a reference with no scheme. * @param {string} value The value. * @returns {boolean} True if the value is a relative reference. */ export declare function isRelativeReference(value: string): boolean; /** * Returns true if the URL parser of the URL Standard parses the value with no base URL. * @param {string} value The value. * @returns {boolean} True if the value is an absolute URL. */ export declare function isUrl(value: string): boolean; //# sourceMappingURL=url-syntax.d.ts.map