// Copyright IBM Corp. 2016. All Rights Reserved.
// Node module: apiconnect-cli-apps
// US Government Users Restricted Rights - Use, duplication or disclosure
// restricted by GSA ADP Schedule Contract with IBM Corp.

/********************************************************* {COPYRIGHT-TOP} ***
 * IBM Confidential
 * OCO Source Materials
 * 5725-C11, 5725-C12, 7198-8FX, 5725-F70, 5725-F71, 5725-F72, 5725-L30
 *
 * (C) Copyright IBM Corporation 2015  All Rights Reserved.
 *
 * The source code for this program is not published or otherwise
 * divested of its trade secrets, irrespective of what has been
 * deposited with the U.S. Copyright Office.
 ********************************************************* {COPYRIGHT-END} **/

var logger = require('apiconnect-cli-logger');
var _ = require('lodash');

function ApimAppsListFormatter() {}

ApimAppsListFormatter.prototype.format = function(result) {
  _.each(result, function(app) {
    logger.writeln(app.fullId);
  });

};

ApimAppsListFormatter.prototype.error = function(error) {
  throw error;
};

module.exports = ApimAppsListFormatter;
