All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.nervousync.proxy.ProxyConfig Maven / Gradle / Ivy

There is a newer version: 1.2.1
Show newest version
/*
 * Licensed to the Nervousync Studio (NSYC) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You under the Apache License, Version 2.0
 * (the "License"); you may not use this file except in compliance with
 * the License.  You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.nervousync.proxy;

import java.net.Proxy.Type;

import jakarta.xml.bind.annotation.*;
import org.nervousync.beans.core.BeanObject;
import org.nervousync.commons.Globals;

/**
 * 

Proxy server configure

*

代理服务器配置信息

* * @author Steven Wee [email protected] * @version $Revision: 1.0.0 $ $Date: Jan 4, 2018 16:05:54 $ */ @XmlType(name = "proxy_config", namespace = "https://nervousync.org/schemas/proxy") @XmlRootElement(name = "proxy_config", namespace = "https://nervousync.org/schemas/proxy") @XmlAccessorType(XmlAccessType.NONE) public final class ProxyConfig extends BeanObject { /** * Serial version UID * 序列化UID */ private static final long serialVersionUID = -5386443812775715018L; /** * Enumeration value of proxy type * 代理服务器类型枚举值 */ @XmlElement(name = "type") private Type proxyType = Type.DIRECT; /** * Proxy server address * 代理服务器地址 */ @XmlElement(name = "address") private String proxyAddress = Globals.DEFAULT_VALUE_STRING; /** * Proxy server port * 代理服务器端口号 */ @XmlElement(name = "port") private int proxyPort = Globals.DEFAULT_VALUE_INT; /** * Authenticate username * 身份认证用户名 */ @XmlElement(name = "username") private String userName = Globals.DEFAULT_VALUE_STRING; /** * Authenticate password * 身份认证密码 */ @XmlElement(name = "password") private String password = Globals.DEFAULT_VALUE_STRING; /** *

Constructor method for ProxyConfig

*

ProxyConfig构造方法

*/ public ProxyConfig() { } /** *

Static method for create redirect ProxyConfig instance

*

静态方法用于创建无代理的代理服务器配置信息实例对象

* * @return Generated ProxyConfig instance * 生成的代理服务器配置信息实例对象 */ public static ProxyConfig redirect() { return new ProxyConfig(); } /** *

Getter method for proxy type

*

代理服务器类型的Getter方法

* * @return Enumeration value of proxy type * 代理服务器类型枚举值 */ public Type getProxyType() { return proxyType; } /** *

Setter method for proxy type

*

代理服务器类型的Setter方法

* * @param proxyType Enumeration value of proxy type * 代理服务器类型枚举值 */ public void setProxyType(Type proxyType) { this.proxyType = proxyType; } /** *

Getter method for proxy type

*

代理服务器类型的Getter方法

* * @return Proxy server address * 代理服务器地址 */ public String getProxyAddress() { return proxyAddress; } /** *

Setter method for proxy type

*

代理服务器类型的Setter方法

* * @param proxyAddress Proxy server address * 代理服务器地址 */ public void setProxyAddress(String proxyAddress) { this.proxyAddress = proxyAddress; } /** *

Getter method for proxy type

*

代理服务器类型的Getter方法

* * @return Proxy server port * 代理服务器端口号 */ public int getProxyPort() { return proxyPort; } /** *

Setter method for proxy type

*

代理服务器类型的Setter方法

* * @param proxyPort Proxy server port * 代理服务器端口号 */ public void setProxyPort(int proxyPort) { this.proxyPort = proxyPort; } /** *

Getter method for proxy type

*

代理服务器类型的Getter方法

* * @return Authenticate username * 身份认证用户名 */ public String getUserName() { return userName; } /** *

Setter method for proxy type

*

代理服务器类型的Setter方法

* * @param userName Authenticate username * 身份认证用户名 */ public void setUserName(String userName) { this.userName = userName; } /** *

Getter method for proxy type

*

代理服务器类型的Getter方法

* * @return Authenticate password * 身份认证密码 */ public String getPassword() { return password; } /** *

Setter method for proxy type

*

代理服务器类型的Setter方法

* * @param password Authenticate password * 身份认证密码 */ public void setPassword(String password) { this.password = password; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy