com.volcengine.model.ServiceInfo Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of volc-sdk-java Show documentation
Show all versions of volc-sdk-java Show documentation
The VOLC Engine SDK for Java
package com.volcengine.model;
import com.volcengine.helper.Const;
import lombok.Data;
import org.apache.http.Header;
import java.util.List;
import java.util.Map;
import static com.volcengine.helper.Const.*;
@Data
public class ServiceInfo {
private int connectionTimeout;
private int socketTimeout;
private String scheme;
private String host;
private List header;
private Credentials credentials;
public ServiceInfo(Map params) {
this.connectionTimeout = ((Integer) params.get(CONNECTION_TIMEOUT)) == null ? 0: (Integer) params.get(CONNECTION_TIMEOUT);
this.socketTimeout = ((Integer) params.get(SOCKET_TIMEOUT)) == null ? 0 : (Integer) params.get(SOCKET_TIMEOUT);
this.scheme = ((String) params.get(Scheme)) == null ? "http" : ((String) params.get(Scheme));
this.host = (String) params.get(Host);
this.header = (List) params.get(Const.Header);
this.credentials = (Credentials) params.get(Const.Credentials);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy