public Parser cicsWriteQ() {
        if (cicsWriteQParser == null) {
           FutureParser future = scoped("cicsWriteQ");
           cicsWriteQParser = future;
           future.setParser(
               sequence(
                   token("WRITEQ"),
                   choice(
                       sequence(
                           token("TS"),
                           choice(
                               token("QUEUE"),
                               token("QNAME")
                           ),
                           token("("),
                           queueName(),
                           token(")"),
                           permuted(
                               sequence(
                                   choice(
                                       token("SYSID"),
                                       token("SYS")
                                   ),
                                   token("("),
                                   cicsSysid(),
                                   token(")")
                               ),
                               sequence(
                                   token("FROM"),
                                   token("("),
                                   dataArea(),
                                   token(")"),
                                   optional(
                                       sequence(
                                           token("LENGTH"),
                                           cicsWaterInBrackets()
                                       )
                                   )
                               ),
                               choice(
                                   sequence(
                                       token("NUMITEMS"),
                                       cicsWaterInBrackets()
                                   ),
                                   sequence(
                                       token("ITEM"),
                                       cicsWaterInBrackets(),
                                       optional(
                                           token("REWRITE")
                                       )
                                   )
                               ),
                               token("NOSUSPEND"),
                               choice(
                                   token("MAIN"),
                                   token("AUXILIARY")
                               )
                           )
                       ),
                       sequence(
                           token("TD"),
                           token("QUEUE"),
                           token("("),
                           queueName(),
                           token(")")
                       )
                   )
               )
           );
        }

        return cicsWriteQParser;
    }