Method endElement in AccessControList was revised. A feature that put access document itset into xml_access was added.
In hasPermission method, a rule for access document is implements. If user want to write a access document, it should hhave "all" permission.The permission for access document now is looking up in xml_access table directly, rather get same permission to data set document.
In order to increase data file docid, method registerDocument was revised. Now it not only insert a new data file record to xml_documents table, but also can update the data file documents. Moreover, it can archieve the old version to xml_revisions table. Two other private methods were added to handl these futures: deleteXMLDocuments and getLatestRevisionNumber.
fixed my tagging error
some small changes I had to make to get the QAENGINE demo to work right. this should be committing in a branch
We decided that the permission for a user to an access documents is as same as to the data set document(which contains the access document). In order to do this, we need to look-up xml-relation table. If we could find the data set document id, just check the id. If we couldn't find one, we need check if the user is owner. If it is, has permission. Otherwise, doesn't have.
Add a new method getDataSetId to the class. The permission policy for access documents is: the user will have the same permission as data set file. (There is no entry in xml_access table for access document.
Add a throwing exception in hasPermission and hasReadPermission methods.
Add a throwing exception in haspermission method.
A constructor for this class was added. In the new constructor, user can specify the revision number he want to update. In method writeDocumentToDB, when a update action happend, the rev number would not automatictlly to add one, but it can go to specified number. This is for bug 417.
View revisions
Also available in: Atom