本文整理汇总了Java中com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type.Void方法的典型用法代码示例。如果您正苦于以下问题:Java Type.Void方法的具体用法?Java Type.Void怎么用?Java Type.Void使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type
的用法示例。
在下文中一共展示了Type.Void方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* Runs a type check on either the variable element body or the
* expression in the 'select' attribute
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
// Type check the 'select' expression if present
if (_select != null) {
_type = _select.typeCheck(stable);
}
// Type check the element contents otherwise
else if (hasContents()) {
typeCheckContents(stable);
_type = Type.ResultTree;
}
else {
_type = Type.Reference;
}
// The return type is void as the variable element does not leave
// anything on the JVM's stack. The '_type' global will be returned
// by the references to this variable, and not by the variable itself.
return Type.Void;
}
示例2: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* Type-check this expression, and possibly child expressions.
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
// Get the left and right operand types
Type tleft = _left.typeCheck(stable);
Type tright = _right.typeCheck(stable);
// Check if the operator supports the two operand types
MethodType wantType = new MethodType(Type.Void, tleft, tright);
MethodType haveType = lookupPrimop(stable, Ops[_op], wantType);
// Yes, the operation is supported
if (haveType != null) {
// Check if left-hand side operand must be type casted
Type arg1 = (Type)haveType.argsType().elementAt(0);
if (!arg1.identicalTo(tleft))
_left = new CastExpr(_left, arg1);
// Check if right-hand side operand must be type casted
Type arg2 = (Type) haveType.argsType().elementAt(1);
if (!arg2.identicalTo(tright))
_right = new CastExpr(_right, arg1);
// Return the result type for the operator we will use
return _type = haveType.resultType();
}
throw new TypeCheckError(this);
}
示例3: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* Type checks the 'file' attribute (must be able to convert it to a str).
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
final Type type = _filename.typeCheck(stable);
if (type instanceof StringType == false) {
_filename = new CastExpr(_filename, Type.String);
}
typeCheckContents(stable);
return Type.Void;
}
示例4: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* Type-check this when element. The test should always be type checked,
* while we do not bother with the contents if we know the test fails.
* This is important in cases where the "test" expression tests for
* the support of a non-available element, and the <xsl:when> body contains
* this non-available element.
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
// Type-check the test expression
if (_test.typeCheck(stable) instanceof BooleanType == false) {
_test = new CastExpr(_test, Type.Boolean);
}
// Type-check the contents (if necessary)
if (!_ignore) {
typeCheckContents(stable);
}
return Type.Void;
}
示例5: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* Type-check the "test" expression and contents of this element.
* The contents will be ignored if we know the test will always fail.
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
// Type-check the "test" expression
if (_test.typeCheck(stable) instanceof BooleanType == false) {
_test = new CastExpr(_test, Type.Boolean);
}
// Type check the element contents
if (!_ignore) {
typeCheckContents(stable);
}
return Type.Void;
}
示例6: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* Run type check on the fallback element (if any).
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
if (_fallbacks != null) {
int count = _fallbacks.size();
for (int i = 0; i < count; i++) {
Fallback fallback = (Fallback)_fallbacks.elementAt(i);
fallback.typeCheck(stable);
}
}
return Type.Void;
}
示例7: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
if (!_ignore) {
_name.typeCheck(stable);
if (_namespace != null) {
_namespace.typeCheck(stable);
}
typeCheckContents(stable);
}
return Type.Void;
}
示例8: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* Type check the contents of this element
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
if (_ignore) return (Type.Void);
// _mergeSet Point to any previous definition of this attribute set
_mergeSet = stable.addAttributeSet(this);
_method = AttributeSetPrefix + getXSLTC().nextAttributeSetSerial();
if (_useSets != null) _useSets.typeCheck(stable);
typeCheckContents(stable);
return Type.Void;
}
示例9: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
if (_value != null) {
Type tvalue = _value.typeCheck(stable);
if (tvalue instanceof RealType == false) {
_value = new CastExpr(_value, Type.Real);
}
}
if (_count != null) {
_count.typeCheck(stable);
}
if (_from != null) {
_from.typeCheck(stable);
}
if (_format != null) {
_format.typeCheck(stable);
}
if (_lang != null) {
_lang.typeCheck(stable);
}
if (_letterValue != null) {
_letterValue.typeCheck(stable);
}
if (_groupingSeparator != null) {
_groupingSeparator.typeCheck(stable);
}
if (_groupingSize != null) {
_groupingSize.typeCheck(stable);
}
return Type.Void;
}
示例10: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
// Type check match pattern
_match.typeCheck(stable);
// Cast node values to string values (except for nodesets)
_useType = _use.typeCheck(stable);
if (_useType instanceof StringType == false &&
_useType instanceof NodeSetType == false)
{
_use = new CastExpr(_use, Type.String);
}
return Type.Void;
}
示例11: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* Type-check the contents of this element. The element itself does not
* need any type checking as it leaves nothign on the JVM's stack.
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
// Type-check all attributes
if (_attributeElements != null) {
for (SyntaxTreeNode node : _attributeElements) {
node.typeCheck(stable);
}
}
typeCheckContents(stable);
return Type.Void;
}
示例12: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
/**
* This element never produces any data on the stack
*/
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
if (_active) {
return(typeCheckContents(stable));
}
else {
return Type.Void;
}
}
示例13: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
typeCheckContents(stable);
return Type.Void;
}
示例14: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
return Type.Void;
}
示例15: typeCheck
import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type; //导入方法依赖的package包/类
public Type typeCheck(SymbolTable stable) throws TypeCheckError {
return Type.Void; // TODO
}