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

org.genx.javadoc.vo.MethodDocVO Maven / Gradle / Ivy

package org.genx.javadoc.vo;

import org.apache.commons.lang3.StringUtils;

import java.util.List;
import java.util.Map;

/**
 * Created with IntelliJ IDEA.
 * Description:
 *
 * @author: genx
 * @date: 2019/3/12 9:35
 */
public class MethodDocVO extends AbsDocVO {

    /**
     * 方法名
     */
    private String methodName;


    /**
     * 参数
     */
    private List params;


    /**
     * 返回类型
     */
    private TypeDoc returnType;


    /**
     * 抛出的异常
     */
    private Map throwExpections;


    public String getMethodName() {
        return methodName;
    }

    public void setMethodName(String methodName) {
        this.methodName = methodName;
    }

    public List getParams() {
        return params;
    }

    public void setParams(List params) {
        this.params = params;
    }

    public boolean hasNoParam() {
        return this.params == null || this.params.size() == 0;
    }

    public TypeDoc getReturnType() {
        return returnType;
    }

    public void setReturnType(TypeDoc returnType) {
        this.returnType = returnType;
    }

    public String getReturnComment() {
        return StringUtils.trimToEmpty(getTag("return"));
    }


    public Map getThrowExpections() {
        return throwExpections;
    }

    public void setThrowExpections(Map throwExpections) {
        this.throwExpections = throwExpections;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy