Paul Clapham wrote:
Aaron John wrote:Is there a special syntax for the double forward slash in xsl? For example, the use of "//"
I don't understand the question. That is syntax.
Paul Clapham wrote:One other thing you didn't know about XSLT is going to mess up that plan, no matter how you decide to store the data: once you assign a value to an xsl:variable, you subsequently can't change it. So you'll need to go back to the drawing board and design a completely different solution to your original problem.
Perhaps it would be better to just post your original problem? If you have a solution to a problem but don't know how to implement it at all, it's generally better to ask about the problem and not about the solution.
Edit: for example, if your problem is actuallythen just write an XPath expression which returns that directly. Like "//order/method/description".I would like a collection that holds all the /order/method/description values
Originally posted by Jethro Borsje:
You can also choose to read the data file into memory before hand, the Data class would then just hold a Map of the records in memory. Using this approach you do not have any IOExceptions during the usage of the Data class. You can catch these errors before hand we reading the file into memory. In my opinion this is also better, because you may not want th DB server to run at all if some serious IOExceptions occurred.
Originally posted by Jo�o Batista:
Think about the kinds of Exception that a method can throw and how they affect the method signature.
You'll find a way to disguise that IOException.
Originally posted by Jason Moors:
Hi Aaron,
A possible solution if you don't want to handle the RecordNotFoundException in your find method is to create a new private method for actually reading the record which doesn't throw an exception, this method would return null array if the record is not found or marked as deleted.
This new method would then be called by both the read and find, the read method would check if the returned value is null and throw a RecordNotFoundException, and the find method could ignore null array and not add to search results.
Hope it helps,
Jason
[ June 23, 2008: Message edited by: Jason Moors ]
Originally posted by Roberto Perillo:
Well, to me, "Field n in the database file is described by criteria[n]" means that the search criteria should have the same number of fields of a record, and "A non-null value in criteria[n] matches any field value that begins with criteria[n]" means that any value in criteria[n] should match any field that is different from null and that starts with criteria[n].
Originally posted by Quintin Stephenson:
Hi All
I've gone for a dynamic approach with regards to the shema in a similar manner at Edwin. I read the meta data in the header and create a schema object. This object contains all the information that will dictate everything with regards to data (ie. data type, length postion in of column per records etc) and will ensure data ways ends up in the correct position in the datafile. It will also be used to affect my MVC model for the displayed GUI to my users.
My analysis of the data file gave me similar questions and conclusions(by the sounds of it) to Edwin. What redesign work would I have to go through if a new column was added (e.g. in my assignment I can see a need for a phone number column to be added). By the sounds of it some people are going for similar solutions to Andrew Monkhouse's book solution using a traditional hard coded Transfer Object design pattern.
I think you should be fine as long as you can justify it and remember to document it in your choices document as this is a major part of your assignment (your thought process and why you did certain things).
Cheers
Q
Originally posted by Musab Al-Rawi:
Hi,
you can either
1. define another interface and have your Data.java class implements both DBMain and the new interface.
2. or in UI call find for all contractors then extract the info that you need to build the combo boxes.
Originally posted by Mike Ottinger:
Hi Aaron,
I implemented the searching using combo boxes. I felt, even with a potential increase in names and locations, that this approaches was still tenable. I had two drop-downs, one for name and location each. Then a radio button indicating a search mode of 'any' or 'both', defaulting to 'any'. With drop-downs, the user input is controlled, thus removing the need for me to do any intensive validation of search terms. Hope this helps...