net.sf.mmm.util.reflect.api
Class Arguments

java.lang.Object
  extended by net.sf.mmm.util.reflect.api.Arguments

public class Arguments
extends Object

This class represents an argument list. It is a container for an Object array and can be used as hash-key.

Since:
1.0.1
Author:
Joerg Hohwiller (hohwille at users.sourceforge.net)

Field Summary
private  Object[] args
          the wrapped signature
private  int hash
          bleeding edge performance hack
static Arguments NO_ARGS
          the void signature for a non-arg method
 
Constructor Summary
Arguments(Object... arguments)
          The constructor.
 
Method Summary
 boolean equals(Object other)
          
 Object getArgument(int position)
          This method gets the argument at the given position.
 int getArgumentCount()
          This method gets the number of arguments.
 int hashCode()
          
 String toString()
          
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

NO_ARGS

public static final Arguments NO_ARGS
the void signature for a non-arg method


args

private final Object[] args
the wrapped signature


hash

private final int hash
bleeding edge performance hack

Constructor Detail

Arguments

public Arguments(Object... arguments)
The constructor.

Parameters:
arguments - are the signature to wrap.
Method Detail

getArgumentCount

public int getArgumentCount()
This method gets the number of arguments.

Returns:
the type count.

getArgument

public Object getArgument(int position)
This method gets the argument at the given position.

Parameters:
position - is the index of the requested type. This value must be in the range from 0 to getArgumentCount() - 1.
Returns:
the argument at the given index.

hashCode

public int hashCode()

Overrides:
hashCode in class Object

equals

public boolean equals(Object other)

Overrides:
equals in class Object

toString

public String toString()

Overrides:
toString in class Object


Copyright © 2001-2010 mmm-Team. All Rights Reserved.