Silly question ...which tutorial is this? Eric Bresie [email protected] (mailto:[email protected])
> On December 3, 2020 at 5:17:14 PM CST, Sean Carrick <[email protected] > (mailto:[email protected])> wrote: > Gj, > > Ok, so what I am understanding now is that the folder is virtual and > *only* located within the confines of the Virtual Filesystem, within the > layer.xml file. So far, I am with you on this. > > Now, if I provided an editor to the user to enter a new vehicle, for > example, to include make, model, color, and vehicle ID number (VIN), > then the save action is invoked upon that new vehicle. This vehicle file > would then, also, be saved in the Virtual Filesystem, correct? And it > would be saved in the "data/vehicles" folder in the Virtual Filesystem? > > Am I now understanding it correctly? > > Thanks once again for your assistance. I do truly appreciate it. > > Sean C. > > PS: If I am being thickheaded, please feel free to tell me so. I am good > with that. ;-) > > > On 12/3/20 4:52 PM, Geertjan Wielenga wrote: > > It is a virtual folder, what you see in the layer file. The virtual folder > > is in the virtual filesystem of the NetBeans Platform. You will not see it > > anywhere on disk. > > > > Gj > > > > On Thu, 3 Dec 2020 at 23:28, Sean Carrick <[email protected] > > (mailto:[email protected])> wrote: > > > > > Gj, > > > > > > Again, thank you for your gracious assistance. I do, however, have one > > > more question about the DataFolder, DataObject, and the layer.xml file. > > > > > > If I were to create a <folder name="data/vehicles"> section in the > > > layer.xml file, when the save action is invoked, would that then create > > > the folder on disk? > > > > > > Also, where on disk is that folder created? Is it in the default user's > > > data folder? Can I specify somewhere else on disk to create/use the > > > custom folder? > > > > > > I really am trying to understand how the System Filesystem works and how > > > it relates to the physical media, when needed. Your tutorials have > > > brought me a long way, but seem to cause questions for me and I struggle > > > to find the answers. > > > > > > Thank you again for your assistance, this time in advance. Have a > > > wonderful day. > > > > > > Sean C. > > > > > > On 12/3/20 2:32 AM, Geertjan Wielenga wrote: > > > > Next, since the Object in your scenario is a DataFolder, when a folder > > > > is > > > > selected, the Action is automatically enabled because the folder has a > > > > DataFolder built into its Lookup. > > > > > > > > Now that the Action is enabled, you have the DataFolder available in the > > > > constructor and can refer to it and use it and refer to it in the next > > > part > > > > of the logic in the ActionListener. > > > > > > > > Gj > > > > > > > > On Thu, 3 Dec 2020 at 09:26, Geertjan Wielenga < > > > > [email protected] > > > > (mailto:[email protected])> wrote: > > > > > > > > > The fact that the ActionListener takes an Object as an argument means > > > that > > > > > the annotations at the top of the class (or in the layer.xml file) > > > > > will > > > > > generate a context-sensitive Action that is sensitive to the Object in > > > the > > > > > argument. The Action will be enabled when the Object is available, > > > i.e., in > > > > > context, thanks to the Lookup. > > > > > > > > > > Gj > > > > > > > > > > On Thu, 3 Dec 2020 at 02:37, Sean Carrick <[email protected] > > > > > (mailto:[email protected])> wrote: > > > > > > > > > > > Gj, > > > > > > > > > > > > Hello. > > > > > > > > > > > > I was looking at your tutorial (old, for NB8.1) for the RSS Reader. > > > > > > I > > > > > > was especially looking at how you were storing new, user-created > > > folders > > > > > > and RSS feed files. However, reading through it, I was getting a > > > > > > little > > > > > > confused, and want to make sure that I am properly understanding how > > > > > > your last three code snippets are working together. First, I want to > > > > > > explain how I am understanding it, then ask my questions of you. > > > > > > > > > > > > Toward the end of the section titled "Displaying the Node Hierarchy > > > > > > in > > > > > > the Feed Window, in Step 4, you added code to the end of the > > > > > > TopComponent's constructor with the BeanTreeView and a try...catch > > > block. > > > > > > The two lines that I am particularly referring to are: > > > > > > > > > > > > FileObject rssFeedsFolder = FileUtil.getConfigFile("RssFeeds"); > > > > > > > > > > > > Node rssFeedsNode = > > > > > > DataObject.find(rssFeedsFolder).getNodeDelegate(); > > > > > > > > > > > > Down further in the tutorial, you have two code blocks: the first is > > > the > > > > > > AddRssAction class and the second is the AddFolderAction class. > > > > > > Both of > > > > > > these classes' constructors take a DataFolder object as an argument. > > > > > > > > > > > > Now that I have laid all of that out, here is the way I am > > > understanding > > > > > > this, and I would like you to correct me if I am wrong, please. > > > > > > > > > > > > By creating the FileObject rssFeedsFolder and getting the config > > > > > > file > > > > > > from FileUtil, when the DataObject.find() method is called, that > > > > > > gets > > > > > > the rssFeedsFolder object into the constructors of the two Action > > > > > > classes, correct? > > > > > > > > > > > > I do not see any other code regarding these Actions and, therefore, > > > > > > am > > > > > > having trouble understanding how the two Action classes receive > > > > > > their > > > > > > parameter value. With what I just explained of my understanding in > > > > > > the > > > > > > paragraph above, am I even close to figuring this out? Or, do I > > > > > > need to > > > > > > go back to kindergarten and re-learn reading comprehension? ;-} > > > > > > > > > > > > Regardless of how off I am, I am determined to learn this system. I > > > > > > appreciate your assistance in getting me moving in the correct > > > direction. > > > > > > Cheers, > > > > > > > > > > > > Sean C. > > > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > > > > To unsubscribe, e-mail: [email protected] > > > > > > (mailto:[email protected]) > > > > > > For additional commands, e-mail: [email protected] > > > > > > (mailto:[email protected]) > > > > > > > > > > > > For further information about the NetBeans mailing lists, visit: > > > > > > https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists > > > > > > > > > > > > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: [email protected] > > > (mailto:[email protected]) > > > For additional commands, e-mail: [email protected] > > > (mailto:[email protected]) > > > > > > For further information about the NetBeans mailing lists, visit: > > > https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists > > > > > > > > > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > (mailto:[email protected]) > For additional commands, e-mail: [email protected] > (mailto:[email protected]) > > For further information about the NetBeans mailing lists, visit: > https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists > > >
