| // |
| // Licensed to the Apache Software Foundation (ASF) under one |
| // or more contributor license agreements. See the NOTICE file |
| // distributed with this work for additional information |
| // regarding copyright ownership. The ASF licenses this file |
| // to you under the Apache License, Version 2.0 (the |
| // "License"); you may not use this file except in compliance |
| // with the License. You may obtain a copy of the License at |
| // |
| // http://www.apache.org/licenses/LICENSE-2.0 |
| // |
| // Unless required by applicable law or agreed to in writing, |
| // software distributed under the License is distributed on an |
| // "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| // KIND, either express or implied. See the License for the |
| // specific language governing permissions and limitations |
| // under the License. |
| // |
| |
| = ParsingAPI |
| :jbake-type: wiki |
| :jbake-tags: wiki, devfaq, needsreview |
| :markup-in-source: verbatim,quotes,macros |
| :jbake-status: published |
| :syntax: true |
| :description: Quick Links to Turorials and Docs |
| :icons: font |
| :source-highlighter: pygments |
| :toc: left |
| :toc-title: |
| :experimental: |
| |
| == Quick Links to Turorials and Docs |
| |
| * http://netbeans.apache.org/tutorials/nbm-javacc-lexer.html |
| * http://netbeans.apache.org/tutorials/nbm-javacc-parser.html |
| * link:https://bits.netbeans.org/dev/javadoc/org-netbeans-modules-parsing-api/overview-summary.html[Official Doc (JavaDoc)] |
| |
| |
| [[Motivation]] |
| == Motivation |
| |
| NetBeans IDE is no longer just Java IDE. We support many various languages: |
| Java, Ruby, PHP, JSP, Javascript and so on. Each language support module |
| implements its own parsing framework. We have Retouche for Java, GSF for Ruby, |
| Schliemann. Now is the right time to consiladate those framworks in order to |
| avoid code duplication, improve performance, solve threading issues, |
| consolidate features and allow language embedding. |
| |
| |
| [[Description]] |
| == Description |
| |
| We want to create Parsing API to: |
| |
| * Unify registration of parsers |
| * Allow language embedding |
| * Allow file indexing |
| * Unify threading, starting/canceling parser tasks |
| * Avoid code duplication |
| * Simplify implementation of language supports |
| |
| |
| [[Current_Status]] |
| == Current Status |
| |
| |=== |
| |Plugin |Go/No Go |Status |
| |
| |CSS |Done. |
| |
| |Groovy |Done, bugfixing. |
| |
| |GSP |Done, bugfixing. |
| |
| |HTML |Done, bugfixing. |
| |
| |Javascript |Done, bugfixing. |
| |
| |JSP |Done, bugfixing. |
| |
| |PHP |Done, bugfixing. |
| |
| |Python |In progress. |
| |
| |RHTML |Done, bugfixing. |
| |
| |Ruby |Done, bugfixing. |
| |
| |YAML |Done, bugfixing. |
| |
| |JavaFX |Done |
| |
| |Ada |Done, bugfixing. (contrib) |
| |
| |EJS |Not planned for 6.7 (contrib) |
| |
| |Erlang |Rewrite done (?) -- link:http://blogtrader.net/[Status] |
| |
| |Fortress |Not planned for 6.7 (contrib) |
| |
| |Scala |Done, bugfixing. (contrib) |
| |
| |Tcl/Tk |Not planned for 6.7 (contrib) |
| |=== |
| |
| |
| [[Impacts]] |
| == Impacts |
| |
| |
| [[Architecture]] |
| === Architecture |
| |
| |
| [[API]] |
| === API |
| |
| We have experience with Retouche, GSF and Schliemann and we want to make an API, which will rise from our experience with those frameworks. The API is not intend to be revolutionary. It is evolutionary development. |
| |
| The API will have several parts: |
| |
| 1. Parsing |
| * Defines registration of parsers |
| * Defines threading |
| * Concept of Virtual Source (support for language embedding) |
| * No support for phases |
| * No ordering of parsers |
| . Indexing |
| * Provides scanning infrastructure |
| * Allows registration of Index providers |
| * RepositoryUpdater - listening on file and document changes |
| . "Generic ClassPath" |
| * Provides something like ClassPath to specify source roots (folders, archives) |
| . UserAction and Modification tasks |
| * Change represented by ModificationResult (in fact textual diff) |
| * Need source position translators for embedded languages |
| |
| |
| [[Documentation]] |
| === Documentation |
| |
| API must be well documented. Developer documentation is a must. |
| |
| [[Testing]] |
| === Testing |
| |
| * Unit testing. |
| * Functional testing through language support modules. |
| |
| |
| [[Performance]] |
| === Performance |
| |
| * Well defined threading and starting/canceling parser tasks could improve performance of code completion and features in various Editors |
| * Startup scanning will be slower because of scanning and indexing not only Java, but possibly all files |
| |
| |
| [[Tasks]] |
| == Tasks |
| |
| We have been tracking all tasks related to Parsing API in IssueZilla under *Editor / Parsing & Indexing* category. Please use the following |
| link:http://editor.netbeans.org/issues/buglist.cgi?component=editor;subcomponent=Parsing%20%26%20Indexing;issue_status=NEW;issue_status=STARTED;issue_status=REOPENED;&order=issues.priority%2C%20issues.issue_id[query] to see all unresolved issues sorted by their priority. |
| |
| |
| [[Bugs]] |
| == Bugs |
| |
| * link:http://www.netbeans.org/issues/buglist.cgi?issue_status=NEW&issue_status=STARTED&issue_status=REOPENED&email1=&emailtype1=exact&emailassigned_to1=1&email2=&emailtype2=exact&emailreporter2=1&issueidtype=include&issue_id=&changedin=&votes=&chfieldfrom=&chfieldto=Now&chfieldvalue=&short_desc=&short_desc_type=substring&long_desc=&long_desc_type=substring&issue_file_loc=&issue_file_loc_type=substring&status_whiteboard=parsingapi&status_whiteboard_type=substring&keywords=&keywords_type=anytokens&field0-0-0=status_whiteboard&type0-0-0=notequals&value0-0-0=works_in_parsingapi&cmdtype=doit&namedcmd=my-projects&newqueryname=&order=Reuse+same+sort+as+last+time&Submit+query=Submit+query[List of bugs specific to the parsing api] |
| * link:http://www.netbeans.org/issues/buglist.cgi?issue_status=NEW&issue_status=STARTED&issue_status=REOPENED&status_whiteboard=works_in_parsingapi&status_whiteboard_type=substring[List of (trunk) bugs fixed by the parsing API] |
| |
| |
| [[Additional_information]] |
| == Additional information |
| |
| * Send comments to link:mailto:dev@netbeans.apache.org[dev@netbeans.apache.org] |
| * xref:EditorSupportChangesProposal.adoc[Editor Support Changes Proposal] |
| * xref:ParsingAPIRequirements.adoc[Parsing API - Use cases, Requirements] |
| * link:https://bz.apache.org/netbeans/show_bug.cgi?id=137084[GSF Inception Review] |
| * link:https://bz.apache.org/netbeans/show_bug.cgi?id=127357[Parsing API Inception Review] |
| * xref:ParsingAPITCReview.adoc[Parsing API Technical Council Review ] |
| * xref:GsfToParsingAndIndexingApiMigration.adoc[Migrating GSF-based language plugins to Parsing & Indexing API] |
| |
| |
| [NOTE] |
| ==== |
| |
| The content in this page was kindly donated by Oracle Corp. to the |
| Apache Software Foundation. |
| |
| This page was exported from link:http://wiki.netbeans.org/ParsingAPI[http://wiki.netbeans.org/ParsingAPI] , |
| that was last modified by NetBeans user Mr lou d |
| on 2015-01-08T09:23:40Z. |
| |
| |
| This document was automatically converted to the AsciiDoc format on 2020-03-12, and needs to be reviewed. |
| ==== |