Back to project page couchbase-lite-android.
The source code is released under:
Apache License
If you think the Android project couchbase-lite-android listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.couchbase.lite.mockserver; /*w w w. ja v a 2 s.com*/ import com.squareup.okhttp.mockwebserver.MockResponse; import com.squareup.okhttp.mockwebserver.RecordedRequest; public class WrappedSmartMockResponse implements SmartMockResponse { private MockResponse mockResponse; private long delayMs; private boolean sticky; public WrappedSmartMockResponse(MockResponse mockResponse) { this.mockResponse = mockResponse; } public WrappedSmartMockResponse(MockResponse mockResponse, boolean sticky) { this.mockResponse = mockResponse; this.sticky = sticky; } @Override public MockResponse generateMockResponse(RecordedRequest request) { return mockResponse; } @Override public boolean isSticky() { return this.sticky; } public void setSticky(boolean sticky) { this.sticky = sticky; } @Override public long delayMs() { return delayMs; } public void setDelayMs(long delayMs) { this.delayMs = delayMs; } }