![JAR search and dependency download from the Maven repository](/logo.png)
com.sap.cloud.yaas.servicesdk.springboot.apiconsole.ApiConsoleProperties Maven / Gradle / Ivy
/*
* © 2017 SAP SE or an SAP affiliate company.
* All rights reserved.
* Please see http://www.sap.com/corporate-en/legal/copyright/index.epx for additional trademark information and
* notices.
*/
package com.sap.cloud.yaas.servicesdk.springboot.apiconsole;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import com.sap.cloud.yaas.servicesdk.springboot.filter.FilterRegistrationPropertiesBase;
import org.springframework.boot.context.properties.ConfigurationProperties;
import java.net.URI;
import java.util.Collection;
import java.util.List;
/**
* Properties used to configure the (embedded or stand-alone) RAML API Console.
*/
@ConfigurationProperties(prefix = "yaas.service.api-console")
public class ApiConsoleProperties extends FilterRegistrationPropertiesBase
{
/**
* The path at which the embedded RAML API Console will be served.
*/
@NotNull
@Pattern(regexp = "^/[-_.!~*'()/$%a-zA-Z0-9]*/")
private String basePath = "/api-console/";
/**
* The (absolute) URI of an external stand-alone API Console to redirect to.
* If omitted, the embedded RAML API Console at base-path will be used.
*/
private URI uri;
/**
* The URI of the RAML to load into the API Console.
* Can be absolute ore relative, where the latter is interpreted as relative to the web application.
*/
private URI ramlUri = URI.create("/meta-data/api.raml?expand=full");
/**
* URI path patterns that should be redirected to the API Console.
* If omitted, the following defaults will be used:
* - the root path of the web-application,
* - the base-path of the embedded API Console.
*/
private List redirectPatterns;
public String getBasePath()
{
return basePath;
}
public void setBasePath(final String basePath)
{
this.basePath = basePath;
}
public URI getUri()
{
return uri;
}
public void setUri(final URI uri)
{
this.uri = uri;
}
public URI getRamlUri()
{
return ramlUri;
}
public void setRamlUri(final URI ramlUri)
{
this.ramlUri = ramlUri;
}
public Collection getRedirectPatterns()
{
return redirectPatterns;
}
public void setRedirectPatterns(final List redirectUrlPatterns)
{
this.redirectPatterns = redirectUrlPatterns;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy