net.sf.csutils.groovy
Class GroovyObjects

java.lang.Object
  extended by net.sf.csutils.groovy.GroovyObjects

public class GroovyObjects
extends Object


Constructor Summary
GroovyObjects()
           
 
Method Summary
static void checkNoArgs(String pMethodName, Object pArgs)
          Checks, whether the given argument is suitable for a method taking no arguments.
static void checkNoArgs(String pMethodName, Object[] pArgs)
          Checks, whether the given argument is suitable for a method taking no arguments.
static String checkStringArg(String pMethodName, Object[] pArgs)
          Checks, whether the given signature contains a single string.
static Locale getLocaleArg(String pMethodName, Object pArgs)
          Converts the given arguments into a locale.
static Locale getLocaleArg(String pMethodName, Object[] pArgs)
          Converts the given arguments into a locale.
static String getStringArg(String pMethodName, Object pArgs)
          Converts the given arguments into a string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GroovyObjects

public GroovyObjects()
Method Detail

getLocaleArg

public static Locale getLocaleArg(String pMethodName,
                                  Object[] pArgs)
Converts the given arguments into a locale.

Parameters:
pMethodName - The method name; will be used for error messages, if required.
pArgs - The method arguments.
Returns:
A locale matching the arguments.

getLocaleArg

public static Locale getLocaleArg(String pMethodName,
                                  Object pArgs)
Converts the given arguments into a locale.

Parameters:
pMethodName - The method name; will be used for error messages, if required.
pArgs - The method arguments.
Returns:
A locale matching the arguments.

getStringArg

public static String getStringArg(String pMethodName,
                                  Object pArgs)
Converts the given arguments into a string.

Parameters:
pMethodName - The method name; will be used for error messages, if required.
pArgs - The method arguments.
Returns:
The converted arguments.

checkNoArgs

public static void checkNoArgs(String pMethodName,
                               Object pArgs)
Checks, whether the given argument is suitable for a method taking no arguments.

Parameters:
pMethodName - The method name; will be used for error messages, if required.
pArgs - The method arguments.

checkNoArgs

public static void checkNoArgs(String pMethodName,
                               Object[] pArgs)
Checks, whether the given argument is suitable for a method taking no arguments.

Parameters:
pMethodName - The method name; will be used for error messages, if required.
pArgs - The method arguments.

checkStringArg

public static String checkStringArg(String pMethodName,
                                    Object[] pArgs)
Checks, whether the given signature contains a single string.

Parameters:
pMethodName - The method name; will be used for error messages, if required.
pArgs - The method arguments.
Returns:
The string, which has been found in the argument list.


Copyright © 2009-2010. All Rights Reserved.