/** * Creates a job to update an outbox. * @param bindingProperties Properties that uniquely identify a permutation. * (Otherwise, more than one permutation will be compiled.) * @param parentLogger The parent of the logger that will be used for this job. */ Job(Outbox box, Map<String, String> bindingProperties, TreeLogger parentLogger, Options options) { this.id = chooseNextId(box); this.outbox = box; this.inputModuleName = box.getInputModuleName(); // TODO: we will use the binding properties to find or create the outbox, // then take binding properties from the outbox here. this.bindingProperties = ImmutableSortedMap.copyOf(bindingProperties); this.recompileListener = Preconditions.checkNotNull(options.getRecompileListener()); this.jobChangeListener = Preconditions.checkNotNull(options.getJobChangeListener()); this.args = Preconditions.checkNotNull(options.getArgs()); this.tags = Preconditions.checkNotNull(options.getTags()); this.logSupplier = new LogSupplier(parentLogger, id); }
/** * Creates a job to update an outbox. * @param bindingProperties Properties that uniquely identify a permutation. * (Otherwise, more than one permutation will be compiled.) * @param parentLogger The parent of the logger that will be used for this job. */ Job(Outbox box, Map<String, String> bindingProperties, TreeLogger parentLogger, Options options) { this.id = chooseNextId(box); this.outbox = box; this.inputModuleName = box.getInputModuleName(); // TODO: we will use the binding properties to find or create the outbox, // then take binding properties from the outbox here. this.bindingProperties = ImmutableSortedMap.copyOf(bindingProperties); this.recompileListener = Preconditions.checkNotNull(options.getRecompileListener()); this.jobChangeListener = Preconditions.checkNotNull(options.getJobChangeListener()); this.args = Preconditions.checkNotNull(options.getArgs()); this.tags = Preconditions.checkNotNull(options.getTags()); this.logSupplier = new LogSupplier(parentLogger, id); }