Announcement

Collapse
No announcement yet.

Type casting in javascript writer.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Type casting in javascript writer.

    I am using custom RXTX jar file with javascript writer.

    Java Code:
    import gnu.io.*;
    SerialPort serialPort;
    CommPortIdentifier comPort;
    serialPort = (SerialPort) comPort.open("SimpleWrite", 2000);

    While in mirth connect;
    importPackage(Packages.gnu.io);
    var serialPort;
    var comPort;
    How to type caste port.open() to serialPort datatype?

  • #2
    You can't cast java types in javascript. javascript always sees the actual class of an object rather than a superclass or interface.

    You have a lot of threads for this same problem. Can you stick to one?

    Comment

    Working...
    X