neilcsmith-net commented on code in PR #9736:
URL: https://github.com/apache/netbeans/pull/9736#discussion_r4443978719


##########
ide/generic.project/arch.xml:
##########
@@ -0,0 +1,1241 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    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.
+
+-->
+
+<!DOCTYPE api-answers PUBLIC "-//NetBeans//DTD Arch Answers//EN" 
"../../nbbuild/antsrc/org/netbeans/nbbuild/Arch.dtd" [
+  <!ENTITY api-questions SYSTEM 
"../../nbbuild/antsrc/org/netbeans/nbbuild/Arch-api-questions.xml">
+]>
+
+<api-answers
+    question-version="1.29"
+    author="[email protected]"
+>
+
+  &api-questions;
+
+
+    <!--
+            <question id="arch-overall" when="init">
+                Describe the overall architecture.
+                <hint>
+                What will be API for
+                <a 
href="https://netbeans.apache.org/wiki/API_Design#Separate_API_for_clients_from_support_API";>
+                    clients and what support API</a>?
+                What parts will be pluggable?
+                How will plug-ins be registered? Please use <code>&lt;api 
type="export"/&gt;</code>
+                to describe your general APIs and specify their
+                <a 
href="https://netbeans.apache.org/wiki/API_Stability#private";>
+                stability categories</a>.
+                If possible please provide simple diagrams.
+                </hint>
+            </question>
+    -->
+    <answer id="arch-overall">
+        <p>
+            The module implements a project type for arbitrary directories. A 
directory
+            becomes a generic project when it contains the marker file (a plain
+            <code>java.util.Properties</code> file named <code>.nbgp</code> by 
default,
+            brandable) or when the
+            <code>org.netbeans.modules.generic.project</code> FileObject 
attribute is
+            set on it (a marker-less "local" project). A generic project is 
just its
+            directory: the logical view is a plain folder tree, and move, 
rename, copy
+            and delete operate on the directory as a whole.
+        </p>
+        <p>
+            The module exports no public Java packages; its contracts are:
+        </p>
+        <ul>
+            <li>
+                <api group="java" name="GenericProjectType" type="export" 
category="devel">
+                    <p>
+                        The project type itself, discovered by 
<code>ProjectManager</code> via
+                        the <code>ProjectFactory</code> registered in the 
global lookup. The
+                        contract is the marker file/attribute detection and 
the auxiliary data
+                        files (see <code>format-types</code>). The per-project 
services
+                        (logical view, project information, operations, 
customizer) are
+                        published in the project's lookup and can be extended 
by other modules
+                        via <code>@ProjectServiceProvider</code>.
+                    </p>
+                </api>
+            </li>
+        </ul>
+    </answer>
+
+
+
+    <!--
+            <question id="arch-quality" when="init">
+                How will the <a 
href="https://netbeans.apache.org/participate/qualityevangelism.html";>quality</a>
+                of your code be tested and
+                how are future regressions going to be prevented?
+                <hint>
+                What kind of testing do
+                you want to use? How much functionality, in which areas,
+                should be covered by the tests? How you find out that your
+                project was successful?
+                </hint>
+            </question>
+    -->
+    <answer id="arch-quality">
+        <p>
+            Unit tests (<code>GenericProjectTest</code>, 37 tests) cover 
project
+            detection (marker file vs. attribute), marker state changes, the 
two-file
+            auxiliary storage (shared vs. private data, marker toggling, 
external
+            marker deletion), display name handling and the file filter 
behavior.
+        </p>
+    </answer>
+
+
+
+    <!--
+            <question id="arch-time" when="init">
+                What are the time estimates of the work?
+                <hint>
+                Please express your estimates of how long the design, 
implementation,
+                stabilization are likely to last. How many people will be 
needed to
+                implement this and what is the expected milestone by which the 
work should be
+                ready?
+                </hint>
+            </question>
+    -->
+    <answer id="arch-time">
+        <p>
+            N/A - the module is already implemented.
+        </p>
+    </answer>
+
+
+
+    <!--
+            <question id="arch-usecases" when="init">
+                <hint>
+                    Content of this answer will be displayed as part of page at
+                    http://www.netbeans.org/download/dev/javadoc/usecases.html
+                    You can use tags &lt;usecase name="name&gt; regular html 
description &lt;/usecase&gt;
+                    and if you want to use an URL you can prefix if with @TOP@ 
to begin
+                    at the root of your javadoc
+                </hint>
+
+                Describe the main <a 
href="https://netbeans.apache.org/wiki/API_Design#The_Importance_of_Being_Use_Case_Oriented";>
+                use cases</a> of the new API. Who will use it under
+                what circumstances? What kind of code would typically need to 
be written
+                to use the module?
+            </question>
+    -->
+    <answer id="arch-usecases">
+        <p>
+            A generic project is a plain directory the user wants to manage as 
a
+            project (no build system, no specific language): a collection of 
documents,
+            scripts or data files with a folder view and per-project settings.

Review Comment:
   > I don't see any use-case to make this support optional
   
   I remain -1 on having this required to use `projectui`, or not allowing 
platform applications to exclude or reimplement generic project support.  I 
also think the API level and the generic project type are two separate things 
that overlap only in part, and each address other use cases.
   
   I'm -0.9 to making this generic project support not disable-able in the IDE, 
or not allowing plugins to hook into the API layer.
   
   > in fact I would find it very bad if differently configured versions of the 
IDE supported different marker files
   
   Is that in regard to the branding of shareable marker files?  Because my aim 
in requesting that was that different _applications_ can support different 
marker files.  A generic project configured in one should not automatically be 
picked up as a project in the other.  Yes, reimplementing the whole module 
could work around that, but the most obvious option in most cases is to re-use 
the module and brand it.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to