本文整理汇总了Java中org.springframework.hateoas.TemplateVariables类的典型用法代码示例。如果您正苦于以下问题:Java TemplateVariables类的具体用法?Java TemplateVariables怎么用?Java TemplateVariables使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
TemplateVariables类属于org.springframework.hateoas包,在下文中一共展示了TemplateVariables类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: InitializrMetadataV2JsonMapper
import org.springframework.hateoas.TemplateVariables; //导入依赖的package包/类
public InitializrMetadataV2JsonMapper() {
this.templateVariables = new TemplateVariables(
new TemplateVariable("dependencies",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("packaging",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("javaVersion",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("language",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("edorasoneVersion",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("groupId",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("artifactId",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("version",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("name", TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("shortName", TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("description",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("packageName",
TemplateVariable.VariableType.REQUEST_PARAM));
}
示例2: InitializrMetadataV2JsonMapper
import org.springframework.hateoas.TemplateVariables; //导入依赖的package包/类
public InitializrMetadataV2JsonMapper() {
this.templateVariables = new TemplateVariables(
new TemplateVariable("dependencies",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("packaging",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("javaVersion",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("language",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("bootVersion",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("groupId",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("artifactId",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("version",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("name", TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("description",
TemplateVariable.VariableType.REQUEST_PARAM),
new TemplateVariable("packageName",
TemplateVariable.VariableType.REQUEST_PARAM));
}
示例3: InitializrMetadataV21JsonMapper
import org.springframework.hateoas.TemplateVariables; //导入依赖的package包/类
public InitializrMetadataV21JsonMapper() {
this.dependenciesVariables = new TemplateVariables(
new TemplateVariable("edorasoneVersion",
TemplateVariable.VariableType.REQUEST_PARAM)
);
}
示例4: createPaginatedResourceLink
import org.springframework.hateoas.TemplateVariables; //导入依赖的package包/类
private Link createPaginatedResourceLink(Link link) {
String href = link.getHref();
UriComponents components = UriComponentsBuilder.fromUriString(href).build();
TemplateVariables variables = resolver.getPaginationTemplateVariables(null, components);
return new Link(new UriTemplate(href, variables), link.getRel());
}
示例5: InitializrMetadataV21JsonMapper
import org.springframework.hateoas.TemplateVariables; //导入依赖的package包/类
public InitializrMetadataV21JsonMapper() {
this.dependenciesVariables = new TemplateVariables(
new TemplateVariable("bootVersion",
TemplateVariable.VariableType.REQUEST_PARAM)
);
}