Package com.ericsson.otp.erlang

Examples of com.ericsson.otp.erlang.OtpErlangTuple.elementAt()


                        docPath = Util.stringValue(otpDoc.elementAt(3));
                        anchor = Util.stringValue(otpDoc.elementAt(4));
                    }
                    if (result.length() > 0) {
                        final String html = HoverUtil.getHTMLAndReplaceJSLinks(result);
                        final Object element = OpenResult.build(otpDoc.elementAt(2));
                        input = new ErlBrowserInformationControlInput(input, editor,
                                element, html, 20, HoverUtil.getDocumentationURL(docPath,
                                        anchor));
                    }
                }
View Full Code Here


                            externalModulesString,
                            model.getPathVars(editor.getModule()
                                    .getCorrespondingResource()));
            ErlLogger.debug("otp doc %s", t);
            if (Util.isOk(t)) {
                element = OpenResult.build(t.elementAt(2));
                final String docStr = Util.stringValue(t.elementAt(1));
                result.append(docStr);
                if (t.arity() > 4) {
                    docPath = Util.stringValue(t.elementAt(3));
                    anchor = Util.stringValue(t.elementAt(4));
View Full Code Here

                            model.getPathVars(editor.getModule()
                                    .getCorrespondingResource()));
            ErlLogger.debug("otp doc %s", t);
            if (Util.isOk(t)) {
                element = OpenResult.build(t.elementAt(2));
                final String docStr = Util.stringValue(t.elementAt(1));
                result.append(docStr);
                if (t.arity() > 4) {
                    docPath = Util.stringValue(t.elementAt(3));
                    anchor = Util.stringValue(t.elementAt(4));
                }
View Full Code Here

            if (Util.isOk(t)) {
                element = OpenResult.build(t.elementAt(2));
                final String docStr = Util.stringValue(t.elementAt(1));
                result.append(docStr);
                if (t.arity() > 4) {
                    docPath = Util.stringValue(t.elementAt(3));
                    anchor = Util.stringValue(t.elementAt(4));
                }
            } else {
                element = OpenResult.build(t);
                final Object found = new OpenUtils().findOpenResult(editor,
View Full Code Here

                element = OpenResult.build(t.elementAt(2));
                final String docStr = Util.stringValue(t.elementAt(1));
                result.append(docStr);
                if (t.arity() > 4) {
                    docPath = Util.stringValue(t.elementAt(3));
                    anchor = Util.stringValue(t.elementAt(4));
                }
            } else {
                element = OpenResult.build(t);
                final Object found = new OpenUtils().findOpenResult(editor,
                        editor.getModule(), erlProject, element,
View Full Code Here

            }

            @Override
            public void progress(final OtpErlangObject msg) {
                final OtpErlangTuple t = (OtpErlangTuple) msg;
                final OtpErlangPid backgroundSearchPid = (OtpErlangPid) t.elementAt(0);
                final OtpErlangLong progressL = (OtpErlangLong) t.elementAt(1);
                final OtpErlangObject resultO = t.elementAt(2);
                int progress = 1;
                try {
                    progress = progressL.intValue();
View Full Code Here

            @Override
            public void progress(final OtpErlangObject msg) {
                final OtpErlangTuple t = (OtpErlangTuple) msg;
                final OtpErlangPid backgroundSearchPid = (OtpErlangPid) t.elementAt(0);
                final OtpErlangLong progressL = (OtpErlangLong) t.elementAt(1);
                final OtpErlangObject resultO = t.elementAt(2);
                int progress = 1;
                try {
                    progress = progressL.intValue();
                    final List<ModuleLineFunctionArityRef> result = Lists.newArrayList();
View Full Code Here

            @Override
            public void progress(final OtpErlangObject msg) {
                final OtpErlangTuple t = (OtpErlangTuple) msg;
                final OtpErlangPid backgroundSearchPid = (OtpErlangPid) t.elementAt(0);
                final OtpErlangLong progressL = (OtpErlangLong) t.elementAt(1);
                final OtpErlangObject resultO = t.elementAt(2);
                int progress = 1;
                try {
                    progress = progressL.intValue();
                    final List<ModuleLineFunctionArityRef> result = Lists.newArrayList();
                    SearchUtil.addSearchResult(result, resultO);
View Full Code Here

    public ISourceRange findVariable(final ISourceRange range, final String variableName,
            final String elementText) throws OtpErlangRangeException {
        final OtpErlangTuple res2 = ErlangEngine.getInstance()
                .getService(OpenService.class).findFirstVar(variableName, elementText);
        if (res2 != null) {
            final int relativePos = ((OtpErlangLong) res2.elementAt(0)).intValue() - 1;
            final int length = ((OtpErlangLong) res2.elementAt(1)).intValue();
            final int start = relativePos + range.getOffset();
            return new SourceRange(start, length);
        }
        return range;
View Full Code Here

            final String elementText) throws OtpErlangRangeException {
        final OtpErlangTuple res2 = ErlangEngine.getInstance()
                .getService(OpenService.class).findFirstVar(variableName, elementText);
        if (res2 != null) {
            final int relativePos = ((OtpErlangLong) res2.elementAt(0)).intValue() - 1;
            final int length = ((OtpErlangLong) res2.elementAt(1)).intValue();
            final int start = relativePos + range.getOffset();
            return new SourceRange(start, length);
        }
        return range;
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.