How to use the @accordproject/cicero-core.logger.info function in @accordproject/cicero-core

To help you get started, we’ve selected a few @accordproject/cicero-core examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github accordproject / cicero / packages / cicero-engine / lib / logger.js View on Github external
keys.forEach(function(key) {
                let element = obj[key];
                if(element.getType) {
                    // TODO (DCS) call toJSON once that works for concepts
                    printable[key] = element.getFullyQualifiedType();
                }
                else {
                    printable[key] = element;
                }
            }, this);

            logger.info( 'CICERO-ENGINE', JSON.stringify(printable));
        }
        else {
            logger.info( 'CICERO-ENGINE', obj);
        }
    }
}
github accordproject / cicero / packages / cicero-engine / lib / logger.js View on Github external
if(typeof obj === 'object') {
            let printable = {};
            const keys = Object.keys(obj);

            keys.forEach(function(key) {
                let element = obj[key];
                if(element.getType) {
                    // TODO (DCS) call toJSON once that works for concepts
                    printable[key] = element.getFullyQualifiedType();
                }
                else {
                    printable[key] = element;
                }
            }, this);

            logger.info( 'CICERO-ENGINE', JSON.stringify(printable));
        }
        else {
            logger.info( 'CICERO-ENGINE', obj);
        }
    }
}