define("esri/tasks/ProjectParameters",
["dojo/_base/declare", "dojo/_base/lang", "dojo/_base/array", "dojo/_base/json", "dojo/has", "esri/kernel", "esri/lang", "esri/geometry/jsonUtils"],
function (declare, d_lang, array, json, has, kernel, lang, jsonUtils) {
var _9 = declare(null, {
declaredClass:"esri.tasks.ProjectParameters",
geometries:null,
outSR:null,
transformation:null,
transformForward:null,
toJson:function () {
var _a = array.map(this.geometries, function (_b) {
return _b.toJson();
});
var jsonObj = {};
jsonObj.outSR = this.outSR.wkid || json.toJson(this.outSR.toJson());
jsonObj.inSR = this.geometries[0].spatialReference.wkid || json.toJson(this.geometries[0].spatialReference.toJson());
jsonObj.geometries = json.toJson({geometryType:jsonUtils.getJsonType(this.geometries[0]), geometries:_a});
if (this.transformation) {
jsonObj.transformation = this.transformation.wkid || json.toJson(this.transformation);
}
if (lang.isDefined(this.transformForward)) {
jsonObj.transformForward = this.transformForward;
}
return jsonObj;
}
});
if (has("extend-esri")) {
d_lang.setObject("tasks.ProjectParameters", _9, kernel);
}
return _9;
});