gnu.kawa.xml
Class ProcessingInstructionType

java.lang.Object
  extended by gnu.bytecode.Type
      extended by gnu.bytecode.ObjectType
          extended by gnu.kawa.xml.NodeType
              extended by gnu.kawa.xml.ProcessingInstructionType
All Implemented Interfaces:
TypeValue, ItemPredicate, NodePredicate, java.io.Externalizable, java.io.Serializable, java.lang.reflect.Type

public class ProcessingInstructionType
extends NodeType
implements TypeValue, java.io.Externalizable

See Also:
Serialized Form

Field Summary
static ProcessingInstructionType piNodeTest
           
static ClassType typeProcessingInstructionType
           
 
Fields inherited from class gnu.kawa.xml.NodeType
anyNodeTest, ATTRIBUTE_OK, COMMENT_OK, commentNodeTest, DOCUMENT_OK, documentNodeTest, ELEMENT_OK, nodeType, PI_OK, TEXT_OK, textNodeTest, typeKNode, typeNodeType
 
Fields inherited from class gnu.bytecode.ObjectType
flags
 
Fields inherited from class gnu.bytecode.Type
boolean_ctype, boolean_type, booleanType, booleanValue_method, byte_type, byteType, char_type, charType, clone_method, double_type, doubleType, doubleValue_method, errorType, float_type, floatType, floatValue_method, int_type, intType, intValue_method, java_lang_Class_type, javalangBooleanType, javalangClassType, javalangNumberType, javalangObjectType, javalangStringType, javalangThrowableType, long_type, longType, longValue_method, neverReturnsType, nullType, number_type, objectType, pointer_type, reflectClass, short_type, shortType, string_type, throwable_type, toString_method, tostring_type, toStringType, typeArray0, void_type, voidType
 
Constructor Summary
ProcessingInstructionType(java.lang.String target)
           
 
Method Summary
static KProcessingInstruction coerce(java.lang.Object obj, java.lang.String target)
           
 java.lang.Object coerceFromObject(java.lang.Object obj)
          Convert an object to a value of this Type.
static KProcessingInstruction coerceOrNull(java.lang.Object obj, java.lang.String target)
           
 void emitCoerceFromObject(CodeAttr code)
          Compile (in given method) cast from Object to this Type.
protected  void emitCoerceOrNullMethod(Variable incoming, Compilation comp)
           
 Type getImplementationType()
          The type used to implement types not natively understood by the JVM.
static ProcessingInstructionType getInstance(java.lang.String target)
           
 boolean isInstance(java.lang.Object obj)
           
 boolean isInstancePos(AbstractSequence seq, int ipos)
           
 void readExternal(java.io.ObjectInput in)
           
 java.lang.String toString()
           
 void writeExternal(java.io.ObjectOutput out)
           
 
Methods inherited from class gnu.kawa.xml.NodeType
coerceForce, coerceOrNull, compare, convertValue, emitIsInstance, emitTestIf, getConstructor, isInstance
 
Methods inherited from class gnu.bytecode.ObjectType
getContextClass, getContextClassLoader, getField, getInternalName, getMethod, getMethods, getMethods, getReflectClass, isExisting, promote, setExisting
 
Methods inherited from class gnu.bytecode.Type
coerceToObject, emitCoerceToObject, emitConvertFromPrimitive, emitIsInstance, getName, getRealType, getSignature, getSize, getSizeInWords, getType, hashCode, isMoreSpecific, isSubtype, isValidJavaTypeName, isVoid, lookupType, lowestCommonSuperType, make, printSignature, registerTypeForClass, setName, setReflectClass, setSignature, signatureLength, signatureLength, signatureToName, signatureToPrimitive, signatureToType, signatureToType, swappedCompareResult
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface gnu.expr.TypeValue
convertValue, emitIsInstance, emitTestIf, getConstructor
 

Field Detail

piNodeTest

public static final ProcessingInstructionType piNodeTest

typeProcessingInstructionType

public static final ClassType typeProcessingInstructionType
Constructor Detail

ProcessingInstructionType

public ProcessingInstructionType(java.lang.String target)
Method Detail

getInstance

public static ProcessingInstructionType getInstance(java.lang.String target)

getImplementationType

public Type getImplementationType()
Description copied from class: Type
The type used to implement types not natively understood by the JVM. Usually, the identity function. However, a language might handle union types or template types or type expressions calculated at run time. In that case return the type used at the JVM level, and known at compile time.

Specified by:
getImplementationType in interface TypeValue
Overrides:
getImplementationType in class NodeType

emitCoerceFromObject

public void emitCoerceFromObject(CodeAttr code)
Description copied from class: ObjectType
Compile (in given method) cast from Object to this Type.

Overrides:
emitCoerceFromObject in class NodeType

coerceFromObject

public java.lang.Object coerceFromObject(java.lang.Object obj)
Description copied from class: Type
Convert an object to a value of this Type. Throw a ClassCastException when this is not possible.

Overrides:
coerceFromObject in class NodeType

isInstancePos

public boolean isInstancePos(AbstractSequence seq,
                             int ipos)
Specified by:
isInstancePos in interface ItemPredicate
Overrides:
isInstancePos in class NodeType

isInstance

public boolean isInstance(java.lang.Object obj)
Overrides:
isInstance in class NodeType

coerceOrNull

public static KProcessingInstruction coerceOrNull(java.lang.Object obj,
                                                  java.lang.String target)

coerce

public static KProcessingInstruction coerce(java.lang.Object obj,
                                            java.lang.String target)

emitCoerceOrNullMethod

protected void emitCoerceOrNullMethod(Variable incoming,
                                      Compilation comp)
Overrides:
emitCoerceOrNullMethod in class NodeType

writeExternal

public void writeExternal(java.io.ObjectOutput out)
                   throws java.io.IOException
Specified by:
writeExternal in interface java.io.Externalizable
Overrides:
writeExternal in class NodeType
Throws:
java.io.IOException

readExternal

public void readExternal(java.io.ObjectInput in)
                  throws java.io.IOException,
                         java.lang.ClassNotFoundException
Specified by:
readExternal in interface java.io.Externalizable
Overrides:
readExternal in class NodeType
Throws:
java.io.IOException
java.lang.ClassNotFoundException

toString

public java.lang.String toString()
Overrides:
toString in class NodeType