public abstract class RestSampleDataProvider<T,A> extends Object implements org.mule.sdk.api.data.sample.SampleDataProvider<T,A>
| Modifier and Type | Field and Description |
|---|---|
protected RestConnection |
connection |
protected org.mule.runtime.api.el.ExpressionLanguage |
expressionLanguage |
| Constructor and Description |
|---|
RestSampleDataProvider() |
| Modifier and Type | Method and Description |
|---|---|
protected org.mule.runtime.api.el.BindingContext |
buildContext(org.mule.runtime.api.metadata.TypedValue<?> payload) |
protected org.mule.runtime.api.metadata.MediaType |
getDefaultResponseMediaType() |
String |
getId() |
protected abstract RequestParameterBinding |
getParameterBinding()
Returns the parameter binding configuration of this RestPollingSource.
|
protected abstract org.mule.runtime.api.util.MultiMap<String,org.mule.runtime.api.metadata.TypedValue<?>> |
getParameterValues()
Returns a MultiMap containing all the parameters this source exposes to the user.
|
protected abstract String |
getPathTemplate()
Returns the request path for this RestSampleDataProvider with placeholders for its uri parameters.
|
protected abstract RestRequestBuilder |
getRequestBuilder(String path)
Return a RequestBuilder configured to do the request to the endpoint this source must poll.
|
protected org.mule.runtime.extension.api.runtime.operation.Result<org.mule.runtime.api.metadata.TypedValue<String>,HttpResponseAttributes> |
getResult() |
org.mule.sdk.api.runtime.operation.Result<T,A> |
getSample() |
@Connection protected RestConnection connection
@Inject protected org.mule.runtime.api.el.ExpressionLanguage expressionLanguage
public String getId()
public org.mule.sdk.api.runtime.operation.Result<T,A> getSample() throws org.mule.sdk.api.data.sample.SampleDataException
protected org.mule.runtime.extension.api.runtime.operation.Result<org.mule.runtime.api.metadata.TypedValue<String>,HttpResponseAttributes> getResult()
protected abstract String getPathTemplate()
protected abstract RestRequestBuilder getRequestBuilder(String path)
path - The request path with the placeholders replaced with its corresponding values.protected abstract RequestParameterBinding getParameterBinding()
protected abstract org.mule.runtime.api.util.MultiMap<String,org.mule.runtime.api.metadata.TypedValue<?>> getParameterValues()
protected org.mule.runtime.api.metadata.MediaType getDefaultResponseMediaType()
protected org.mule.runtime.api.el.BindingContext buildContext(org.mule.runtime.api.metadata.TypedValue<?> payload)
Copyright © 2021. All rights reserved.