February 10, 2012

OpenXML node type help

Filed under: Uncategorized — Tags: , , , — michaelangela @ 7:12 pm

I’ve been investigating some possible development opportunities dealing with OpenXML. Obviously for what it has to do there is quite a lot baked in and finding out what a particular node or attribute does though can be a bit time consuming. Schema Central offers a search though. Fast and concise. Not noticing the context I was in I saw <w:b />. A quick search yielded the text below prompting me to look at surrounding nodes. Yep, makes sense. Nice.

OOXML w:b — Complete documentation and samples

w:b Bold

August 15, 2010

JSON and xpath-like filtering

Filed under: Uncategorized — Tags: , , , — michaelangela @ 6:32 pm

I have been doing some recent work for a client with a large amount of JSON and webservices. Of course CharlesProxy is always helpful for this. I use it to be able analyze data flows, etc. In this case I wanted to be able to filter through the JSON to get at specific elements. Doing this for a while I thought it’d be neat to filter it the way we use XPath with XML. JSON Editor is a cool AIR app which allows you to view JSON and XML but also translate from one to the other. So I thought I’d just use that to convert the JSON to XML and then use XPath on it. Then I thought… “has anyone done anything like xpath for json?” Turns out they have.

jsonpath – Project Hosting on Google Code

JSONPath is a lightweight component that allows to find and extract relevant portions out of JSON structures on the client as well as on the server.

You can read more about it.

There are Wiki pages about usage and examples in Javascript and PHP.

Extensive test examples are available for JSONPath.

A PHP helper class JsonStore allows read, write and delete operations on JSON structures.

This isn’t the only json-xpath implementation of course. This also looks promising.

JPath – bluelinecity.com

JPath is a simple lightweight Javascript Class which provides an XPath-like querying ability to JSON objects.

Very cool.

Blog at WordPress.com.