[xwiki-devs] [PROPOSAL] Add a setParent() method to DocumentAccessBridge / DocumentModelBridge
Hi Devs, I'm in need of a method to set the parent document of a given document. So until the we remodel the model classes (when? xwiki 2.0 release?), I propose to add the following method: void setParent(String parentDoc); Now the next question is where to add this method? DocumentAccessBridge or DocumentModelBridge? To me it seems to fit DocumentModelBridge. WDYT? Thanks. - Asiri
Asiri Rathnayake wrote:
Hi Devs,
I'm in need of a method to set the parent document of a given document. So until the we remodel the model classes (when? xwiki 2.0 release?), I propose to add the following method:
void setParent(String parentDoc);
+1 I'm wondering if a String is the best choice. Could we pass in another DocumentModelBridge instance?
Now the next question is where to add this method? DocumentAccessBridge or DocumentModelBridge?
To me it seems to fit DocumentModelBridge.
DocumentModelBridge -- Sergiu Dumitriu http://purl.org/net/sergiu/
On Sun, Mar 22, 2009 at 16:48, Sergiu Dumitriu <[email protected]> wrote:
Asiri Rathnayake wrote:
Hi Devs,
I'm in need of a method to set the parent document of a given document. So until the we remodel the model classes (when? xwiki 2.0 release?), I propose to add the following method:
void setParent(String parentDoc);
+1
+1
I'm wondering if a String is the best choice. Could we pass in another DocumentModelBridge instance?
Now the next question is where to add this method? DocumentAccessBridge or DocumentModelBridge?
Or DocumentName, anyway +1 for the general concept of not using String as much as possible since it's where the new model goes.
To me it seems to fit DocumentModelBridge.
DocumentModelBridge
Same
-- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Thomas Mortagne
On Mar 22, 2009, at 4:48 PM, Sergiu Dumitriu wrote:
Asiri Rathnayake wrote:
Hi Devs,
I'm in need of a method to set the parent document of a given document. So until the we remodel the model classes (when? xwiki 2.0 release?), I propose to add the following method:
void setParent(String parentDoc);
+1
I'm wondering if a String is the best choice. Could we pass in another DocumentModelBridge instance?
I don't think you should pass a full object to add a parent. A name is better. DocumentName would be best IMO. Thanks -Vincent
Now the next question is where to add this method? DocumentAccessBridge or DocumentModelBridge?
To me it seems to fit DocumentModelBridge.
DocumentModelBridge
Vincent Massol wrote:
On Mar 22, 2009, at 4:48 PM, Sergiu Dumitriu wrote:
Asiri Rathnayake wrote:
Hi Devs,
I'm in need of a method to set the parent document of a given document. So until the we remodel the model classes (when? xwiki 2.0 release?), I propose to add the following method:
void setParent(String parentDoc); +1
I'm wondering if a String is the best choice. Could we pass in another DocumentModelBridge instance?
I don't think you should pass a full object to add a parent. A name is better. DocumentName would be best IMO.
Sure. I must have forgotten about it...
Thanks -Vincent
Now the next question is where to add this method? DocumentAccessBridge or DocumentModelBridge?
To me it seems to fit DocumentModelBridge. DocumentModelBridge
-- Sergiu Dumitriu http://purl.org/net/sergiu/
participants (4)
-
Asiri Rathnayake -
Sergiu Dumitriu -
Thomas Mortagne -
Vincent Massol