本文整理汇总了Java中jsinterop.base.Any类的典型用法代码示例。如果您正苦于以下问题:Java Any类的具体用法?Java Any怎么用?Java Any使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Any类属于jsinterop.base包,在下文中一共展示了Any类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getExpressionReturnTypeForAttribute
import jsinterop.base.Any; //导入依赖的package包/类
/**
* Guess the type of the expression based on where it is used.
* The guessed type can be overridden by adding a Cast to the desired type at the
* beginning of the expression.
* @param attribute The attribute the expression is in
* @return
*/
private String getExpressionReturnTypeForAttribute(Attribute attribute)
{
String attributeName = attribute.getKey().toLowerCase();
if (attributeName.indexOf("@") == 0 || attributeName.indexOf("v-on:") == 0)
return "void";
if ("v-if".equals(attributeName) || "v-show".equals(attributeName))
return "boolean";
if (currentProp != null)
return currentProp.getType().toString();
return Any.class.getCanonicalName();
}
示例2: getInExpressionType
import jsinterop.base.Any; //导入依赖的package包/类
public String getInExpressionType()
{
if (type == VForDefinitionType.ARRAY_OR_RANGE)
return Any.class.getCanonicalName();
return "Object";
}
示例3: prop
import jsinterop.base.Any; //导入依赖的package包/类
@JsOverlay
public final T prop( @Nonnull final String key, @Nullable final Any value )
{
Js.asPropertyMap( this ).set( key, value );
return self();
}
示例4: vForExpressionFromJava
import jsinterop.base.Any; //导入依赖的package包/类
public static <T> Any vForExpressionFromJava(Collection<T> collection)
{
return Js.asAny(JsUtils.arrayFrom(collection));
}
示例5: isReturnAny
import jsinterop.base.Any; //导入依赖的package包/类
public boolean isReturnAny()
{
return Any.class.getCanonicalName().equals(type.toString());
}
示例6: getFrom
import jsinterop.base.Any; //导入依赖的package包/类
@JsOverlay
default Any getFrom(Object on) {
return Jso.getProperty(on, this);
}
示例7: getProperty
import jsinterop.base.Any; //导入依赖的package包/类
@JsOverlay
public static Any getProperty(Object on, SymbolOrString s) {
return JsoMagic.getProperty(on, s);
}