UriSavingArgs

UriSavingArgs class

Provides information and controls for customizing how a resource URI is written during document-to-Markdown conversion. An instance of this class is created for each resource and can be used to override the default URI or file name.

public class UriSavingArgs

Properties

Name Description
ResourceFileName { get; } Gets the default file name (without path) generated by the library for this resource.
ResourceFileNameOutput { get; } Gets the overridden file name set by the caller, or null if no override was specified.
ResourceFileUri { get; } Gets the default resource URI that the library would write into the Markdown output.
ResourceFileUriOutput { get; } Gets the overridden URI set by SetResourceFileUri, or null if no override was specified.

Methods

Name Description
SetResourceFileUri(string) Overrides the URI that will be written to the Markdown output for this resource.

Remarks

Call SetResourceFileUri to change the URI that appears in the Markdown output. If no override is set, the library uses the default ResourceFileUri.

Examples

Rewriting a resource URI in a callback:

// Inside a custom URI export callback
args.SetResourceFileUri("https://cdn.example.com/assets/" + args.ResourceFileName);

See Also