Using JsonFX I am loading a json stream into my application. The json uses a URL for one of the objects inside, and so, using the default dynamic way of accessing the object doesn’t work, as some of the characters in the URL are not valid for a member name.
http://opendatacommunities.org/doc/geography/lsoa/E01004700.json
{
'http://opendatacommunities.org/id/geography/lsoa/E01004700': {
'http://data.ordnancesurvey.co.uk/ontology/spatialrelations/easting': [
{
type: 'literal',
value: '526252',
datatype: 'http://www.w3.org/2001/XMLSchema#integer'
}
],
'http://www.w3.org/2003/01/geo/wgs84_pos#lat': [
{
type: 'literal',
value: '51.51349',
datatype: 'http://www.w3.org/2001/XMLSchema#decimal'
}
],
'http://statistics.data.gov.uk/def/administrative-geography/district': [
{
type: 'uri',
value: 'http://statistics.data.gov.uk/id/local-authority-district/00BK'
}
],
'http://opendatacommunities.org/def/geography#boundaryAsJSON': [
{
type: 'uri',
value: 'http://opendatacommunities.org/lsoa_boundaries/E01004700.json'
}
],
'http://data.ordnancesurvey.co.uk/ontology/spatialrelations/northing': [
{
type: 'literal',
value: '180964',
datatype: 'http://www.w3.org/2001/XMLSchema#integer'
}
],
'http://www.w3.org/2003/01/geo/wgs84_pos#long': [
{
type: 'literal',
value: '-0.18198',
datatype: 'http://www.w3.org/2001/XMLSchema#decimal'
}
],
'http://www.w3.org/2004/02/skos/core#notation': [
{
type: 'literal',
value: 'E01004700'
}
],
'http://www.w3.org/1999/02/22-rdf-syntax-ns#type': [
{
type: 'uri',
value: 'http://opendatacommunities.org/def/geography#LSOA'
}
],
'http://www.w3.org/2000/01/rdf-schema#label': [
{
type: 'literal',
value: 'Westminster 016E'
}
],
'http://www.w3.org/2002/07/owl#sameAs': [
{
type: 'uri',
value: 'http://statistics.data.gov.uk/id/statistical-geography/E01004700'
}
]
}
}
Is there a way that I can access this object?
You can use the class of mine. Or go to Json.net .