Builds a property transform from a kernel and some options
@param kernel The transform kernel
@param options Some options regarding the property transform
872
function buildPropertyTransform(kernel, options = {}) {
    if (options.splitArrays == null)
        options.splitArrays = true;
    if (options.neverSkip == null)
        options.neverSkip = false;
    const ret = kernel;
    ret.splitArrays = options.splitArrays;
    ret.neverSkip = options.neverSkip;
    return ret;
}
498966
public <T extends Enum & Option> OptionsMapper prop(final String name, final T option) {
        return prop(name, option, null);
    }
1341178
public OptionsBuilder option(String option, Object value) {
        this.options.setOption(option, value);
        return this;
    }
697586
private function applyCallbacks($value, $options, core_kernel_classes_Property $targetProperty)
    {
        if (isset($options['callbacks'])) {
            foreach (array('*', $targetProperty->getUri()) as $key) {
                if (isset($options['callbacks'][$key]) && is_array($options['callbacks'][$key])) {
                    foreach ($options['callbacks'][$key] as $callback) {
                        if (is_callable($callback)) {
                            $value = call_user_func($callback, $value);
                        }
                    }
                }
            }
        }

        return $value;
    }
124123
function render(renderProperties, encodings, options) {
	encodings = linearizeEncodings(encodings);

	for (var i = 0; i < encodings.length; i++) {
		encodings[i].options = merge(options, encodings[i].options);
		fixOptions(encodings[i].options);
	}

	fixOptions(options);

	var Renderer = renderProperties.renderer;
	var renderer = new Renderer(renderProperties.element, encodings, options);
	renderer.render();

	if (renderProperties.afterRender) {
		renderProperties.afterRender();
	}
}
239591
def create_kernel_instance(self, kernel_options, params, verbose):
        """"""
        instance_string = util.get_instance_string(params)
        grid_div = (kernel_options.grid_div_x, kernel_options.grid_div_y, kernel_options.grid_div_z)

        #insert default block_size_names if needed
        if not kernel_options.block_size_names:
            kernel_options.block_size_names = util.default_block_size_names

        #setup thread block and grid dimensions
        threads, grid = util.setup_block_and_grid(kernel_options.problem_size, grid_div, params, kernel_options.block_size_names)
        if numpy.prod(threads) > self.dev.max_threads:
            if verbose:
                print("skipping config", instance_string, "reason: too many threads per block")
            return None

        #obtain the kernel_string and prepare additional files, if any
        temp_files = dict()
        kernel_source = kernel_options.kernel_string
        if not isinstance(kernel_source, list):
            kernel_source = [kernel_source]
        name, kernel_string, temp_files = util.prepare_list_of_files(kernel_options.kernel_name, kernel_source, params, grid, threads, kernel_options.block_size_names)

        #collect everything we know about this instance and return it
        return KernelInstance(name, kernel_string, temp_files, threads, grid, params, kernel_options.arguments)
277011
public <T> NettyChannelBuilder withOption(ChannelOption<T> option, T value) {
    channelOptions.put(option, value);
    return this;
  }
73134
public function setKernelOptions($kernelOptions)
    {
        $this->kernelOptions = $kernelOptions;

        //Convert root_dir to be relative to the resque bundle paths, this makes it possible to deploy workers in different places
        if (array_key_exists('kernel.root_dir', $this->kernelOptions)) {
            $this->kernelOptions['kernel.root_dir'] = $this->getRelativePath(__DIR__, $this->kernelOptions['kernel.root_dir']);
        }

        return $this;
    }
1004414
function(options) {
    var outputText = "";

    if (typeof options === "undefined") {
      throw new Error("No options passed to build method");
    }

    if (typeof options.selectedFeatures === "undefined" || options.selectedFeatures.length < 1) {
      throw new Error("Must specify at least one selected feature");
    }

    this.featuresWithReporting = [];
    this.featuresWithUpdate = [];
    this.dependencies = Object.create(null);
    this.updateEnabled = false;
    this.reportingEnabled = false;

    this.filename = options.filename || "ConfiguredFirmata";
    this.connectionType = options.connectionType || {serial: {baud: 57600}};
    this.selectedFeatures = options.selectedFeatures;

    this.transport = this.createTransport(this.connectionType);

    this.processFeatureSelection();

    outputText += this.createHeader();
    outputText += this.createIncludes();
    outputText += this.createPostDependencies();
    outputText += this.createSystemResetCallbackFn();
    outputText += this.transport.createHostConnectionCallbackFn();
    outputText += this.transport.createDebugStatusFn();
    outputText += this.transport.createIgnorePinsFn();
    outputText += this.transport.createInitTransportFn();
    outputText += this.createInitFirmataFn();
    outputText += this.createSetupFn();
    outputText += this.createLoopFn();

    return outputText;
  }
683865
public Configuration setOptions(Option... options) {
        return Configuration.builder().jsonProvider(jsonProvider).mappingProvider(mappingProvider).options(options).evaluationListener(evaluationListeners).build();
    }
516540
function(options) {
      inputEx.VectorField.superclass.setOptions.call(this, options);
     
      this.options.dimension = options.dimension || 2;
      this.options.size = options.size || 3;
     
      this.options.fields = [];
      for(var i = 0 ; i < this.options.dimension ; i++) {
         this.options.fields.push({type: 'number', size: this.options.size });
      }
   }
278960
public static void convolve(Kernel kernel, int[] inPixels, int[] outPixels, int width, int height, boolean alpha, int edgeAction) {
		if (kernel.getHeight() == 1)
			convolveH(kernel, inPixels, outPixels, width, height, alpha, edgeAction);
		else if (kernel.getWidth() == 1)
			convolveV(kernel, inPixels, outPixels, width, height, alpha, edgeAction);
		else
			convolveHV(kernel, inPixels, outPixels, width, height, alpha, edgeAction);
	}
442323
public void addAll(OptionsContainerBuilder container) {
		for ( Entry<Class<? extends Option<?, ?>>, ValueContainerBuilder<?, ?>> entry : container.optionValues.entrySet() ) {
			addAll( entry.getKey(), entry.getValue().build() );
		}
	}
542291
function sysctl(options, cb) {
  if (typeof arguments[0] != 'object'
    && typeof arguments[1] != 'function') {

    throw new Error('Invalid arguments. Signature: (object, callback)');
  }

  /*
   * Build cmd to execute.
   */
  var cmd = ['sysctl'];
  var args = [];

  switch (options.action) {
    case 'enable':
      args = args.concat('-w', options.path + '=1'); // It can not be --write since is not supported in older kernels.

      break;
    case 'disable':
      args = args.concat('-w', options.path + '=0'); // It can not be --write since is not supported in older kernels.

      break;
    case 'status':
      args = args.concat('--values', options.path);

      break;
    default:
      break;
  }

  /*
   * Execute command.
   */
  exec(cmd.concat(args).join(' '), function (error, stdout, stderror) {
    if (error) {
      cb(stderror.replace(/\n/g, '') + '. Executed command line: ' + cmd.concat(args).join(' '));
    }
    else {
      var result = null;
      if (options.action == 'status') {
        result = stdout;
      }

      cb(null, result);
    }
  });
}
993689
function Kernel(){
    this.registrations = new Registrations()
    this.decorators = new Decorators()
    this.resolvers = {}
    this.activators = {}
    this._inflight = new Inflight(this.decorators)
    registerSystemServices.call(this)
}
553216
public PropertyBuilder options(final String name) {
        name(name);
        type(Property.Type.Options);
        return this;
    }
1035815
public Operation createImage(String image, OperationOption... options) {
    ImageInfo imageInfo = ImageInfo.of(ImageId.of(image), DiskImageConfiguration.of(getDiskId()));
    return compute.create(imageInfo, options);
  }