Package statechum.analysis.Erlang.Signatures

Examples of statechum.analysis.Erlang.Signatures.TupleSignature


        } else if (spec.startsWith("string()")) {
            specbuf.delete(0, 8);
            sig = new StringSignature(new OtpErlangList());
        } else if (spec.startsWith("tuple()")) {
            specbuf.delete(0, 7);
            sig = new TupleSignature(new OtpErlangList());
        } else if (spec.startsWith("char()")) {
            specbuf.delete(0, 6);
            sig = new CharSignature(new OtpErlangList());
        } else if (spec.startsWith("byte()")) {
            specbuf.delete(0, 6);
            sig = new ByteSignature(new OtpErlangList());
        } else if (spec.startsWith("pid()")) {
            specbuf.delete(0, 5);
            sig = new PidSignature();
        } else if (spec.startsWith("port()")) {
            specbuf.delete(0, 6);
            sig = new PortSignature();
        } else if (spec.startsWith("'")) {
            String lit = "";
            specbuf.delete(0, 1);
            while (specbuf.charAt(0) != '\'') {
                lit += specbuf.charAt(0);
                specbuf.delete(0, 1);
            }
            specbuf.delete(0, 1);
            sig = new LiteralSignature(lit);
        } else if (spec.startsWith("{")) {
            // Tuple...
            specbuf.delete(0, 1);
            bufTrimmer(specbuf);
            List<Signature> tupElems = new LinkedList<Signature>();
            while (specbuf.charAt(0) != '}') {
              tupElems.add(parseSignature(specbuf));
                bufTrimmer(specbuf);
                if (specbuf.charAt(0) == ',') {
                    // More vals...
                    specbuf.delete(0, 1);
                    bufTrimmer(specbuf);
                }
            }
            // Swallow the closing }
            specbuf.delete(0, 1);
            sig = new TupleSignature(tupElems);
        } else if (spec.startsWith("maybe_improper_list(")) {
            specbuf.delete(0, 20);
            bufTrimmer(specbuf);
            sig = parseList(specbuf, false, ')');
        } else if (spec.startsWith("nonempty_maybe_improper_list(")) {
View Full Code Here

TOP

Related Classes of statechum.analysis.Erlang.Signatures.TupleSignature

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.