io.github.kiryu1223.expressionTree.expressions.ParameterExpression Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ExpressionTree Show documentation
Show all versions of ExpressionTree Show documentation
java static expressionTree
package io.github.kiryu1223.expressionTree.expressions;
public class ParameterExpression extends Expression
{
private final Class> type;
private final String name;
public ParameterExpression(Class> type, String name)
{
this.type = type;
this.name = name;
}
public Class> getType()
{
return type;
}
public String getName()
{
return name;
}
@Override
public Kind getKind()
{
return Kind.Parameter;
}
@Override
public String toString()
{
return name;
}
@Override
public boolean equals(Object obj)
{
if (this == obj) return true;
if (obj == null || getClass() != obj.getClass()) return false;
ParameterExpression that = (ParameterExpression) obj;
return type.equals(that.type) && name.equals(that.name);
}
}