public static String toStringScope ( int scope , String defaultValue ) { switch ( scope ) { case Scope . SCOPE_APPLICATION : return "application" ; case Scope . SCOPE_ARGUMENTS : return "arguments" ; case Scope . SCOPE_CALLER : return "caller" ; case Scope . SCOPE_CGI : return "cgi" ; case Scope . SCOPE_CLIENT : return "client" ; case Scope . SCOPE_COOKIE : return "cookie" ; case Scope . SCOPE_FORM : return "form" ; case Scope . SCOPE_VAR : case Scope . SCOPE_LOCAL : return "local" ; case Scope . SCOPE_REQUEST : return "request" ; case Scope . SCOPE_SERVER : return "server" ; case Scope . SCOPE_SESSION : return "session" ; case Scope . SCOPE_UNDEFINED : return "undefined" ; case Scope . SCOPE_URL : return "url" ; case Scope . SCOPE_VARIABLES : return "variables" ; case Scope . SCOPE_CLUSTER : return "cluster" ; } return defaultValue ; }
cast a int scope definition to a string definition