jhorvath commented on code in PR #5353:
URL: https://github.com/apache/netbeans/pull/5353#discussion_r1087790412


##########
enterprise/cloud.oracle/src/org/netbeans/modules/cloud/oracle/actions/AddADBAction.java:
##########
@@ -65,80 +73,104 @@
     "AddADB=Add Oracle Autonomous DB",
     "SelectTenancy=Select Tenancy",
     "SelectCompartment=Select Compartment",
-    "SelectDatabase=Select Database"
+    "SelectDatabase=Select Compartment or Database",
+    "EnterUsername=Enter Username",
+    "EnterPassword=Enter Password"
 })
 public class AddADBAction implements ActionListener {
     private static final Logger LOGGER = 
Logger.getLogger(AddADBAction.class.getName());
     
+    private static final String DB = "db";
+    private static final String USERNAME = "username";
+    private static final String PASSWORD = "password";
 
     @Override
     public void actionPerformed(ActionEvent e) {
-        List<TenancyItem> tenancies = new ArrayList<>();
-        for (OCIProfile p : OCIManager.getDefault().getConnectedProfiles()) {
-           p.getTenancy().ifPresent(tenancies::add);
-        }
-        Optional<TenancyItem> selectedTenancy = chooseOneItem(tenancies, 
Bundle.SelectTenancy());
-        
-        Optional<CompartmentItem> selectedCompartment = Optional.empty();
-                
-        if (!selectedTenancy.isPresent()) {
-            return;
-        }
-        
-        List<CompartmentItem> compartments = 
CompartmentNode.getCompartments().apply(selectedTenancy.get());
-        selectedCompartment = chooseOneItem(compartments, 
Bundle.SelectCompartment());
-        DatabaseItem selectedDatabase = null;
+        Map<String, Object> result = new HashMap<> ();
         
-        if (selectedCompartment.isPresent()) {
-            while(selectedDatabase == null) {
-                OCIItem item = chooseCopartmentOrDb(selectedCompartment.get());
-                if (item == null) {
-                    return;
-                }
-                if (item instanceof DatabaseItem) {
-                    selectedDatabase = (DatabaseItem) item;
-                }
-                if (item instanceof CompartmentItem) {
-                    selectedCompartment = Optional.of((CompartmentItem) item);
+        NotifyDescriptor.ComposedInput ci = new 
NotifyDescriptor.ComposedInput(Bundle.AddADB(), 2, new Callback() {

Review Comment:
   Increasing estimated number of steps for additional steps in the middle 
(sub-compartments)



-- 
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