Fantom

 

abstract class compilerJs::JsNode

sys::Obj
  compilerJs::JsNode

Source

JsNode translates a compiler::Node into the equivalent JavaScript source code.

isPrimitive

Bool isPrimitive(CType ctype)

Source

Return true if the type is a primitive type:

  • Bool
  • Decimal
  • Float
  • Int
  • Num
  • Str
make

new make(JsCompilerSupport support)

Source

pmap

const Str:Bool pmap := ...

Source

qnameToJs

Str qnameToJs(CType ctype)

Source

Return the JavaScript qname for this CType.

support

JsCompilerSupport support

Source

vnameToJs

Str vnameToJs(Str name)

Source

Return the JavaScript variable name for the given Fan variable name.

write

abstract Void write(JsWriter out)

Source

Write the JavaScript source code for this node.