Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [e4-dev] Contribution from Dave and Gordon


> As we discussed on the call, I'd appreciate a pointer to code within
> Eclipse that encodes/decodes XML entities in a String.  That's the
> only thing I can anticipate needing to fix from an IP perspective (but
> we'll see what the lawyers say).

I'm not sure if this is exactly what you are looking for, but code to embed an arbitrary String into XML can be found in XMLWriter.java in the method escape(String):

http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.equinox/p2/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/XMLWriter.java?root=RT_Project&view=markup

A similar method is found in XMLMemento.DOMWriter#getEscaped(String), which is part of a public API for storing arbitrary settings in XML:

http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.ui.workbench/Eclipse%20UI/org/eclipse/ui/XMLMemento.java?view=markup

John

Back to the top