in GatewayPluginExample/Ux/gulps/gulp-resjson/resjson-convert.ts [116:135]
private scan(node: any): { keyItems: NameValuePair[], dataItems: NameValuePair[] } {
let current = node;
let keyItems: NameValuePair[] = [];
let dataItems: NameValuePair[] = [];
for (let itemKey in current) {
if (current.hasOwnProperty(itemKey)) {
let itemValue: any = current[itemKey];
if (typeof itemValue === 'object') {
keyItems.push({ name: itemKey, value: itemValue });
} else if (typeof itemValue === 'string') {
dataItems.push({ name: itemKey, value: itemValue });
}
}
}
return {
keyItems: keyItems,
dataItems: dataItems
};
}