Skip to main content

Basic Usage

Signature

Configuration Options

Required Properties

Optional Properties

URI Template Syntax

Templates support two RFC 6570 operators:
  • {var}: Level 1 simple expansion. It matches one path segment (no /), and the value is percent-encoded when the URI is built.
  • {+var}: Level 2 reserved expansion. It can span several segments, so files://{+path} matches files://docs/a/b.txt with path = "docs/a/b.txt", and reserved characters such as / pass through unencoded.
Other operators ({#var}, {?var}, {&var}, {;var}, {.var}, {/var}) are not supported.

Parameter Extraction

Parameters are extracted automatically and passed to execute():

Function-Based Alternative

vs Static Resource

Full Example

@Resource

Static resources

ResourceContext

Context class details

ResourceRegistry

Resource registry API

Resource Errors

Resource-related errors