Java Javascript Mozilla Library isValid(Object[] args)

Here you can find the source of isValid(Object[] args)

Description

is Valid

License

Open Source License

Declaration

public static boolean isValid(Object[] args) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

import org.mozilla.javascript.Context;

public class Main {
    public static boolean isValid(Object o) {
        return o != null && o != Context.getUndefinedValue();
    }//  www .j a va2s  . c  o m

    public static boolean isValid(Object[] args) {
        return args.length > 0 && args[0] != Context.getUndefinedValue();
    }
}

Related

  1. isNullNativeObject(Object val)
  2. isPrototypeNameNode(AstNode node)
  3. isPrototypePropertyGet(PropertyGet pg)
  4. isSimplePropertyGet(PropertyGet pg, String expectedObj, String expectedField)
  5. isStaticProperty(Scriptable property)
  6. isVariable(Name name)
  7. javaToJS(Object o, Scriptable scope)
  8. jsToJava(Object jsObject)
  9. jsToJava(Object obj)