Annotation Interface DemoSource
This annotation is used for configuring the source code URL in a
TabbedDemo. If no
value or clazz is specified, and the demo view is annotated with GithubLink,
then the source URL defaults to the location of the annotated class under src/test/java
and the branch is determined from the value of GithubBranch in the demo view class (if
the annotation is present) or the containing package of the demo view class. If the source URL is
defaulted and no GithubBranch annotation is present either in the demo view class or its
containing package, then the branch defaults to master.- Author:
- Javier Godoy / Flowing Code
-
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionThe caption of the source tab (displayed if several sources are provided).Class<?>The class to display, if different from the annotated class.The language used to format the sources.Source code position in the layoutA link to the source code, if different from the annotated class. -
Field Summary
Fields
-
Field Details
-
GITHUB_SOURCE
- See Also:
-
DEFAULT_VALUE
- See Also:
-
-
Element Details
-
value
String valueA link to the source code, if different from the annotated class.It is an error if both
valueandclazz()are specified.- Default:
- "__GITHUB__"
-
clazz
Class<?> clazzThe class to display, if different from the annotated class.It is an error if both
value()andclazzare specified.- Default:
- com.flowingcode.vaadin.addons.demo.DemoSource.class
-
caption
String captionThe caption of the source tab (displayed if several sources are provided). Default to the file name.- Default:
- "__DEFAULT__"
-
language
String languageThe language used to format the sources. By default the language is inferred from the file extension.- Default:
- "__DEFAULT__"
-
sourcePosition
SourcePosition sourcePositionSource code position in the layout- Default:
- SECONDARY
-