java.lang.Object
io.quarkus.qute.JavaElementUriBuilder
Builder for Qute-specific URIs that reference a Java element
(class, method, or annotation) from a template.
These URIs have the format:
qute-java://<fully-qualified-class-name>[#method][@annotation]Examples:
- Class-level annotation:
qute-java://com.acme.Bean@io.quarkus.qute.TemplateContents - Method-level annotation:
qute-java://com.acme.Bean#process@io.quarkus.qute.TemplateContents
This builder is used to construct such URIs in a type-safe way and to provide
utility methods to identify and parse them. It is aligned with
.
invalid reference
io.quarkus.qute.debug.client.JavaSourceLocationArguments#javaElementUri
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the Qute Java URI representing the element.static JavaElementUriBuilderCreates a new builder for the given Java class name.Returns the fully qualified Java annotation name (nullable if not specified).Returns the Java method name (nullable if not specified).Returns the fully qualified Java class name for this URI.static booleanReturns true if the given string starts with the qute-java URI prefix.static booleanReturns true if the given URI uses the qute-java scheme.setAnnotation(String annotation) Sets the fully qualified Java annotation name.Sets the Java method name.
-
Field Details
-
QUTE_JAVA_SCHEME
Scheme used for Qute Java URIs.- See Also:
-
QUTE_JAVA_URI_PREFIX
Prefix for Qute Java URIs.- See Also:
-
-
Method Details
-
getTypeName
Returns the fully qualified Java class name for this URI.- Returns:
- the class name
-
getMethod
Returns the Java method name (nullable if not specified).- Returns:
- the method name or
null
-
setMethod
Sets the Java method name.- Parameters:
method- the method name to set- Returns:
- this builder
-
getAnnotation
Returns the fully qualified Java annotation name (nullable if not specified).- Returns:
- the annotation name or
null
-
setAnnotation
Sets the fully qualified Java annotation name.- Parameters:
annotation- the annotation name to set- Returns:
- this builder
-
builder
Creates a new builder for the given Java class name.- Parameters:
typeName- fully qualified Java class name- Returns:
- a new
JavaElementUriBuilder
-
build
Builds the Qute Java URI representing the element.- Returns:
- a
URIfor the Java element
-
isJavaUri
Returns true if the given URI uses the qute-java scheme.- Parameters:
uri- the URI to check- Returns:
trueif this URI is a Qute Java element URI
-
isJavaUri
Returns true if the given string starts with the qute-java URI prefix.- Parameters:
uri- the URI string to check- Returns:
trueif this string is a Qute Java element URI
-