@Test public void getConnectionTest() throws IOException { URL url = new URL(DUMMY_URL); HttpURLConnection connection = abstractRESTAdapter.getConnection(url); assertThat(connection.getURL().toExternalForm(), equalTo(DUMMY_URL)); }
public HttpURLConnection getConnection(URL url) throws IOException { return (HttpURLConnection) url.openConnection(); }
AbstractRESTAdapter implements RESTAdapter { public HttpURLConnection getConnection(URL url) throws IOException { return (HttpURLConnection) url.openConnection(); } }
AbstractRESTAdapter implements RESTAdapter { public HttpURLConnection getConnection(URL url) throws IOException { return (HttpURLConnection) url.openConnection(); } protected  AbstractRESTAdapter();  AbstractRESTAdapter(long embeddingVectorSize, int connectTimeout, int readTimeout); }
AbstractRESTAdapter implements RESTAdapter { public HttpURLConnection getConnection(URL url) throws IOException { return (HttpURLConnection) url.openConnection(); } protected  AbstractRESTAdapter();  AbstractRESTAdapter(long embeddingVectorSize, int connectTimeout, int readTimeout); @Override long getEmbeddingVectorSize(); void setEmbeddingVectorSize(long embeddingVectorSize); int getConnectTimeout(); void setConnectTimeout(int connectTimeout); int getReadTimeout(); void setReadTimeout(int readTimeout); @Override double[] encode(String data); abstract double[] encodeImpl(String data); @Override double[][] encode(String[] data); abstract double[][] encodeImpl(String[] data); @Override double[][][] encode(String[][] data); abstract double[][][] encodeImpl(String[][] data); O request(I input, Class<O> classOfO, URL url); HttpURLConnection configureConnection(URL url); @JsonIgnore abstract SerializationProvider getSerializationProvider(); @JsonIgnore abstract DeserializationProvider getDeserializationProvider(); HttpURLConnection getConnection(URL url); }
AbstractRESTAdapter implements RESTAdapter { public HttpURLConnection getConnection(URL url) throws IOException { return (HttpURLConnection) url.openConnection(); } protected  AbstractRESTAdapter();  AbstractRESTAdapter(long embeddingVectorSize, int connectTimeout, int readTimeout); @Override long getEmbeddingVectorSize(); void setEmbeddingVectorSize(long embeddingVectorSize); int getConnectTimeout(); void setConnectTimeout(int connectTimeout); int getReadTimeout(); void setReadTimeout(int readTimeout); @Override double[] encode(String data); abstract double[] encodeImpl(String data); @Override double[][] encode(String[] data); abstract double[][] encodeImpl(String[] data); @Override double[][][] encode(String[][] data); abstract double[][][] encodeImpl(String[][] data); O request(I input, Class<O> classOfO, URL url); HttpURLConnection configureConnection(URL url); @JsonIgnore abstract SerializationProvider getSerializationProvider(); @JsonIgnore abstract DeserializationProvider getDeserializationProvider(); HttpURLConnection getConnection(URL url); static final String HTTP_REQUEST_METHOD; static final String HTTP_CONTENT_TYPE_NAME; static final String HTTP_ACCEPT_TYPE_NAME; }