Some code hygiene.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@6045 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -143,7 +143,7 @@ public class GenServiceTask extends InvocationTask
|
|||||||
@Override
|
@Override
|
||||||
public boolean equals (Object other)
|
public boolean equals (Object other)
|
||||||
{
|
{
|
||||||
return getClass().equals(other.getClass()) &&
|
return (other != null) && getClass().equals(other.getClass()) &&
|
||||||
listener.equals(((ServiceListener)other).listener);
|
listener.equals(((ServiceListener)other).listener);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -263,11 +263,6 @@ public abstract class InvocationTask extends Task
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
public int compareTo (ServiceMethod other)
|
|
||||||
{
|
|
||||||
return getCode().compareTo(other.getCode());
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getUnwrappedArgList (boolean listenerMode)
|
public String getUnwrappedArgList (boolean listenerMode)
|
||||||
{
|
{
|
||||||
StringBuilder buf = new StringBuilder();
|
StringBuilder buf = new StringBuilder();
|
||||||
@@ -315,6 +310,24 @@ public abstract class InvocationTask extends Task
|
|||||||
hint.type().name() + ", " + hint.channel() + ")";
|
hint.type().name() + ", " + hint.channel() + ")";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// from interface Comparator<ServiceMethod>
|
||||||
|
public int compareTo (ServiceMethod other)
|
||||||
|
{
|
||||||
|
return getCode().compareTo(other.getCode());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override // from Object
|
||||||
|
public boolean equals (Object other)
|
||||||
|
{
|
||||||
|
return (other instanceof ServiceMethod) && compareTo((ServiceMethod)other) == 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override // from Object
|
||||||
|
public int hashCode ()
|
||||||
|
{
|
||||||
|
return getCode().hashCode();
|
||||||
|
}
|
||||||
|
|
||||||
protected String boxArgument (Class<?> clazz, int index)
|
protected String boxArgument (Class<?> clazz, int index)
|
||||||
{
|
{
|
||||||
if (_ilistener.isAssignableFrom(clazz)) {
|
if (_ilistener.isAssignableFrom(clazz)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user