In ActionScript, Is there a way to check if an input argument is a valid Vector of any type?
        Posted  
        
            by ty
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by ty
        
        
        
        Published on 2010-04-23T10:02:30Z
        Indexed on 
            2010/04/23
            20:33 UTC
        
        
        Read the original article
        Hit count: 331
        
In the following code:
var a:Vector.<int> ...
var b:Vector.<String> ...
var c:Vector.<uint> ...
var c:Vector.<MyOwnClass> ...
function verifyArrayLike(arr:*):Boolean
{
   return (arr is Array || arr is Vector)
}
verifyArrayLike(a);
verifyArrayLike(b);
...
What I'm looking for is something like _var is Vector.<*>
But Vector.<*> is not a valid expression, even Vector. can not be placed at the right side of operators. 
Is there a way to check if an input argument is a valid Vector of any type?
© Stack Overflow or respective owner