Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mylar-dev] task list externalization

Mik,

 Here is proposed interface for replacing w3c classes in externalizers api.

I have updated all connectors to use new interface and implemented two variants of IElement: read-only that is internally using w3c dom and write-only that is constructing xml stream directly. Apparently, write performance improvement is not big (probably about 10..20%), but I still think that this would be a good improvement for externalizers api.

Bugzilla is now down for maintenance, so I can't attach patch to bug 166609 I opened to track this. Let me know if I should be bothering with attaching this work.

 Thanks

 Eugene


public interface IElement {
   public String getNodeName();
   public IElement addChildElement(String name);
   public void addChildElement(IElement element);
   public List<IElement> getChildNodes();
   public void setAttribute(String name, String value);
   public String getAttribute(String name);
   public boolean hasAttribute(String name);
   public Map<String, String> getAttributes();
   public void close();
}

 regards,
 Eugene


Eugene Kuleshov wrote:

While I am in an enthusiastic mood, I'd like to suggest to make some changes in ITaskListExternalizer API that need to be done before 1.0 release.

The main reason is to eliminate org.w3c.dom.* classes from this API and reduce runtime memory footprint of the task externalizers.

As a first step we can introduce own classes for Element, which may use dom classes internally (for now). So, connector's externalizers will only deal with our Element and won't have to change their implementation if we'll need to change externalizer internals. Another benefit of own element is that we can have stream based implementation at least for writing task data. That should help to speed things up for saving big task lists.

 See bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=166609

 regards,
 Eugene




Back to the top