"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getRealmOptions = getRealmOptions; exports.getSerializerOptions = getSerializerOptions; exports.getDebuggerOptions = getDebuggerOptions; var _realm = require("./realm.js"); var _invariant = require("./invariant.js"); var _invariant2 = _interopRequireDefault(_invariant); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } /** * Copyright (c) 2017-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. */ function getRealmOptions(_ref) { var _ref$abstractEffectsI = _ref.abstractEffectsInAdditionalFunctions, abstractEffectsInAdditionalFunctions = _ref$abstractEffectsI === undefined ? false : _ref$abstractEffectsI, _ref$compatibility = _ref.compatibility, compatibility = _ref$compatibility === undefined ? "browser" : _ref$compatibility, _ref$debugNames = _ref.debugNames, debugNames = _ref$debugNames === undefined ? false : _ref$debugNames, errorHandler = _ref.errorHandler, mathRandomSeed = _ref.mathRandomSeed, _ref$omitInvariants = _ref.omitInvariants, omitInvariants = _ref$omitInvariants === undefined ? false : _ref$omitInvariants, uniqueSuffix = _ref.uniqueSuffix, reactEnabled = _ref.reactEnabled, reactOutput = _ref.reactOutput, residual = _ref.residual, _ref$serialize = _ref.serialize, serialize = _ref$serialize === undefined ? !residual : _ref$serialize, strictlyMonotonicDateNow = _ref.strictlyMonotonicDateNow, timeout = _ref.timeout, maxStackDepth = _ref.maxStackDepth; return { abstractEffectsInAdditionalFunctions: abstractEffectsInAdditionalFunctions, compatibility: compatibility, debugNames: debugNames, errorHandler: errorHandler, mathRandomSeed: mathRandomSeed, omitInvariants: omitInvariants, uniqueSuffix: uniqueSuffix, reactEnabled: reactEnabled, reactOutput: reactOutput, residual: residual, serialize: serialize, strictlyMonotonicDateNow: strictlyMonotonicDateNow, timeout: timeout, maxStackDepth: maxStackDepth }; } function getSerializerOptions(_ref2) { var additionalFunctions = _ref2.additionalFunctions, lazyObjectsRuntime = _ref2.lazyObjectsRuntime, heapGraphFormat = _ref2.heapGraphFormat, _ref2$delayInitializa = _ref2.delayInitializations, delayInitializations = _ref2$delayInitializa === undefined ? false : _ref2$delayInitializa, _ref2$delayUnsupporte = _ref2.delayUnsupportedRequires, delayUnsupportedRequires = _ref2$delayUnsupporte === undefined ? false : _ref2$delayUnsupporte, _ref2$accelerateUnsup = _ref2.accelerateUnsupportedRequires, accelerateUnsupportedRequires = _ref2$accelerateUnsup === undefined ? true : _ref2$accelerateUnsup, _ref2$internalDebug = _ref2.internalDebug, internalDebug = _ref2$internalDebug === undefined ? false : _ref2$internalDebug, _ref2$debugScopes = _ref2.debugScopes, debugScopes = _ref2$debugScopes === undefined ? false : _ref2$debugScopes, _ref2$logStatistics = _ref2.logStatistics, logStatistics = _ref2$logStatistics === undefined ? false : _ref2$logStatistics, _ref2$logModules = _ref2.logModules, logModules = _ref2$logModules === undefined ? false : _ref2$logModules, _ref2$profile = _ref2.profile, profile = _ref2$profile === undefined ? false : _ref2$profile, _ref2$inlineExpressio = _ref2.inlineExpressions, inlineExpressions = _ref2$inlineExpressio === undefined ? false : _ref2$inlineExpressio, _ref2$simpleClosures = _ref2.simpleClosures, simpleClosures = _ref2$simpleClosures === undefined ? false : _ref2$simpleClosures, _ref2$initializeMoreM = _ref2.initializeMoreModules, initializeMoreModules = _ref2$initializeMoreM === undefined ? false : _ref2$initializeMoreM, _ref2$trace = _ref2.trace, trace = _ref2$trace === undefined ? false : _ref2$trace; var result = { delayInitializations: delayInitializations, delayUnsupportedRequires: delayUnsupportedRequires, accelerateUnsupportedRequires: accelerateUnsupportedRequires, initializeMoreModules: initializeMoreModules, internalDebug: internalDebug, debugScopes: debugScopes, logStatistics: logStatistics, logModules: logModules, profile: profile, inlineExpressions: inlineExpressions, simpleClosures: simpleClosures, trace: trace }; if (additionalFunctions) result.additionalFunctions = additionalFunctions; if (lazyObjectsRuntime !== undefined) { result.lazyObjectsRuntime = lazyObjectsRuntime; } if (heapGraphFormat !== undefined) { result.heapGraphFormat = heapGraphFormat; } return result; } function getDebuggerOptions(_ref3) { var debugInFilePath = _ref3.debugInFilePath, debugOutFilePath = _ref3.debugOutFilePath; (0, _invariant2.default)(debugInFilePath !== undefined, "Debugger invoked without input file path"); (0, _invariant2.default)(debugOutFilePath !== undefined, "Debugger invoked without output file path"); var result = { inFilePath: debugInFilePath, outFilePath: debugOutFilePath }; return result; } //# sourceMappingURL=prepack-options.js.map