"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
function _StandaloneBuildFlags() {
const data = _interopRequireDefault(require("./StandaloneBuildFlags"));
_StandaloneBuildFlags = function () {
return data;
};
return data;
}
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
class StandaloneContext {
constructor() {
_defineProperty(this, "type", void 0);
_defineProperty(this, "data", void 0);
_defineProperty(this, "config", void 0);
_defineProperty(this, "published", void 0);
_defineProperty(this, "build", void 0);
_defineProperty(this, "isAnonymous", () => {
return this.type === 'service' && !this.config;
});
}
}
_defineProperty(StandaloneContext, "createUserContext", (projectPath, exp, publishedUrl) => {
let context = new StandaloneContext();
context.type = 'user';
context.data = {
projectPath,
exp
};
context.config = exp;
context.published = {
url: publishedUrl,
releaseChannel: 'default'
}; // we never expect to handle the build step for user contexts right now
context.build = _StandaloneBuildFlags().default.createEmpty();
return context;
});
_defineProperty(StandaloneContext, "createServiceContext", (expoSourcePath, archivePath, manifest, privateConfig, testEnvironment, build, publishedUrl, releaseChannel, shellAppSdkVersion) => {
let context = new StandaloneContext();
context.type = 'service';
context.data = {
expoSourcePath,
archivePath,
manifest,
privateConfig,
testEnvironment,
shellAppSdkVersion
};
context.config = manifest;
context.build = build;
context.published = {
url: publishedUrl,
releaseChannel: releaseChannel ? releaseChannel : 'default'
};
return context;
});
var _default = StandaloneContext;
exports.default = _default;
//# sourceMappingURL=../__sourcemaps__/detach/StandaloneContext.js.map