Hi,
On Aug 25, 3:57 pm, B Smith-Mannschott wrote:
> Yes, that's precisely the intent. ("...Consider the prefix to be the
> empty string in for attrs declaring a default namespace.")
Oops again. Seems I was also sloppy reading docstrings. :)
Sincerely
Meikel
--~--~-~--~~--
On Tue, Aug 25, 2009 at 15:44, Meikel Brandmeyer wrote:
>
> Hi,
>
> here's my try using for:
>
> (defn xmlns-attr?
> [k]
> (or (= k :xmlns) (.startsWith (name k) "xmlns:")))
>
> (defn ns-assoc-2
> [attrs xmlns-map]
> (into xmlns-map
> (for [[k v] :when (xmlns-a
Hi again,
On Aug 25, 3:44 pm, Meikel Brandmeyer wrote:
> (for [[k v] :when (xmlns-attr? k)]
Oops. Missed the attrs in front of :when.
Sincerely
Meikel
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "
On Tue, Aug 25, 2009 at 15:44, Meikel Brandmeyer wrote:
>
> Hi,
>
> here's my try using for:
>
> (defn xmlns-attr?
> [k]
> (or (= k :xmlns) (.startsWith (name k) "xmlns:")))
>
> (defn ns-assoc-2
> [attrs xmlns-map]
> (into xmlns-map
> (for [[k v] :when (xmlns-a
Hi,
here's my try using for:
(defn xmlns-attr?
[k]
(or (= k :xmlns) (.startsWith (name k) "xmlns:")))
(defn ns-assoc-2
[attrs xmlns-map]
(into xmlns-map
(for [[k v] :when (xmlns-attr? k)]
[(-> k name (.replaceAll "xmlns:" "") (.replaceAl
Hello!
I've been playing around with clojure in my spare time for a while now
and am currently experimenting with ideas for querying XML using
clojure. It'll be a while yet before I have something usable, but in
the meantime I'd like some advice regarding one of the functions I'm
writing. Clojure